Welcome, Guest. Please login or register.
Did you miss your activation email?
October 24, 2014, 10:25:54 AM

Login with username, password and session length
Search:     Advanced search
* Home Help Search Calendar Links Login Register
  Show Posts
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 »
141  Mach Discussion / General Mach Discussion / Re: Tool change macro on: February 01, 2009, 08:31:30 PM
Great  Grin
You shouldnt have any problem setting the LED in the Brain.
Its too bad Hoods SetModOutput will not work because you could just do it all from the macro without a brain  Wink
142  Mach Discussion / General Mach Discussion / Re: Tool change macro on: February 01, 2009, 08:20:29 PM
I think the best is to set a USERLED to tell the Brain it is time to rotate.

In your Brain have it look for LED2000
If LED2000 is true and tool# is not equal to current tool then get tool.

Anyways here is the complete code for something like that in your Macro:

Code:
'////MOVE THE MACHINE FOR TOOLCHANGE////
Code ("G53 G00 Z-0.200")'Move Z to position

While IsMoving() ' Wait for machine to stop
SLEEP(250)'Slow down cycle time for CPU resources
Wend

'MsgBox "Machine finished moving"

'//GET SET TOOL////
tool = GetSelectedTool() 'Gettool
SetCurrentTool( tool )'Set tool

Call SetUserLED(2000,1)'Activate Brain

'///Time wait for INPUT1
i=0'Reset timmer

Do 'Run timmer

SLEEP(500)'timmer 1/2 second intervals

 i= i+1'increment
 
 
If (IsActive(INPUT1)) Or GetOEMLED(800) Then'INPUT is active
 
  Exit Do  'exit function Continue
 
ELSEIf i>8 Then'if we have reached 4 seconds
 
 
'///Message box////
msg = "Please reseat tool and continue?"   ' Define message
title = "Tool Changer"   ' Define title
buttons = 1

response = MsgBox(msg,buttons, title)'Display message box

'///Responce was YES
If response = 1 Then' User chose Yes.

   'OK has been pressed continue
   
Else'///Responce was NO

     DoOEMButton(1021)'Estop system
     
     
End If'exit message


Exit Do  'exit function
 
End If 'INPUT ACTIVE
 
Loop



143  Mach Discussion / General Mach Discussion / Re: Tool change macro on: February 01, 2009, 03:59:48 PM
whats in your Brain?

Here timmer that waits for 4 seconds for INPUT1 to become active after that the message will appear and if "OK "is pressed continue if "cancel" is press will Estop the sytem.

Code:
i=0'Reset timmer

Do 'Run timmer

SLEEP(500)'timmer 1/2 second intervals

 i= i+1'increment
 
 
If (IsActive(INPUT1)) Then'INPUT is active
 
  Exit Do  'exit function Continue
 
ELSEIf i>8 Then'if we have reached 4 seconds
 
 
'///Message box////
msg = "Please reseat tool and continue?"   ' Define message
title = "Tool Changer"   ' Define title
buttons = 1

response = MsgBox(msg,buttons, title)'Display message box

'///Responce was YES
If response = 1 Then' User chose Yes.

   'OK has been pressed continue
   
Else'///Responce was NO

     DoOEMButton(1021)'Estop system
     
     
End If'exit message


Exit Do  'exit function
 
End If 'INPUT ACTIVE
 
Loop
144  Mach Discussion / General Mach Discussion / Re: Tool change macro on: February 01, 2009, 03:19:41 PM
OOOPPPs Undecided Undecided  Shocked Shocked  was wondering why you stated the turret was rotating before the machine got into position....I have a error in my code:
was missing the "()"...
While IsMoving() ' Wait for machine to stop
SLEEP(250)'Slow down cycle time for CPU resources
Wend

give me a sec and will post the complete code with the 4 second check for INPUT1 one to be active
145  Mach Discussion / General Mach Discussion / Re: Tool change macro on: February 01, 2009, 02:59:42 PM
The code was more for a outline but will work.

I have a message popup for "YEP" to verify that the code is working but left this for you to decide what to do...just comment out "PRINT "YEP" and/or add a result.

Let me know what part isnít working right and I can modify it:

I'll break it down here with description ...

1. Move Z to toolchange position:

Code:
'////MOVE THE MACHINE FOR TOOLCHANGE////
Code ("G53 G00 Z-0.200")'Move Z to position

2. Wait for Z to get to position:

Code:
While IsMoving() ' Wait for machine to stop
SLEEP(250)'Slow down cycle time for CPU resources
Wend

3. Get requested tool and activate turret with Brain:

Code:
'//GET SET TOOL////
tool = GetSelectedTool() 'Gettool
SetCurrentTool( tool )'Set tool

4. Wait 4 seconds and then Check to see if Input 1
*****************************Rather then waiting 4 seconds why dont we loop and check for INPUT1 to be active....if after 4 seonds it is not active popup message to user?

Code:
SLEEP(500)'Wait to see if input becomes active

5. If Input doesn't activate popup message:

Code:
'////CHECK INPUT/////
If Not(IsActive(INPUT1)) Then 'Is the imput active

Message box settings:

Code:
'///Message box////
msg = "Please reseat tool and continue?"   ' Define message
title = "Tool Changer"   ' Define title
buttons = 1
response = MsgBox(msg,buttons, title)

***6. If the user is finished resetting and presses the "OK" button then do this(HEre you can comment out  ("Print"yep"):

Code:
'///Responce was YES
If response = 1 Then   ' User chose Yes.

   ' Perform recheck issue has been fixed.
   Print"yep"


7. The user pressed "Cancel" you should estop the sytem and turn things off:

Code:
'///Responce was NO
Else

   ' Estop system ecit.
      Print"nope"
     
End If'exit message

8. Input was active and just continue running tool changer:

Code:
End If 'Input was active exit
146  Mach Discussion / General Mach Discussion / Re: Tool change macro on: January 31, 2009, 05:41:15 PM
You can mix this in with Hood's code for the MESSAGE BOX to let the operator activate the process again.


Code:
'////MOVE THE MACHINE FOR TOOLCHANGE////
Code ("G53 G00 Z-0.200")'Move Z to position
While IsMoving()' Wait for machine to stop
SLEEP(250)'Slow down cycle time for CPU resources
Wend

'////GET SET TOOL////
tool = GetSelectedTool() 'Gettool
SetCurrentTool( tool )'Set tool
SLEEP(500)'Wait to see if input becomes active

'////CHECK INPUT/////
If Not(IsActive(INPUT1)) Then 'Is the imput active

'///Message box////
msg = "Please reseat tool and continue?"   ' Define message
title = "Tool Changer"   ' Define title
buttons = 1
response = MsgBox(msg,buttons, title)

'///Responce was YES
If response = 1 Then   ' User chose Yes.

   ' Perform recheck issue has been fixed.
   Print"yep"
   
'///Responce was NO
Else

   ' Estop system ecit.
      Print"nope"
     
End If'exit message

End If 'Input was active exit
147  Mach Discussion / General Mach Discussion / Re: Modifying my M3 macro for arc initiate - Plasma Application. on: January 31, 2009, 05:29:01 AM
Great!  Grin
148  Mach Discussion / General Mach Discussion / Re: Modifying my M3 macro for arc initiate - Plasma Application. on: January 30, 2009, 01:17:55 PM
try
SystemWaitFor(INPUT1) ' Torch Input ready to go
149  Mach Discussion / Flash Screens / Re: Mach Components AGD on: January 26, 2009, 08:14:51 AM
I have had a couple request for versions later then CS3.
Here is the location for users of MX2004 - Flash 8 otherwise if you are using CS2-CS4 download the above.

http://alphagraphicdesigns.com/Download/MachCompontnes_beta_1.0F8.zip
150  Mach Discussion / Flash Screens / Re: New Member, wannabe Flash Developer on: January 20, 2009, 07:54:21 AM
Good,
I wanted to finish up "*Remote connection" on the components and I am very close to finish it...but I felt it would be best to make them avalible while I finish it up.
*Remote allows multiple "Floating" windows of mach open at once...meaning you could have every button,LED and DRO floating around your desktop on multiple monitors if you wanted.

Here is the beta let me know how it works...the final release will have hundreds of graphics to choose from and also create or import your own.

Here is the download and info:
http://www.machsupport.com/forum/index.php/topic,10291.new.html#new
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!