Hello,
I'm using CCS version 4.2.0.10018 and SYS/BIOS 6.30.2.42 to develop an application for the TMS320DM6437. This processor is on a custom board that we have developed.
I'm using SYS/BIOS to do all of the following.
Thread 1 - A Hwi thread (created by Hwi_create and triggered by a CAN transmit/receive interrupt).
Thread 2 - A Timer thread (created by Timer_create and triggered every 100 microseconds, used to read data from an A/D converter and to trigger the next conversion).
Threads 3 and 4 - Two Task threads (created by Task_create, one with priority 15 that periodically reads CAN packets from the bus, the other with priority 14 that periodically writes CAN packets to the bus).
All four of my threads execute just fine as long as my timer thread function simply reads the data from the A/D converter (via the SPI interface) and then triggers the next conversion.
However, when I added code to my timer thread function to insert each data point in a circular buffer, the other threads (threads 1, 3 and 4) stopped running (the timer thread continues to work just fine).
First I called a function from my timer thread function to save the data in a circular buffer. Then I made that function inline, but it made no difference. Then I stopped calling the function and instead just insert directly into the circular buffer from my timer function, but it made no difference.
I'm at a loss. All four of these thread functions are fairly simple. The circular buffer code was copied from another project and has been well tested. All of the threads should be able to "keep up".
Is this a thread priority problem? I placed breakpoints in all the threads and only the timer thread breakpoint is reached.
Does anyone have any ideas? I'm new to the SYS/BIOS real-time kernel.
Thanks,
Tim M