Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Chaps on August 03, 2010, 10:57:09 AM

Title: Home Switch Output Signal
Post by: Chaps on August 03, 2010, 10:57:09 AM
I have Mach3 running a 24x36 woodworking table.  My Limit and Home switches work great.  However, I have an external device that I need control ONLY when Mach 3 is in the homing mode.  I want to retain the funciton of the limit switches as is.  What I need to do is to generate a signal on one of the output lines to send to my device when I request to HOME any or all of the axies.  When "homing" is complete the output signal should return to  normal state.

This appears to be more of a software issue than hardware issue.  It would appear that in the subroutine that is invoked when I click the mouse the software should generate an logic level HIGH on one of the outputs.  When the routine is completed, the output is reset to LOW.

Does anyone have any suggestions for me???? ???

   
Title: Re: Home Switch Output Signal
Post by: Hood on August 03, 2010, 11:37:12 AM
Edit the Ref All button code, for example if you want to switch OutPut 1 then it would be similar to this that you would need in the button

ActivateSignal(OutPut1)
DoButton( 24 )
DoButton( 23 )
DoButton( 22 )
DoButton( 25 )
While IsMoving()
Sleep(10)
Wend
DeActivateSignal(OutPut1)

Hood
Title: Re: Home Switch Output Signal
Post by: Chaps on August 04, 2010, 12:29:20 AM
 ;DThank you.  I will try this  and let you know.