Hi,
I'm new to bios and using:
- Bios version 6.34.2.18.
- IPC Version 1.25.0.04
- XDCTools version 3.24.5.48
- CCS V 5.3.0.00090
I am using a custom board with MSP430F5438A.
I seem to be experiencing a lock up of the system (does not respond to interrupts and tasks do not run) when I use GateAll functions. I don't think the problem is priority inversion because I enter a gate do something that dose not:
- call functions that enter or leave gates.
- or pend on events or semaphores.
On the board there are 3 SPI FRAM modules. One of the tasks writes data on chip 1 every X seconds. The same task writes data on chip 2 after X minutes and data to chip 3 after X hours. My timer module uses a hardware timer interrupt which calls a Swi post function. It is very similar to the one found on page 3-68 of Bios_User_Guide (SPRUEX3J).
The data is then read every Y seconds by another task from the FRAMs and printed on a computer screen via UART.
Before writing or reading data to the FRAMs I call a GateAll_enter and then GateAll_leave. The data is read and written correctly to FRAMs and printed via UART. The SPI and UART drivers work fine without sysbios. I have made sure that ther interrupt keyword is not used anywhere in my code.
If I use the gate functions my system locks up for about 2,5 seconds after every read or write via SPI. I have seen that the system hangs only after every task has finished execution. After 2,5 seconds everything works fine until the next gateAll function call. If I substitute the gateAll functions with interrupt disable functions (Hwi_disable and Hwi_enable) the same thing happens.
If I do not protect the critical parts of my code with gates or by disabling/enabling interrupts everything works as it should (except for the risk of data writes being interrupted by interrupts).
In my application the UART is working with interrupts in transmission and reception meanwhile the SPI does not use interrupts.
Any help would be really appreciated.
Thanks
Adam