[Spindle A/B/Z Rotary Encoder] - Minimum PPR requirement? #61
-
I'm having difficulty reading my spindle RPM with my old Rotary A/B/Z 100ppr encoder (which works fine on a parport config). I'm getting the feeling that 100PPR ain't sufficient for Litex-CNC. My FPGA is 40Mhz and the linuxcnc servo thread is 1000000. What sort of encoder PPR would be best to read 0~5000 RPM? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 11 replies
-
To be honest: anything with an index pulse would work for a spindle. When the speed is constant, the index pulse can be used to start the movements. LitexCNC does not have any requirements on the resolution of the encoder. Can you describe why you think that the 100PPR encoder is not sufficient? Maybe something is wrong and needs improvement on the LitexCNC side. If you want to go fancy and really make 'digital gears', then I would recommend a 2500 PPR encoder. In that case it is possible to create non-round objects with your lathe. |
Beta Was this translation helpful? Give feedback.
-
HAL Example of a PWM Closed Loop Spindle with LitexCNCFor Reference only. I was toying with the encoder and spindle yesterday and had this working pretty well using a PWM output and a 100ppr encoder. Fully Functional with Sxxx M3 however (M4-abs) remains to be done along with filtering, perhaps. If anybody get to finish it up please update/share. HAL
pyvcp_option.hal
|
Beta Was this translation helpful? Give feedback.
To be honest: anything with an index pulse would work for a spindle. When the speed is constant, the index pulse can be used to start the movements.
LitexCNC does not have any requirements on the resolution of the encoder. Can you describe why you think that the 100PPR encoder is not sufficient? Maybe something is wrong and needs improvement on the LitexCNC side.
If you want to go fancy and really make 'digital gears', then I would recommend a 2500 PPR encoder. In that case it is possible to create non-round objects with your lathe.