On Friday 08 February 2019 22:07:12 Jon Elson wrote:

> On 02/08/2019 03:29 PM, Gene Heskett wrote:
> > Greetings Jon;
> >
> > I need a man page for the boot module.  And an example piece of hal
> > showing how its used.
>
> Well, I didn't write it, I think I saw the code a long time
> ago, maybe I got it from another user and sent it to you.
> (I assume you are talking about something to give the pulses
> to the Pico Systems PWM servo amp to get it out of the
> disabled state.)
>
> What you need is to sense when the enable goes true, and
> then give a short pulse on PWM with the DIR input in each
> state, and then go over to normal operation.  These pulses
> can be around 2 us wide, and just even one in each state of
> DIR will clear the disabled state in the gate drivers.
>
> So, it seems to be strongly designed for multiple axes of
> the motion system, not for the spindle.
> But, it should still work.  Inputs are :
> enable  (bit)
> pid0 .. pid3 (float)
> and the outputs are :
> pout0 .. pout3  (float)
>
> On the first servo cycle when enable goes from 0 to 1, it
> generates a value of 0.05 for one servo cycle, then a value
> of -0.05 for one cycle, then passes pid0 through to pout0,
> and the same for the other 3 axes.  I have no idea what the
> Mesa PWM generator does with a value of 0.05, this might or
> might not give a reasonable pulse width to the PWM input of
> the servo amp.
>
> Or, you could strip out all the excess and make it a
> single-channel version.
>
> Jon
>
In re the boot.comp module, I did that before I built it, but I raised 
the pulse during the boot to a 50% pulse.

And I just got it working, turns out to be a timeing problem.  I wasn't 
getting the proper dir polarities sent to the +dir of your pwm servo 
amp.

Since the boot module is the last thing in the signal path before being 
fed to the pwmgens, and its normally a passthru it turned out the dir 
pulse to be a servo-thread late to the party, so the servo was not 
getting "booted". So now I have:

addf boot.spindle servo-thread # pout0 feeds abs_piddir.in
addf abs_piddir   servo-thread # abs_piddir.sign feeds 7i76 spindir
in that addf order and does it in the same servo-thread cycle.

So now its getting booted, and runs as if thats what its been doing for a 
2 or 3 years. But now something has killed the motor creep when the 
gearshift knob is not in position.  And I just found that, I'm using a 
mux4 for that, and feeding the unused inputs .05 but I see in an older 
file I was using .1, so the .05 just isn't enough to turn the motor. 
I'll reset that next time I call up geany.

Thats so if the spindle is running when I shift gears, whatever speed it 
was running at is dropped in 20ms or so to a creep, and that allows the 
gears to mesh, and as soon as the knob is homed & the other switch is 
closed, the spindle is brought back up to whatever it was if less than 
1500, which is motor wide open in low gear, its 3000 in high gear. And 
although the encoder spins with the motor, I've an electronic gear shift 
feeding the tach gui so it shows spindle rpm, not motor. I wrote some 
hal code to measure that to 1%, then commented it out once I had the two 
measurements.

While I was at it, I cut some of the bottom off the swarf shield hiding 
the x home switch so it could come forward, gaining over an inch of y 
motion I have really needed at times. But now I need to make a different 
sweep to keep swarf off the y screw. Never was 100% happy with the 
bellows fabric stretched across that gap. Probably a heavy felt wiper of 
some sort.

Anyway, progress. I actually used it to make some swarf tonight!




> Jon
>
>
> _______________________________________________
> Emc-developers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/emc-developers


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>



_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to