LPCXpresso Debugging question

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPCXpresso Debugging question

376 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by rattus on Fri Aug 12 11:42:40 MST 2011
Hi - I'm new to the LPCXpresso/Eclipse environment, and would like to get a tip on debugging a vexing "memory stomp" issue.

In isolation, my oled driver does a great job. When I integrate it into my FreeRTOS project, I get a hard fault when it is called, but well after it had been initialized.

My question is, how best to determine which tasks are trying to occupy the same address space so that I can untangle them?

Thanks,

Mike
0 Kudos
Reply
3 Replies

367 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Rob65 on Sun Aug 14 00:05:57 MST 2011
Try to figure out what the address is where the hard fault is generated.
See "How to debug a hard fault" in the Code Red FAQ.
This will/may give you some tips.

I've had a few nice hard faults in my application that were not due to the new code added but due to a problem in another part of my code that only popped up when the footprint of the program changed (e.g. getting a pointer from an uninitialized memory address that always resulted in a proper value in the old situation).

What task is running with the hard fault happens?
Do you have configCHECK_FOR_STACK_OVERFLOW and configUSE_MALLOC_FAILED_HOOK enabled? A lot of errors are due to stack or memory allocation problems.

Rob
0 Kudos
Reply

367 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by rattus on Fri Aug 12 17:51:25 MST 2011
I think it's also Eclipse/LPCXpresso question - how do you monitor the memory footprint of any process to determine the addressing limits of that task/process/function. I'll ask at the FreeRTOS forum as well.

Anyone?

Thanks,

Mike
0 Kudos
Reply

367 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by TheFallGuy on Fri Aug 12 16:15:22 MST 2011
You are probably best asking this question on the FreeRTOS forum
0 Kudos
Reply