On Fri, 6 Jun 2008, Jon Elson wrote: > Date: Fri, 06 Jun 2008 11:11:07 -0500 > From: Jon Elson <[EMAIL PROTECTED]> > Reply-To: "Enhanced Machine Controller (EMC)" > <emc-users@lists.sourceforge.net> > To: "Enhanced Machine Controller (EMC)" <emc-users@lists.sourceforge.net> > Subject: Re: [Emc-users] PWM Amp Basics > > Kirk Wallace wrote: >> On Thu, 2008-06-05 at 21:19 -0500, Jon Elson wrote: >> ...snip >> >>> If you have a spindle encoder, you could make HAL read the encoder >>> velocity and add a correction to the PWM output. >>> >>> Jon >> >> >> It was talked about before, but I don't remember the outcome. The >> software encoder has a velocity output pin, but ppmc and other hardware >> drivers don't? >> > The PPMC driver does have "delta", which is velocity in encoder > count units. For a spindle, I guess it would be scaled from 0.0 > to 1.0, but my driver doesn't do this. It could be added fairly > easily. There might be glitches in delta when the spindle syncs > to the index pulse. Clamping the value of delta to some > reasonable maximum for the RPM and pulse count would be a good > thing to do. I'll have to do some experiments with this, I am > going to be setting up a spindle speed control to demo at the > CNC Workshop. > > Jon >
A reasonable hack might be to use the previous delta for velocity if index (and a count clear event) happened Peter Wallace Mesa Electronics (\__/) (='.'=) This is Bunny. Copy and paste bunny into your (")_(") signature to help him gain world domination. ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users