On Fri, 22 Aug 2008, Sebastian Kuzminsky wrote:

> Date: Fri, 22 Aug 2008 00:56:55 -0600
> From: Sebastian Kuzminsky <[EMAIL PROTECTED]>
> Reply-To: "Enhanced Machine Controller (EMC)"
>     <emc-users@lists.sourceforge.net>
> To: "Enhanced Machine Controller (EMC)" <emc-users@lists.sourceforge.net>
> Subject: [Emc-users] hostmot2 stepgen updated
> 
> I just committed mostly working stepgen.maxvel & stepgen.maxaccel code
> to the TRUNK.
>
> Here's a trace of it moving a stepper around:
>
>     <http://highlab.com/~seb/emc2/hm2-0.10-stepgen.png>
>
> The stepgen params are visible under the halscope window: steplen and
> stepspace are 25,000 ns each, dirsetup is 200 ns, and dirhold is 0.
> That waveform gives a max rate of 20,000 steps/second.
>
> position_scale is 1600, which is the number of (micro) steps per
> revolution of my stepmotor, so my position units are "revolutions".
> maxvel is 10 rps and maxaccel is 50 rps^2.
>
> There is a discrepancy between velocity-cmd (which is what the driver is
> asking the FPGA for) and velocity-fb (which is the driver's estimate of
> actual speed based on feedback from the FPGA).  I think it's at least
> partially due to the realtime function's "period" being the thread's
> nominal period instead of the actual wallclock time between
> measurements.  It gets position-fb correctly despite the velocity confusion.


Actually if there have been no pauses caused by direction changes, the 
velocity number you feed to the FPGA will be a much more accurate velocity 
number than any measured value, the only problem now is that on the 5I20, the 
base clock for the stepgenerator comes from the PCI clock which is not 
guaranteed to be exactly 33.333 MHz (might be 33.0 might be 32 etc etc)


On other configs I have a frequency counter on the PCI clock (running from the 
100 MHz HS clock) for calibration, Maybe I should add this to HostMot2.


Another possibility is a 32 bit upcounter running at 100 MHz as a general 
purpose time reference

>
> If maxaccel is too high it can overshoot its position-cmd slightly and
> then immediately correct itself.  I'll try to fix this, RSN.
>
>
> -- 
> Sebastian Kuzminsky
> Computer Science for life, that's my direction
> Instead of b-balls, my homies throw exceptions  -- MC Plus+
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>

Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to