jegy wrote on Saturday, April 13, 2013:
Hi,
I have now FreeRTOS running on a LPC2478.
Please observe the following:
- I use IAR EW 5.4
- I use Segger J-Link Ultra JTAG debugger
- HW platform is “old”, and is known for me. It is a subset of the Olimex LPC2478-STK with a QVGA color touch screeen. It runs normally the application, with a simple scheduler and my job is now to modify the application to run under FreeRTOS.
- I have started FreeRTOS with only one appTask and the idleHook,
- I can toggle port pins in the the timerISR, in the appTask and in the idleHook for observing on an oscilloscope where the CPU time is spent.
- When the FreeRTOS application runs without debugger, everything is perfect.
- When It runs from the EW, via the JTAG, the timing is corrupted. In the J-link Control Panel, I can see that when my FreeRTOS application runs, there are several hundred times more calls bewtween the J-Link and the CPU, than when the original old application is running. I guess these calls halts/blocks the CPU.
It seems that every time the FreeRTOS shall switch task, the CPU is halted/blocked for app. 8-10ms
I guess that it has something to do with the ARM operating mode or that the J-link and FreeRTOS both makes use of the “SWI” and therefore disrupts each other
Q1: Have you earlier seen similar behavior?
Q2: Can the “yieldfromApi” function be implemented in an other way than using the “SWI” if this is the reason for the halt/blocing the CPU?
Q3: Do you have a more simple solution?
Q4: Do you think the problem also exists if I replace the LPC2478 with the pincompaible CM-3 LPC1788?
I am not a novice in FreeRTOS, I have made several projects with AT-mega, STM32 and H8.
Best Regards,
Jens