Servo-drive enable delay needed

More
02 Oct 2021 10:15 #222003 by Baderbahn
Hello guys,

after I got my encoders to work, I'm struggeling with the servo-enable timing.

I found, that as soon as I enable the machine in Gmoccapy, the servo-drives are also enabled. This particcular is a problem to me, due to the drive/ power/ E-Stop setup. 
When the machine is shut on (by Gmoccapy), the servo-drives are powered up and need a few ms before they can accept the enable signal.
So I need a time delay between machine-is-enabled and servo-enable.

I've searched the forum a lot, but was unable to find anything that really fits and works propperly.
I was able to set up a delay between my mouse-click and the machine-enable GPIO-Output signal send to the machine, but not between Machine enable and drive enable.

Maybe you have an idea on how to solve this issue :)

Thanks and best regards,
Simon

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

More
02 Oct 2021 11:27 #222005 by anfänger
you can use a delay in ladder to solve this problem

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

More
02 Oct 2021 11:46 - 02 Oct 2021 11:49 #222006 by Baderbahn
Hello Anfänger,

I tried, but how ?
The problem is, that the drive-enable pin (TB5 NAN+ & NAN-) and the machine-is-on GPIO are switched simultaneously.
I can't find a way to delay the output on TB5
Edit: in my understanding, it doesn't matter, whether I program a delay by the timedelay- HAL function or by CL. My main problem is, how to decoupple machine-is-enabled and drive-enable.

regards,
Simon
Last edit: 02 Oct 2021 11:49 by Baderbahn.

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

More
02 Oct 2021 13:38 #222013 by Aciera
Maybe post your hal file.

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

More
02 Oct 2021 13:49 - 02 Oct 2021 13:55 #222015 by Baderbahn
Yeah, I've found a way to delay the servo enable!

I added the following to my custom-hal

loadrt timedelay
addf timedelay.0 servo-thread
setp timedelay.0.on-delay 0.5

net x-enable => timedelay.0.in
net x-enable-delay <= timedelay.0.out
net x-enable-delay  => hm2_5i25.0.7i77.0.1.analogena

In the main hal-file,  I disabled

# enable _all_ sserial pwmgens
# net x-enable   => hm2_5i25.0.7i77.0.1.analogena

sometimes, life can be so easy
Last edit: 02 Oct 2021 13:55 by Baderbahn.

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

More
02 Oct 2021 15:14 #222022 by tommylight
That will also delay powering them down, so you might want to add an AND with
timedelay.0.out on one IN
and
x-enable on the other IN
while
hm2_5i25.0.7i77.0.1.analogena to AND OUT

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

More
02 Oct 2021 19:03 #222039 by Baderbahn
Hi Tommy,

good point!
I'll add this next time when I'm at the machine :)

regards,
Simon
The following user(s) said Thank You: tommylight

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

Time to create page: 0.117 seconds
Powered by Kunena Forum