Hello, I'm working on EZ-USB 8051 firmware. If I load the firmware under debugger then firmware works as expected but when I load it standalone then it crashes. I have been able to find a corelation between a ring buffer declaration and crash. Following is the ring buffer declarion
#define RING_BUFFER_SIZE 900 #define RING_BUFFER_THRESHOLD 100 // // Define a Ring Buffer // struct RingBuffer { byte buffer[RING_BUFFER_SIZE]; //pointer to a character buffer unsigned short count; //count of characters in buffer unsigned short nextSlotOut; //pointer to next input slot unsigned short nextSlotIn; //pointer to last character read };