Here's the values for Z:
MAX_VELOCITY = 1.8
MAX_ACCELERATION = 2.0
These were set after a lot of experimentation. Higher values stall the stepper motor. I could try increasing the acceleration somewhat, but probably in the 10-20% range. Not sure this would make much difference. Let me know if you think I should try it anyway.
You mentioned that the 200 RPM plot is broken. Are you referring to the change of slope in the velocity before it starts oscillating?
Is it likely that the 10 pulse/revolution pulses are causing the problem? I could redo that part of the lathe. Getting greater acceleration will require a new stepper or servo motor and a lot of work.
I have two choices for the encoder-
1) I have some encoders in my junk drawer. They're both quadrature. One is a US Digital 1000 pulses/rev with a separate index signal, and the other is a more robust looking Accu-coder 2500 pulses/rev. Both are designed for small shafts, so I'd need a belt or gearing to connect them.
2) I could machine a gear to bolt on the spindle pulley. It'd be about 7 1/4" or so in diameter, so how ever many teeth I could fit on it. Maybe about 90 1/8" teeth? Or 180 1/16" teeth? I don't have any feel for how many pulses/revolution is appropriate, so maybe this would not work.
Here's a photo of the two pulse generators. The 1 pulse/rev is magnetic and the other one is proximity. The teeth are for locking the spindle.