Hello Guest it is March 28, 2024, 07:44:57 PM

Author Topic: Mach3 & Galil using stepper motor and encoder feedback  (Read 9453 times)

0 Members and 1 Guest are viewing this topic.

Mach3 & Galil using stepper motor and encoder feedback
« on: December 27, 2010, 11:53:11 PM »
I have recently added an encoder on the x axis of my router. The system controller is a gall 2108 card from Galil. The feedback is from  a rack and pinion ygear mounted on an encoder.
How do I configure Mach3 to use the encoder feedback to drive the x axis rather than the open loop control that I currently have. Is this possible to do with this setup? I am able the see that the encoder does work properly in the Smartterm (Galil) as the motor position does increments/decrements  as the position changes.
Thanks 

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
    • View Profile
Re: Mach3 & Galil using stepper motor and encoder feedback
« Reply #1 on: December 28, 2010, 07:18:08 AM »
Mach is open loop and if the loop is to be closed at all it will have to be done in the Galil. Whether this can be done I dont know, you would be better posting on the Galil part of the forum for answers specific to Galil.
Hood
Re: Mach3 & Galil using stepper motor and encoder feedback
« Reply #2 on: December 28, 2010, 11:53:19 AM »
thanks, I moved this post to the Galil section.

Offline smurph

*
  • *
  •  1,544 1,544
  • "That there... that's an RV."
    • View Profile
Re: Mach3 & Galil using stepper motor and encoder feedback
« Reply #3 on: December 28, 2010, 12:18:23 PM »
If you are running steppers from the Galil, then it is open loop as well.  To get closed loop, you will need to run servos.  There is no PID loop involved with stepper motors.  :(

Steve
Re: Mach3 & Galil using stepper motor and encoder feedback
« Reply #4 on: December 29, 2010, 10:19:21 PM »
It looks like galil supports that functionality, at least on some of their controllers...

http://www.galilmc.com/support/appnotes/optima/note2445.pdf

Offline smurph

*
  • *
  •  1,544 1,544
  • "That there... that's an RV."
    • View Profile
Re: Mach3 & Galil using stepper motor and encoder feedback
« Reply #5 on: December 30, 2010, 12:36:32 AM »
That's Stepper Position Maintenance (SPM).  You have to set up code to catch position errors.  Where the position error is "caught", the motor stopped, and then a POSERR subroutine is called to correct the error.  Unfortunately, this is nowhere near a closed PID loop.  :(  

Also, this "mode" of correction is not suited to the way we stream data to the controller.  We don't download a Galil script to the controller at all.  If you run the plugin and enable debug output, then you can see what we are doing by looking at the GalilDebug.txt file.  

So, unfortunately, all that the plugin supports is open loop control for stepper motors on the Galil.  :(

Steve