Quote:
Originally Posted by Jim E
That ROM array you are initializing at the start looks pretty big. Do you really need that level of precision? Each character will probably eat up 2 bytes of RAM.
|
First of all, characters are, by definition, a single byte. On the other hand, the array is defined as
int, so each value indeed takes two bytes. On the gripping hand, putting the array in ROM means it takes no RAM anyway.
Tanis, you're only putting values between -127 and 127 in the array. That will fit in a
signed char if you do want to cut the array's size in half.
Quote:
|
Including the camera code and other functions is probably pushing you to the limits of the processors RAM during run time.
|
There's essentially no dynamic allocation of memory in the program, so RAM usage issues will make themselves known at compile time.
But I didn't notice the reference to camera and tracking code before. The serial port support that goes along with them requires specific changes to the interrupt service routine. Failing to handle interrupts properly is another way to cause the code error light to come on.
Tanis, are you actually using the camera? If so, make sure you've done the appropriate things to
user_routines_fast.c as called out in the camera code documentation, and don't forget to call the camera tracking function in the main loop, probably from
Default_Routine(). If not, don't
#include the unnecessary files.