My DIY LCNC + Mesa machine - sanity check please!

More
20 Feb 2013 06:44 #30339 by arvidb
Would this work?
loadrt timedelay names=Y,Z,A,S

timedelay.Y.on-delay = 1
timedelay.Y.off-delay = 0.1
timedelay.Z.on-delay = 2
timedelay.Z.off-delay = 0.2
timedelay.A.on-delay = 3
timedelay.A.off-delay = 0.3
timedelay.S.on-delay = 4
timedelay.S.off-delay = 0.4

net machine-power timedelay.Y.in timedelay.Z.in timedelay.A.in timedelay.S.in <= halui.machine.is-on

net X-power hm2_5i25.0.7i77.0.0.output-00 <= X.out
net Y-power hm2_5i25.0.7i77.0.0.output-01 <= timedelay.Y.out
net Z-power hm2_5i25.0.7i77.0.0.output-02 <= timedelay.Z.out
net A-power hm2_5i25.0.7i77.0.0.output-03 <= timedelay.A.out
net S-power hm2_5i25.0.7i77.0.0.output-04 <= timedelay.S.out


loadrt not names=estop

net estop halui.estop.activate not.estop.in <= hm2_5i25.0.7i77.0.0.input-00
net not-estop halui.estop.reset <= not.estop.in

Especially the halui.estop.activate/halui.estop.reset part seems a bit fishy... ?

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

More
25 Feb 2013 01:59 #30529 by andypugh

Especially the halui.estop.activate/halui.estop.reset part seems a bit fishy... ?


Sorry to take so long to reply, I have been away.

I think that the time delays ought to work as you have them.

I am not using the halui pins in my own setup, my e-stop delay and logic uses other pins.
#E-Stop and machine-on
setp oneshot.0.falling 1
setp oneshot.0.rising 0
setp oneshot.0.retriggerable 1
setp oneshot.0.width 10 #10 second delay before machine can be on after off.
net estop-sw0 estop-sw.in-00 hm2_5i23.0.7i64.0.0.input-06-not
net estop-sw1 estop-sw.in-01 hm2_5i23.0.7i64.0.0.input-07-not
net estop-sw2 estop-sw.in-02 <= oneshot.0.out-not
net estop-loop estop-sw.and => iocontrol.0.emc-enable-in 
net amp-enable axis.0.amp-enable-out oneshot.0.in
#Servo Power (08) 8i20-enable 12
net amp-enable hm2_5i23.0.7i64.0.0.output-08 hm2_5i23.0.7i64.0.0.output-12
estop-sw is a "logic" component set up as a 3-input AND gate. It is easy enough to add other inputs later.

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

More
04 Mar 2013 10:00 #30816 by arvidb
No problem, I've been busy with other things as well!

I haven't had time to look more into the time delay code, but I have been able to run one of my servos from PnCConf's Open Loop Test via the 7i77 Mesa card. Worked like a charm! :)

Now I have to get hold of a fitting cabinet to hold everything...
Attachments:

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

More
28 Mar 2013 07:05 #31988 by arvidb
When I first ran latency-test on the computer that I want to use to run LinuxCNC, I first got jitter figures of >200 µs when surfing the web while also running a couple of large glxgears windows. Idle latency was something like <20 µs, but when opening or sometimes when closing large web pages, it would shoot through 200 µs on the servo thread repeatably. It even reached 250 µs.

This on a Core2 Duo with a radeon card, running the open source drivers.

Well, today I tested booting with isolcpus=1. That brought the worst-case latency down to about 65 µs (servo thread, same tests as above).

I have servos and Mesa cards, so I won't be running a "base thread", only the servo thread. I also read somewhere that reducing the period of the servo thread can reduce the latency, since the thread may then be kept in cache, instead of being ousted by other running processes.

After looking at the latency-test scrips I realised that it is possible to run it with only one thread (see here for details). I first tried running it like this:

$ latency-test 250

But that gave me one 10 ms thread and one 1 ms thread instead of the expected single 250 µs thread. (A bug in latency-test?)

But running it like this:
$ latency-test 250us 250us

gave me the single 250 µs thread that I wanted. And now with a jitter that never went much above 20 µs, and that only once! Otherwise it was rock steady at <12 µs.

So I'm very satisfied right now! :)

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

More
30 Mar 2013 20:30 #32092 by PetefromTn
I ran into the same kinds of decisions when I started the Cincinnati Arrow 500 retrofit I am currently working on. After a lot of questions on here and other forums I came to the conclusion that you really do need a limit and a home switch per axis. My machine came with both after investigation and ultimately your limits on anything more than a small hobby machine need to be exactly that emergency limits, hard stop,remove power from the drives limits.... they must also be independent of any software or unreliable circuitry. My machine setup now will remove power from the motors. Luckily the drives I am using have two power inputs. One side controls the logic and encoder stuff, the other is the main power for the drives. It is the latter that is removed in the event of an estop or a limit switch trip. Due to thus dual power input in this scenario I will not lose encoder position thankfully. We then use a momentary pushbutton to override the limit switch which allows you to jog off the switch slowly and carefully. I'm in agreement with PCW in that a limit on any sort of powerful machine must be a last ditch emergency stop before any machine damage should occur. You then setup soft limits to control your day to day machine envelope control setup which by most accounts here are dead reliable. Good luck man...peace

Pete

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

More
01 Apr 2013 01:49 - 01 Apr 2013 01:51 #32131 by arvidb
Pete, thanks for your input. I will use software-independent limits for sure (limit switches will be directly wired to the drives). And I will try to get away without a separate home switch -- since my drives block motion in only the limit-indicated direction, this might work. If it doesn't work, I will use separate home switches.
Last edit: 01 Apr 2013 01:51 by arvidb.

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

More
07 Nov 2013 23:42 #40635 by jimmy111
So what happened to this?

About the limits. Use both home and over travel limits. Ive seen mills destroy themselves when someone disconnected them.
These sigma series amps do have built in limits but what happens if it goes into uncontrollable motion before it sets its home? It dosent know where it is yet because the usually incremental encoders are used not absolute ones.

Generally these amps use serial communications with another computer and receive motion commands. Not a current or voltage signal. How does Linux-cnc interface with this? Anyone know?

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

More
17 Apr 2014 19:42 #46029 by arvidb
Hi, sorry for not answering for ages. Not only have I been busy with other things, I also managed to forget my password for the forum, and then the "Forgot your password?" function has refused to work for me as well. Anyway...

The sigma amps does not have in-built limits, but they do have overtravel inputs, which kills movement in the direction concerned. These will be hard-wired to proper limit switches. I will also try to use these as home limits.

The amps I'm using (Sigma I) are old enough to have analog inputs.

A guy named Andreas Schiffler has made some real cool progress in using modern drives controlled by EtherCAT using LinuxCNC:
(also see his other videos, some are in german and some are in english). As I understand it, EtherCAT support will not (ever) be directly integrated into LinuxCNC, since all EtherCAT master implementations require a license from the patent holder (this is free, but not compatible with "libre" open source).

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

Moderators: cncbasher
Time to create page: 0.141 seconds
Powered by Kunena Forum