disable home button while running

More
15 Apr 2011 17:01 #8960 by BigJohnT
piasdom wrote:

The signal is outside-lights <


wouldn't this be the electric "in"

No, that is the signal

the out pin is the wall-switch
the in pins are 4 outside-lights <


and the wall-switch connecting these

The imaginary electric goes to wall-switch and the switch is an "out" pin.

The lights are the "in" pins.


John

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

More
15 Apr 2011 17:11 #8963 by piasdom
So is your task to protect the rapid home button like you did the others?

don't know what you mean by protect. the second line is the protection?
i know net "connects". then the "name-i-choose"(always here)
then (any order)pin or sig(depending on what i'm doing).
i know if pin is "out", i can't change that,as with "in".
what i can't get is why(how) you picked halui.program.is-idle
as the sig.? halui.program.is-idle is an "out" pin. they were other"out"
pin to choose from. i can't use that pin again and i want to understand,
in another and2 how do i know "which" to choose.any "in" or "out"(whichever
i need at the time) that is not being used ?

net rapid-home and2.3.in0 <== pyvcp.rapid-to-home
net all-rapid and2.3.in1 <== halui.program.is-idle <---if i change this to halui.mode.is-joint,it works but doesn't do what i want
net remote-rapid-home halui.mdi-command-00 ==> and2.3.out

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

More
15 Apr 2011 17:32 #8965 by BigJohnT

i know net "connects". then the "name-i-choose"(always here)
then (any order)pin or sig(depending on what i'm doing).


The "name-i-choose" is the sig or signal for the full name and must be second in the net command line.

what i can't get is why(how) you picked halui.program.is-idle
as the sig.?


Where did anyone but you pick halui.program.is-idle?

i can't use that pin again and i want to understand,
in another and2 how do i know "which" to choose.any "in" or "out"(whichever
i need at the time) that is not being used ?


You choose a pin by the function of the pin. If you have linked an "out" pin once to a sig (signal) once then you can't link the same pin again, however you can use the sig(signal) name many times.

John

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

More
15 Apr 2011 17:45 #8966 by andypugh
piasdom wrote:

what i can't get is why(how) you picked halui.program.is-idle
as the sig.? halui.program.is-idle is an "out" pin. they were other"out"
pin to choose from. i can't use that pin again and i want to understand,
in another and2 how do i know "which" to choose.any "in" or "out"(whichever
i need at the time) that is not being used ?


No, you need to choose a pin that has the behaviour you want. And you can only work that out by reading the documentation (for motion, halui, and the realtime components).

You can get a long way by looking at machine->hal configuration and seeing which pins change state in the way that you want.

(Note that you can't link parameters…)

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

More
15 Apr 2011 17:52 - 15 Apr 2011 18:00 #8967 by piasdom
BigJohnT wrote:

i know net "connects". then the "name-i-choose"(signal name)(always here)
then (any order)pin or sig(depending on what i'm doing).

The "name-i-choose" is the sig or signal for the full name and must be second in the net command line.


what i can't get is why(how) you picked halui.program.is-idle
as the sig.?

Where did anyone but you pick halui.program.is-idle?

no one. i was trying to make a new button(all by myself:) to disable home when program
is running. so i went looking for out pins

i can't use that pin again and i want to understand,
in another and2 how do i know "which" to choose.any "in" or "out"(whichever
i need at the time) that is not being used ?

You choose a pin by the function of the pin. If you have linked an "out" pin once to a sig (signal) once then you can't link the same pin again, however you can use the sig(signal) name many times.
John


your button;
net home-x-btn and2.0.in0 -- pyvcp.just-home-x
net home-in-manual and2.0.in1 -- halui.mode.is-manual
net home-x halui.joint.0.home -- and2.0.out

how did you know to use halui.mode.is-manual and then halui.joint.0.home
i know joint.0. is linked to the out pin(and2.0.out) and
mode.is-manual linked to 2.0.in1
why did you choose halui.mode.is-manual and not halui.mode.is-joint?

they are both out pins
they both work, but is-joint not as it should
Last edit: 15 Apr 2011 18:00 by piasdom.

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

More
15 Apr 2011 18:00 #8968 by BigJohnT
I picked halui.mode.is-manual as it is only "on" when EMC is in manual mode.

halui.joint.0.home is an "in" pin.

when your pyvcp button is pressed it's pin (an "out" pin) is "on"
when EMC is in manual mode halui.mode.is-manual is "on"

When both out pins connected to the in pins of the and2 are "on" then the and2.out pin is also "on".

The and2.out is connected to halui.joint.0.home. So when and2.out is "on" it makes joint 0 (your X axis) home.

John

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

More
15 Apr 2011 18:10 #8969 by piasdom
ok a lot better
didn't know what the button was doing exactly.

when your pyvcp button is pressed it's pin (an "out" pin) is "on"
when EMC is in manual mode halui.mode.is-manual is "on"

but couldn't you have chosen halui.program.is-idle,
it's idle as it is in manual mode ?

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

More
15 Apr 2011 18:18 #8970 by BigJohnT
Almost, but not quite. When a program is idle you may not be in manual mode, you may be in MDI mode and that would be an error to try and home when your in MDI mode. However if your in manual mode your not in a running program and your not in MDI mode so it is a better choice for this task.

Your catching on! :)

John

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

More
15 Apr 2011 23:40 #8978 by piasdom
sorry i've been gone.
i think that's my problem, i'm not thinking of what the machine is doing at the time i want the button to work.
i'll have to work on that. "IF" i can get that in my head, ya'll work/time won't be in vane :)

i'm at home, i'm gonna load emc2 on another drive and work on just that :)
(if wife doesn't change my mind for me:)
THANKS

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

More
17 Apr 2011 16:40 - 17 Apr 2011 17:11 #9003 by piasdom
does pyvcp.xml work in emc sim.
i have no machine, and trying to make buttons.
the button show in axis, but doesn't work.
error msg says pyvcp.home-all pin doesn't exist.
Thanks

emc2.4.6
Last edit: 17 Apr 2011 17:11 by piasdom.

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

Time to create page: 0.406 seconds
Powered by Kunena Forum