encoder configuration help for threading

More
15 Nov 2022 21:27 - 15 Nov 2022 21:31 #256801 by PCW
in the postgui.hal file:

net encoder-out lowpass.1.in <= encoder.0.velocity

should be

net spindle-velocity-feedback-rpm => lowpass.1.in
Last edit: 15 Nov 2022 21:31 by PCW.
The following user(s) said Thank You: Ismacr63

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 18:38 #256875 by Ismacr63

in the postgui.hal file:

net encoder-out lowpass.1.in <= encoder.0.velocity

should be

net spindle-velocity-feedback-rpm => lowpass.1.in
 

Currently with this configuration the program starts, but I don't notice any change. I have tried several frequencies but without success. The rpm bar keeps bobbing up and down a lot.
I don't know if I still have something wrong...
Attachments:

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 19:10 #256879 by PCW
try

setp lowpass.1.gain 0.005
The following user(s) said Thank You: Ismacr63

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 19:20 #256881 by Ismacr63

try

setp lowpass.1.gain 0.005


exactly the same thing happens :( you can see it in the video.

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 19:47 - 16 Nov 2022 19:48 #256887 by PCW
That's actually expected because you are not using the lowpass filter output
I would change the postgui.hal to this:


# Incluya sus comandos HAL custom_postgui aquí
# Este archivo no se sobrescribirá cuando vuelva a ejecutar stepconf
addf lowpass.1 servo-thread
setp lowpass.1.gain 0.005
net spindle-velocity-feedback-rpm => lowpass.1.in
net spindle-velocity-filtered <= lowpass.1.out => gmoccapy.spindle_feedback_bar
net spindle-at-speed => gmoccapy.spindle_at_speed_led

Note that the velocity may have other issues as it seemed to have
dropped to 0 some times which may mean an encoder reading issue.
Last edit: 16 Nov 2022 19:48 by PCW.
The following user(s) said Thank You: Ismacr63

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 20:24 #256893 by Ismacr63

That's actually expected because you are not using the lowpass filter output
I would change the postgui.hal to this:


# Incluya sus comandos HAL custom_postgui aquí
# Este archivo no se sobrescribirá cuando vuelva a ejecutar stepconf
addf lowpass.1 servo-thread
setp lowpass.1.gain 0.005
net spindle-velocity-feedback-rpm => lowpass.1.in
net spindle-velocity-filtered <= lowpass.1.out => gmoccapy.spindle_feedback_bar
net spindle-at-speed => gmoccapy.spindle_at_speed_led

Note that the velocity may have other issues as it seemed to have
dropped to 0 some times which may mean an encoder reading issue.

now it is working fine!!! Now the rpm ranges from 365 to 360-368, for example. Do you think that's right?
Something that I have observed is that the rpm does not go above 375 and I think it is due to my encoder which is 600ppr. My lathe has 2500rpm. Do you think a 100ppr encoder would be better, for example?

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 20:36 #256897 by PCW
Yes, the RPM limit is due to the combination of
basethread rate and encoder resolution. A 100 PPR
encoder should allow ~2250 RPM, with the same
base thread rate, though its unlikely that you would
need to thread at that speed...
The following user(s) said Thank You: Ismacr63

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 20:48 #256898 by Ismacr63

Yes, the RPM limit is due to the combination of
basethread rate and encoder resolution. A 100 PPR
encoder should allow ~2250 RPM, with the same
base thread rate, though its unlikely that you would
need to thread at that speed...


my lathe may be able to allow me to thread over 500 rpm. I was just wondering if it is better or not to have an encoder with 100ppr. In the future I want to put a more powerful motor with a frequency inverter to control the spindle from linuxcnc, would the encoder affect something?

Please Log in or Create an account to join the conversation.

More
16 Nov 2022 21:48 #256901 by PCW
I guess it depends on how fast you really need to thread
(or have an actual speed readout)

On a parallel port system, the encoder maximum count rate is
dependent the base thread rate and encoder PPR.

The spindle drive system doesn't affect this limit.
The following user(s) said Thank You: Ismacr63

Please Log in or Create an account to join the conversation.

More
17 Nov 2022 18:49 #256945 by Ismacr63
I wanted to thank you very much for your help. thanks greetings.

Please Log in or Create an account to join the conversation.

Moderators: newbynobiHansU
Time to create page: 0.272 seconds
Powered by Kunena Forum