Problem With Motors

I’m not an expert, but I can say for starters, I don’t think its the code. It would have to be something in the motors themselves, not something in the code making the motors smoke. Or, there could just be too much weight on the motors, or too much power into the motors themselves. If it really is in the code, then I’m not much help there. Sorry.

I’m not an expert, but I can say for starters, I don’t think its the code. It would have to be something in the motors themselves, not something in the code making the motors smoke. Or, there could just be too much weight on the motors, or too much power into the motors themselves. If it really is in the code, then I’m not much help there. Sorry.

After these two parts of code you don’t tell the motors to shut off so for example: this first part, your telling your fork motors to run at negative 127 power but the wait time you have DOESN’T TELL THE MOTORS TO STOP! Because of this your fork motors will reach a point where they can’t move anymore but since you don’t tell them to shut off, they will keep going until either the ptc trips, or the motor just overheats or smokes(your cortex may be partially faulty because smoking motors means the cortex ptc didn’t trip like it should).

And this is the other part that doesn’t tell the motors to shut off:

Basically you just need to add in parts to stop the motors after every movement.
Hopefully this helps, that’s just what’s wrong with the code. I hope you figure out the problem :slight_smile:

EDIT: Your user-control code actually looks pretty spot on, good job.