Encoder interrupts with the svp324

Hi guys, I’m new to the orangatan and have mostly used msp430’s. I have a question regarding the second processor on the svp324. I’m using the 2 of the 1444 - 50:1 Metal Gearmotor 37Dx54L mm with 64 CPR Encoder.

The goal is to have some interrupt that counts the encoder signals, calculates speed and position using a pid controller and what not to hopefully get the robot to go on a set path while avoid objects and recording its position. obviously nothing new.

I have found some code that sets up interrupts in the main program for the encoders however since the encoders I am using have 3200 counts per revolution (1600 for just one signal) I fear that the main processor would be too busy to preform any other functions. I know that I can set the svp to SVP_MODE_ENCODERS and have the second processor deal with the encoders. MY question is can I program or some how delegate the second processor to completely or mostly control the wheels leaving the main processor to preform other tasks? or at the very least interrupt the main processor when ever the encoders reach x number of counts?

The second processor can read the encoders and report the counts to the main processor whenever the main processors asks for it over SPI. The second processor can’t control motors and it doesn’t have any way to trigger an interrupt on the main processor.

Your main processor should have no problem reading the encoder counts from the second processor every 20ms or so and updating the motor speed itself. Is there some reason that won’t work for you?

–David

wow i feel like a dum dum. that would definitively work, sorry for the dumb question.