stepper motor + TI stellaris

hfcanova wrote on Wednesday, August 22, 2012:


I’m trying to make one multi-axis stepper motor controller using an TI Stellaris microcontroller, this controller will be capable to receive command via TCP/IP (uIP) , and control the STEP/DIR motors driver (3 axis for the begin but I want to control 6 if possible), I’m thinking many ways to control this motors at same time, and finally my system maybe will be an very small kind of RTOS, but if possible I want to use the FreeRTOS to create tasks to control the communication,parser, and the motors drivers, my doubt is: Can I use the RTOS to create pulse to my drive around some Khz (maybe 50khz )? and change between tasks quick to sync the motors and create the multi axis moviment?


edwards3 wrote on Wednesday, August 22, 2012:

No. Anything requiring 50khz needs to be kept in interrupts. No RTOS will be able to switch tasks like that and leave space for actually application execution. You can do your communications in the RTOS and use interrupts with priorities higher than configMAX_SYSCALL_INTERRUPT_PRIORITY to do the really fast stuff.

hfcanova wrote on Wednesday, August 22, 2012:

Thank’s Edwards

I’will try this way, using interruption  higher than configMAX_SYSCALL_INTERRUPT_PRIORITY to make the motor moves and RTOS to manipulate the comunication.

Thanks again