As mentioned in #317 and #303 a segmentation fault occurs when compiling with large USER_MOTION_SIZE values, preventing the generation of very long simulations. The error is caused by allocating the array containing the xyz motion in the main function, and thus on the stack. With large motion sizes this leads to a stack overflow causing the crash. The very simple fix is to just declare the xyz variable as a global variable outside the main function putting it into the data section of memory.
As mentioned in #317 and #303 a segmentation fault occurs when compiling with large USER_MOTION_SIZE values, preventing the generation of very long simulations. The error is caused by allocating the array containing the xyz motion in the main function, and thus on the stack. With large motion sizes this leads to a stack overflow causing the crash. The very simple fix is to just declare the xyz variable as a global variable outside the main function putting it into the data section of memory.