Hello Guest it is April 17, 2024, 11:14:58 PM

Author Topic: Gage Block height problem  (Read 2349 times)

0 Members and 1 Guest are viewing this topic.

Offline Klaus

*
  •  42 42
    • View Profile
Gage Block height problem
« on: April 28, 2020, 10:37:43 PM »
Sorry I accidentally posted this in the Mach4 and it seems like I can't move or delete my post, so here it is again.

I have a weird problem.
I am using Mach3
My machine is Imported from China and are normally working without problems.

It came with a Gage block which is 15mm and I also got a script for the "Auto Tool Zero" from China which have been working for the last year without any problems.
Then today, I used it as I normally are doing and it is coming down to hit the block and then going up again as usual, but when I run the job the bit is 20mm over the surface of the material???
So then I went into "Offsets" and the number for the Gage block height are not 15mm anymore and I haven't changed anything at all.
Any way when I try to change it back to 15mm it will not change or accept any numbers???

Another question I don't fully understand:
Under "Offsets" there are 2 places where you can set the height for the Gage block - Seems like one is "Current work offset" and the other one is "Active  work offset".
What is the difference? and do I have to set the height in both places?

Hope my questions makes sense.
Thanks

Offline TPS

*
  •  2,505 2,505
    • View Profile
Re: Gage Block height problem
« Reply #1 on: April 29, 2020, 03:40:06 AM »
None of them is Setting a Special Offset.

the one in the left upper Corner is OEMDro(1001) and the set Z button uses this DRO

code of Set Z button
Code: [Select]
Code "G92.2"

'Call SetDRO(24,0)
Call SetDRO(2, ABS(GetOEMDRO(1001)))



the one in the right  bottom Corner is OEMDro(1002) and the set tool Offset button uses this DRO

code of Set tool offset button
Code: [Select]
Tool_Num = GetDRO (24)


If Tool_Num <>0 then
  Z_Shift = GetOEMDRO (1002)
  Z_Offset = GetOEMDRO ( 49 )
  Axis_Pos = GetOEMDRO(85)
  Tool_Offset = Axis_Pos - Z_Offset  -Z_Shift
  Call setOEMDRO(42, Tool_Offset)
End if
anything is possible, just try to do it.
if you find some mistakes, in my bad bavarian english,they are yours.

Offline Klaus

*
  •  42 42
    • View Profile
Re: Gage Block height problem
« Reply #2 on: April 29, 2020, 05:14:08 AM »
Hi and thanks for your answer.

I am not sure if you understand my question.

The thing is that the numbers for the "Gage Block Height" have suddenly changed from 15mm to 0.2mm and I can't change it back so it will work correctly?

Offline TPS

*
  •  2,505 2,505
    • View Profile
Re: Gage Block height problem
« Reply #3 on: April 29, 2020, 05:20:55 AM »
can you pls post your Auto tool Zero script?
anything is possible, just try to do it.
if you find some mistakes, in my bad bavarian english,they are yours.

Offline Klaus

*
  •  42 42
    • View Profile
Re: Gage Block height problem
« Reply #4 on: April 29, 2020, 06:00:33 AM »
Yes here you go.

Remember it has been working before and I have another computer where it is still working.

The machine where it is not working anymore are running Win7 and the other where it is still working is Win10
____________________________________________________________

Rem   Probe Down by leafboy77 2010-11-20 (Based On Erniebro & PEU Work)

FeedCurrent = GetOemDRO(818)    'Get the current settings, OEM DROs (818)=Feedrate DRO
ZCurrent = GetOemDro(802)   'OEM DROs (802)=Z DRO
GageH = GetOEMDRO(1001)   'OEMDRO(1001)=Gage Block Height
ZNew = ZCurrent - 300      'probe down 20 mm

Code "G90F100"         'slow feed rate to 100 MM/MIN
Rem Code "G4 P1"         'Pause 1 second to give time to position probe plate
Code "G31 Z" &ZNew
While IsMoving()
Sleep(10)
Wend
Call SetDro (2,GageH)      'DRO(2)=Z DRO

FinalMove = GageH + 10
Code  "G0 Z" &FinalMove
Code "F" &FeedCurrent        'restore starting feed rate   dr.lin 2009.10.16

Offline TPS

*
  •  2,505 2,505
    • View Profile
Re: Gage Block height problem
« Reply #5 on: April 29, 2020, 06:05:27 AM »
OK your script uses OEMDRO(1001) for the Gage Block height.

OEMDRO(1001) is on Offset page left upper Corner.

what is going on if you enter there the 15mm?
anything is possible, just try to do it.
if you find some mistakes, in my bad bavarian english,they are yours.

Offline Klaus

*
  •  42 42
    • View Profile
Re: Gage Block height problem
« Reply #6 on: April 29, 2020, 08:52:17 AM »
Nothing is going whatever number i put in, it just reverse to the 0.2mm again.

Again, that script has been working ok all the time, so I am thinking if it maybe can be a Win7 update causing it, but I can't remember when I had an update.

Offline TPS

*
  •  2,505 2,505
    • View Profile
Re: Gage Block height problem
« Reply #7 on: April 29, 2020, 10:25:09 AM »
i never thought that there is something wrong with the script, i only wanted to see witch OEMDro is used.

there is a lot Information here on the Forum about Win7 updates.

you should see in System tray witch was the last installed update.

btw. you did not add any other device like handwheel or something like this witch may use OEMDro(1001)

for a quick fix, you can edit your script and enter a fixed plate thickness for test:

Code: [Select]
GageH = 15.0   'OEMDRO(1001)=Gage Block Height
anything is possible, just try to do it.
if you find some mistakes, in my bad bavarian english,they are yours.

Offline Klaus

*
  •  42 42
    • View Profile
Re: Gage Block height problem
« Reply #8 on: April 30, 2020, 11:36:30 PM »
Great thanks the modification to the script works perfect!

Cheers