I am developing a real-time motion controller for multiple DC motors. During my control loop I want to collect statistical data by saving it into an array, and then outputting the entire array to a file after the control loop is complete. My problem is that if I try to allocate my buffer array(float fBuffer) any larger than 2000, I get a memory fault (core dumped) error. Is there any way to make this array larger? I’ve tried allocating memory for the array using “new” command, but it doesn’t seem to let me allocate a 2-D array.
Any help would be great.