AnsweredAssumed Answered

TWR K60N512 uart ISR triggering using mqx 4.0

Question asked by Shiju C G on Dec 17, 2013
Latest reply on Dec 19, 2013 by Shiju C G

Hi,

I am using TWR K60N512 with mqx 4.0 .I need to create an ISR function for uart3 interrupt that trigger whenever a character is received .I tried to create an ISR  function, but it never gets triggered.

These are my initialization steps

 

#define RS232CHANNEL "ittyd:"

 

 

   rs232_dev = fopen( RS232CHANNEL, BSP_DEFAULT_IO_OPEN_MODE );

  

   _nvic_int_init(INT_UART3_RX_TX, 2, TRUE);  

   

  _nvic_int_enable(INT_UART3_RX_TX);  

 

   _int_install_isr(INT_UART3_RX_TX, uart3_rx_tx_isr, rs232_dev);

 

 

I have enabled the ITTYD in userconfig.h 

 

 

The following is the ISR function that i created.

void uart3_rx_tx_isr

   (

      pointer user_isr_ptr

   )

{

   uchar ubUDR;

   if (fstatus( rs232_dev ))

   {

       ubUDR = fgetc( rs232_dev );

   }

  

}

 

 

Can anybody provide me a sample code for the same  or help me to create an ISR that trigger whenever a character is received?.

Outcomes