Hello Guest it is March 29, 2024, 03:35:34 AM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - dfurlano

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 »
31
General Mach Discussion / Zeroing Z
« on: June 30, 2011, 09:46:17 PM »
I want to go to the Z limit switch and then set G54 Z to zero.

It does not consistently work.  If I run the macro twice it sets zero, just once it will not set zero.

I added the dwells figuring it needed time. Still does not work.

In desperation I post. ???


DoButton( 24 )
Code "G04 P2"
SetVar(5223,0)
Code "G04 P2"
DoButton( 23 )
DoButton( 22 )
DoButton( 25 )


TIA,

Dan


32
General Mach Discussion / Re: Z offsets
« on: March 19, 2011, 04:23:25 PM »
Here is the code if anyone wants it.  This code sends the machine to the home positions which are x-y above the probe and Z zero is all the at the top on my machine.



PlateThickness = GetUserDRO(1151) 'Z-plate thickness DRO

Code "G54"
Code "G90"

DoButton( 24 ) 'home Z
DoButton( 23 ) 'home x
DoButton( 22 ) 'home y
DoButton( 25 ) 'home a

While ismoving()
Sleep 100
Wend

Code "G90 G0 Z-3" 'moves z to just above probe

While ismoving()
Wend

Code "G90 G31 Z-4 F4" 'probing move, can set the feed rate here as well as how far to move

While ismoving()
Wend

ZProbePos = GetVar(2002) 'get the axact point the probe was hit

While ismoving()
Sleep 100
Wend

Code "G90 G0 Z" &ZProbePos 'go back to that point, always a very small amount of overrun

While ismoving()
Sleep 100
Wend

Zoffset = getvar(5223)
Cline = (ZProbePos+-3.1325) '-3.1325 Distance between center line of rotary and probe

SetVar(5243,(Cline+PlateThickness))'Set G55 Z
While ismoving()
Wend
SetVar(5263,(Cline+PlateThickness))'Set G56 Z
While ismoving()
Wend
SetVar(5283,(Cline+PlateThickness))'Set G57 Z
While ismoving()
Wend

Code "G91"
Code "G0 Z 0.1" 'retract

While ismoving()
Sleep 100
Wend

Code "G55"
Code "G90"
While ismoving()
Sleep 100
Wend
Code "G0 X0 Y0"   'move to start position
While ismoving()
Sleep 100
Wend

Code "(Z axis is now zeroed for G55, G56, G57)" 'puts this message in the status bar

Exit Sub                                                        

33
General Mach Discussion / Re: Z offsets
« on: March 18, 2011, 04:05:54 PM »
I figured it out....  I just had to post something to get me motivated.  ;D

34
General Mach Discussion / Z offsets
« on: March 18, 2011, 01:37:26 PM »
I have a setup where I cut a lot of different diameters on my rotary axis.   What I have been trying to do is set up a macro to create Z offsets and I must say I am struggling big time.   I am not sure if I fully understand how offsets work.

Here is a graphic of my set up:



1) I was thinking that the Z home position should be G54 zero.

2) I would then touch off on the probe.

3) I know what the distance is between the rotary center line and the probe (Cline = x).

4) I would then read a userdro where I would have previously entered the radius of the stock material.

5) I would then calculate Zoffset=(Cline - userdro)

6) I would then setvar (5243, Zoffset)

Well I get every number but the one I want.  Somehow it is taking the actual offset from the home position and doing all kinds of weird stuff.

Is this thinking flawed?  How should I do this.  I need Z zero to be the top of the stock

TIA Dan

35
General Mach Discussion / Re: Zeroing Multiple Z Offsets
« on: March 15, 2011, 08:34:34 PM »
Thank you.

36
General Mach Discussion / Re: Zeroing Multiple Z Offsets
« on: March 15, 2011, 08:15:20 PM »
When I look in the Mach3 manual in section 10 is says that variable 5244 is offset 2 Z, then 5263 is offset 3 Z, and 5283 is offset 4 Z.

37
General Mach Discussion / Re: Zeroing Multiple Z Offsets
« on: March 15, 2011, 08:00:31 PM »
For some reason this does not work...  G54 gets set to the correct value but the others are all off by some offset.  I tried zeroing all the values in the tool table before I started but that did not work.  I also tried adding a call and a code in front of the setvar and that did nothing.



CurrentFeed = GetOemDRO(818) 'Get the current feedrate to return to later
CurrentAbsInc = GetOemLED(48) 'Get the current G90/G91 state
CurrentGmode = GetOemDRO(819) 'Get the current G0/G1 state
PlateThickness = GetUserDRO(1151) 'Z-plate thickness DRO


DoOEMButton (1010) 'zero the Z axis so the probe move will start from here
Code "G4 P2" ' this delay gives me time to get from computer to hold probe in place
Code "G90 G31 Z-1 F5" 'probing move, can set the feed rate here as well as how far to move
While IsMoving() 'wait while it happens
Wend
ZProbePos = GetVar(2002) 'get the axact point the probe was hit
Code "G0 Z" &ZProbePos 'go back to that point, always a very small amount of overrun
While IsMoving ()
Wend
Call SetDro (2, PlateThickness) 'set the Z axis DRO to whatever is set as plate thickness
Code "G4 P0.25" 'Pause for Dro to update.
SetVar(5243, PlateThickness)
Code "G4 P0.25" 'Pause for Dro to update.
SetVar(5263, PlateThickness)
Code "G4 P0.25" 'Pause for Dro to update.
SetVar(5283, PlateThickness)
Code "G4 P0.25" 'Pause for Dro to update.
While IsMoving ()
Wend
Code "(Z axis is now zeroed)" 'puts this message in the status bar
Code "F" &CurrentFeed 'Returns to prior feed rate
If CurrentAbsInc = 0 Then 'if G91 was in effect before then return to it
Code "G91"
End If
If CurrentGMode = 0 Then 'if G0 was in effect before then return to it
Code "G0"
End If
Exit Sub    

38
General Mach Discussion / Zeroing Multiple Z Offsets
« on: March 15, 2011, 05:57:03 PM »
I use the tool macro to set the Z offset:

Call setdro (2,platethickness)

This sets whatever offset you have enabled which is usually G54.  But I would like to set multiple offsets at once like G54, G55, G56, and G57.

Is there are command that I can use to do this?

TIA

Dan.

39
VB and the development of wizards / Re: Text Message
« on: March 15, 2011, 11:31:00 AM »
BTW:

The above does work with a Verizon cell phone *********@vtext.com

The standard port has now changed from port 25 to 587

Thanks again.

Dan

40
VB and the development of wizards / Re: Text Message
« on: March 15, 2011, 09:58:21 AM »
Set objMessage = CreateObject("CDO.Message")
objMessage.Subject = "Machine Alert"
objMessage.From = """Machine #549"" <Machine#549@BR549.com>"            <-------------------------------- I am assuming here you put your email address
objMessage.To = "YOUR EMAIL ADDRESS.com"                              <------- and here you put your phone number? *********@vtext.com
objMessage.TextBody = "Machine #549 Process Completed.." & vbCRLF & "Thank You(;-)"

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 »