Home
Downloads
Mach3
Plugins
CAM Post Processors
Screensets
Purchase
Support
Forum
Tutorial Videos
Documentation
Yahoo Group
Mach Wiki
Resources
Contact Us
Links
CNCZone
German Forum
Italian Forum
Korean Forum
Portugese (Brazil) Forum
Russian Forum (RSK CNCROUTER)
Thai Forum
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
May 24, 2012, 12:12:11 PM
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Search:
Advanced search
Select from and to languages
Chinese-simp to English
Chinese-trad to English
English to Chinese-simp
English to Chinese-trad
English to Dutch
English to French
English to German
English to Greek
English to Italian
English to Japanese
English to Korean
English to Portuguese
English to Russian
English to Spanish
Dutch to English
Dutch to French
French to English
French to German
French to Greek
French to Italian
French to Portuguese
French to Dutch
French to Spanish
German to English
German to French
Greek to English
Greek to French
Italian to English
Italian to French
Japanese to English
Korean to English
Portuguese to English
Portuguese to French
Russian to English
Spanish to English
Spanish to French
Machsupport Forum
Mach Discussion
VB and the development of wizards
How do I get my X, Y, and Z axis DROs to reset in this script?
Pages:
«
1
2
3
Go Down
« previous
next »
Author
Topic: How do I get my X, Y, and Z axis DROs to reset in this script? (Read 3368 times)
0 Members and 3 Guests are viewing this topic.
agauger
Active Member
Offline
Posts: 18
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #20 on:
May 17, 2009, 04:38:28 PM »
Quote
IF you just go to the VB editor and type in Setdro(0,0.000) then run it doe s the x axis DRO change to 0.000?
Yes...
I tried this for each of the 3 axis -
(Setdro(0,0.000)
for X,
Setdro(1,0.000)
for Y and
Setdro(2,0.000)
for Z. They all work perfectly. The problem must be within the script. I'll see about rewriting the script slightly simplified and see if I can identify the issue(s).
At least I know the
Setdro(0,0.000)
command works on my machine. This is a milestone in itself.
Logged
vmax549
Guest
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #21 on:
May 17, 2009, 08:03:28 PM »
OK are you saying that at the end of the macro the DROs are readiing something other than 0.000 Or do you mean the machine is out of postion by those amounts while the dros are reading 0.000. ??
I don't see anything in your code that would cause the Dro to reading other than 0.000.
BU I do see a couple of things that may leave it OUT of postion.
Just a thought, (;-) TP
(;-) TP
Logged
agauger
Active Member
Offline
Posts: 18
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #22 on:
May 17, 2009, 08:18:46 PM »
Quote
vmax549 - OK are you saying that at the end of the macro the DROs are readiing something other than 0.000 Or do you mean the machine is out of postion by those amounts while the dros are reading 0.000. ??
When the probing script completes, the mill is directly centered on the part both on the X and Y axis. Additionally the mill is at the top of the part- just touching. This is the exact position that I manually reset the X, Y, and Z DROs before running my slot cutting program. The machine positions itself exactly where it should when the probing script completes, it just resets the DROs to something other than zero.
When the
DoOEMButton(1008)
, or
Setdro(0,0.000)
cammands run at the end of the script, the result is as follows.
The X axis DRO is changed to +0.6105 (this number does vary slightly on occasion)
The Y axis DRO is changed to +0.0000
The Z axis DRO is changed to +0.4000
I have yet to try adding a delay before running the DRO reset command to give Mach3 a chance to catch the mill up to the executed code.
Quote
vmax549 - BU I do see a couple of things that may leave it OUT of postion.
If you see specific problems with the scipt, please let me know. As I mentioned before, I'm very new at this and would like to corect any mistakes I've made before they get to be habbits.
Cheers.
Logged
vmax549
Guest
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #23 on:
May 18, 2009, 08:39:27 AM »
AS long as it ends at the proper location then all is well(;-).
Try this, Delete the resetting of the DROs from the script. ADD an "end" to the end of the scriptThen let it run to completion.
Then from a seperate script do the dros resetting to zero. Just curious.
There is NOTHING I know of that will effect the Setdro() command from inside your script. It does NOT draw from any inside VAR or DRO so any errant value should NOT show up.
THE ONLY thing I can think of is that the axis has NOT stopped at the time your code is updating the value to zero so there is some overrun at times.
IF the seperate script cures the problem then on the old script BEFORE the commands to zero the dros add Code"G04 P0" this will force Mach to empty the motion buffer before doing the next command.
Just a thought, (;-) TP
(;-) TP
«
Last Edit: May 18, 2009, 08:49:36 AM by vmax549
»
Logged
eddie60
Active Member
Offline
Posts: 5
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #24 on:
May 19, 2009, 05:18:37 AM »
HI
IM HAVING PROBLEMS WITH THE MACH BLUE SCREEN SCRIPT
I USE METRIC
I HAVE TRIED CHANGING IT MYSELF, I CAN'T GET IT TO WORK
I NEED A SCRIPT THAT CAN FIND THE CENTER OF A 40 mm PIPE
AND MOVE AT ABOUT 100mm A MINUTE
CAN ANYONE HELP ME PLEASE?
EDDIE
Logged
agauger
Active Member
Offline
Posts: 18
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #25 on:
May 19, 2009, 05:42:10 AM »
Quote
Try this, Delete the resetting of the DROs from the script. ADD an "end" to the end of the scriptThen let it run to completion.
Then from a seperate script do the dros resetting to zero.
I ran the probe script and the DRO reset script seperately. They both wook as they should. I'll try your suggestion using the
END
command as well as the
G04 P0
command this evening to see if I can get everything working in a single script.
Thanks!
Logged
agauger
Active Member
Offline
Posts: 18
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #26 on:
May 21, 2009, 05:34:32 AM »
Well, the END command did not change anything. I also added the G04 P0 command but the DROs are still resetting to values other than zero. I even tried a 10 second wait command (G04 P10) but this did not change anything either. Interesting note though, the DROs changed value prior to the 10 seconds expiring.
By placing the DRO reset commands in a separate script, I can successfully get all 3 axis to reset to zero as they should.
Can you give me an example of how I would call this second script containing only the DRO reset commands from within the first script? I’ve heard calling scripts from within scripts is bad practice but it may just be the fix I’m looking for.
Thanks,
-Aaron
Logged
vmax549
Guest
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #27 on:
May 21, 2009, 09:21:09 AM »
(;-) OK try this Before the DRO updating
While ISMOVING()
Sleep (2000)
Wend
You can try the macro from a macro BUT beware strange things have been known to happen.
Set up the separate code as a separate macro (say M200) then just call the macro from the first macro
Code"M200"
or just
Call M200
Heck give it a whirl, but please try the WhileIsmoving/sleep thing first
(;-) TP
Logged
ellik
Active Member
Offline
Posts: 4
Re: How do I get my X, Y, and Z axis DROs to reset in this script?
«
Reply #28 on:
May 21, 2009, 10:28:26 PM »
Another trick is to add a Sleep(300) just after calling SetDRO, especially if the next line in your script calling a moving the same axis you just changed the DRO for. It looks like there is a synchronization problem between the VB script and the mach driver (probably running in different processes or threads) Otherwise the next move might be executed based on the previous DRO position, not the one you just set.
This solved a problem for me anyway. Worth a try.
EK
Logged
Pages:
«
1
2
3
Go Up
« previous
next »
Jump to:
Please select a destination:
-----------------------------
Mach Discussion
-----------------------------
=> General Mach Discussion
=> Mach3 under Vista
=> Quantum
=> Mach SDK plugin questions and answers.
===> Finished Plugins for Download
=> VB and the development of wizards
=> Brains Development
=> Video P*r*o*b*i*n*g
=> Mach Screens
===> Screen designer tips and tutorials
===> Works in progress
===> Finished Screens
===> Flash Screens
===> JetCam screen designer
===> Machscreen Screen Designer
===> CVI MachStdMill (MSM)
=> Feature Requests
=> Non English Forums
===> Italian
===> French
===> Spanish
===> Chinese
===> German
===> Russian
===> Romanian
===> Japanese
===> Vietnamese
=> FAQs
-----------------------------
*****VIDEOS*****
-----------------------------
=> *****VIDEOS*****
-----------------------------
General CNC Chat
-----------------------------
=> Share Your GCode
=> Show"N"Tell ( What you have made with your CNC machine.)
=> Building or Buying a Wood routing table.. Beginnners guide..
=> Show"N"Tell ( Your Machines)
-----------------------------
G-Code, CAD, and CAM
-----------------------------
=> G-Code, CAD, and CAM discussions
=> LazyCam (Beta)
-----------------------------
Third party software and hardware support forums.
-----------------------------
=> LazyTurn
=> GearoticMotion Preliminary testing
=> Tempest Trajectory Planner
=> Contec
=> dspMC/IP Motion Controller
=> HiCON Motion Controller
=> Third party software and hardware support forums.
=> Galil
=> Newfangled Solutions Wizards
=> Mach3 and G-Rex
=> Mesa
=> Modbus
=> NC Pod
=> PoKeys
=> SmoothStepper USB
=> Sieg Machines
=> Promote and discuss your product
-----------------------------
Tangent Corner
-----------------------------
=> Tangent Corner
=> Competitions
=> Polls
=> Bargain Basement
-----------------------------
Support
-----------------------------
=> Downloads
===> XML files
===> Post Processors
===> Macros
===> Tutorials
===> Others
===> Beta Brains
===> Screen Sets
===> Documents
===> MACH TOOL BOX
=> One on one phone support.
=> Forum suggestions and report forum problems.
-----------------------------
Mach4
-----------------------------
=> Mach4 pre-Alpha Testing
Loading...