PID Loop for stepper motors

More
6 years 8 months ago #156941 by Ameone
Dear all,
I'm currently working on implementing a PID position control with LinuxCNC for a rotary axis. The set-up includes a stepper motor with a rotary encoder. I'm attaching the HAL configuration file, I'm not really sure if everything is set-up correctly or not. Can you please check it?
Thanks,

Amedeo

File Attachment:

File Name: pid_conf.hal
File Size:2.19 KB

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

More
6 years 8 months ago #156942 by tommylight
First delete or omit the following line:
setp pid.x.maxerror .0005

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

More
6 years 8 months ago #156943 by Ameone
Replied by Ameone on topic PID Loop for stepper motors
Ok done! Any other corrections?

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

More
6 years 8 months ago #156944 by tommylight
Not that i noticed at first glance.
As you provided about 1/5 of the info, you get that same amount of help.
Attach the full files, hal and ini.
Either way, we can spot some glaring errors, but not all as i do not have the same hardware to test with.

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

More
6 years 8 months ago #156945 by Ameone
Replied by Ameone on topic PID Loop for stepper motors
Ok, I'm attaching the whole hal as well as the ini. Consider that the configuration is for a 5 axis robot, and only the first axis (axis 0) has the encoder configured. Hope it helps!

File Attachment:

File Name: moveo_step_5.hal
File Size:11.73 KB

File Attachment:

File Name: moveo.ini
File Size:9.59 KB

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

More
6 years 8 months ago #156946 by tommylight
Looks good.
Start testing and report back if you get any errors.

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

Time to create page: 0.115 seconds
Powered by Kunena Forum