This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

eZdsp_F28355 and external interrupt XINT3 not working

Hi all,

I am using DMC1500 with eZdsp_F28355 for motor control with 3-hall sensors (PMSM) and need 3 external interrupts for that. I had it working on F28027 and F2812, but failed on 28335. I have very same codes, in 28335, only XINT1 and XINT2 functional, XINT3 is NOT. I have confirmed that external voltages are present (GPIO20/21/23), but XINT3 is not trigged, are there anything special on 28335 on this matter? thanks

//-------------------------------------------------

PieCtrlRegs.PIECTRL.bit.ENPIE = 1;  
PieCtrlRegs.PIEIER1.bit.INTx4 = 1;  
PieCtrlRegs.PIEIER1.bit.INTx5 = 1;  
PieCtrlRegs.PIEIER12.bit.INTx1 = 1; 

IER |= M_INT1 | M_INT12;            

EALLOW;
  GpioCtrlRegs.GPAMUX2.bit.GPIO20 = 0;     
  GpioCtrlRegs.GPADIR.bit.GPIO20 = 0;      
  GpioCtrlRegs.GPAQSEL2.bit.GPIO20 = 0;    

  GpioCtrlRegs.GPAMUX2.bit.GPIO21 = 0;     
  GpioCtrlRegs.GPADIR.bit.GPIO21 = 0;      
  GpioCtrlRegs.GPAQSEL2.bit.GPIO21 = 0;    

  GpioCtrlRegs.GPAMUX2.bit.GPIO23 = 0;     
  GpioCtrlRegs.GPADIR.bit.GPIO23 = 0;      
  GpioCtrlRegs.GPAQSEL2.bit.GPIO23 = 0;    

 
  GpioIntRegs.GPIOXINT1SEL.bit.GPIOSEL = 20;
  GpioIntRegs.GPIOXINT2SEL.bit.GPIOSEL = 21;
  GpioIntRegs.GPIOXINT3SEL.bit.GPIOSEL = 23;
EDIS;

XIntruptRegs.XINT1CR.bit.POLARITY = 3;
XIntruptRegs.XINT2CR.bit.POLARITY = 3;
XIntruptRegs.XINT3CR.bit.POLARITY = 3;

XIntruptRegs.XINT1CR.bit.ENABLE = 1;  
XIntruptRegs.XINT2CR.bit.ENABLE = 1;  
XIntruptRegs.XINT3CR.bit.ENABLE = 1;  

 

  • Hi Jizhong -

    This is because on the F2833xx devices, XINT3-XINT7 are tied to GPIO32 - GPIO63 via the GPIOXINTnSEL bits (where n is the XINTn interrupt number). So actually when you set GPIOXINT3SEL.bit.GPIOSEL = 23, XINT3 is connected to GPIO55 and not GPIO 23.

     

  • Thanks for quick responce

    I am using DMC1500, which had 3 hall sensor inputs tied to pin 6/7/8 of P19, on ezdsp_f28335, P8 has matching ports (GPIO20/21/23), how can I re-assign XINT3 to GPIO23?

    where can I find out which XINT3-7 are internally tied to which GPIO ports, as you mentioned XINT3 => GPIO55 ?

     

     

    Chrissy Chang said:

    Hi Jizhong -

    This is because on the F2833xx devices, XINT3-XINT7 are tied to GPIO32 - GPIO63 via the GPIOXINTnSEL bits (where n is the XINTn interrupt number). So actually when you set GPIOXINT3SEL.bit.GPIOSEL = 23, XINT3 is connected to GPIO55 and not GPIO 23.

     

     

  • Jizhong -

    As mentioned in the previous post, XINT3-XINT7 can only be tied to GPIO32-GPIO63.  XINT3 therefore cannot be assigned to GPIO23.

    Please see the TMS320x2833x, 2823x System Control and Interrupts Guide (SPRUFB0) GPIO section to see which GPIO pins can be assigned to XINT3-XINT7. 

  • Thanks, since I need 3 external interrupts and can not change pin out for DMC1500-eZdspF28355, I am using XINT1, XINT2 and NMI (assigned to GPIO23) for now. it works for me

     

    Jizhong

     

    Chrissy Chang said:

    Jizhong -

    As mentioned in the previous post, XINT3-XINT7 can only be tied to GPIO32-GPIO63.  XINT3 therefore cannot be assigned to GPIO23.

    Please see the TMS320x2833x, 2823x System Control and Interrupts Guide (SPRUFB0) GPIO section to see which GPIO pins can be assigned to XINT3-XINT7.