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.

TM4C123GH6PM HWI

Other Parts Discussed in Thread: SYSBIOS

Hi i'am using CCS5.4 RTOS1.10.00.23 and i tried to add a hwi via the configurator but i get always the compiling error.

XDC runtime error: ti.sysbios.family.arm.m3.Hwi.Module_State#0/iser: index out of range (-1)  
ti.sysbios.family.arm.m3.Hwi.Module_State#0/iser: index out of range (-1) 

.cfg file

var hwi0Params = new Hwi.Params();
hwi0Params.instance.name = "rs232";
hwi0Params.eventId = 21;
Program.global.rs232 = Hwi.create(1, "&uart_int", hwi0Params);

please help

best regards

Franz Winkler

  • The big problem I see is the vector number passed to Hwi.create.  The first argument should be the vector number of the interrupt, which is definitely not 1.  For example, the vector for UART0 is 21, UART1 is 22.  You can see the vector numbers in hw_ints.h.  Vectors 0-15 are probably reserved since they are special cases (such as fault handler, reset handler, etc.).

  • Hello, ok that is clear for me and it works. my question is how can i implement a recive interrupt driven UART?

    Is the UART_read(...) interrupt driven?

    Franz

  • The easiest thing to do would be to look at the uart_echo example in TivaWare.  You can see how to configure and handle UART interrupts.  In your specific case, the only difference would be how you actually point to the interrupt handler since you're using TI RTOS.  In your case the pointer to the UART handler would be in the sysbios.cfg file, and the RTOS-less version it's directly in the vector table in the startup file.