Hello Guest it is May 17, 2021, 09:55:10 PM

Author Topic: Set Machine Absolute zero in vb ?  (Read 6348 times)

0 Members and 1 Guest are viewing this topic.

Offline Repmo

*
  •  54 54
    • View Profile
Set Machine Absolute zero in vb ?
« on: December 08, 2008, 10:41:07 PM »
           


        I want homing my machine with the calculated position of my
 linear encoder, with my linear encoder ( Acurite ), I am able to find my position with
only 20mm mouvement(coded reference mark ), I am able with vb script to know table position ,
but I don't know how write this position in Machine Absolute Position, I want preset value in OEMDRO (83)

-I can set machine Absolute to Zero with SetABSZero(X)   but I need to Set
 numerical value
-I can set this position with G92, but the soft limit work with Absolute....
-Call SetOEMDRO(83,T)  can be good but it does'nt work


 I search function similar to SetABSZero(X) but to enter numeric value of my actual position



 Fred

Offline poppabear

*
  • *
  •  2,233 2,233
  • Briceville, TN, USA
    • View Profile
    • S S Systems, LLC
Re: Set Machine Absolute zero in vb ?
« Reply #1 on: December 10, 2008, 09:29:16 AM »
Not sure if I understand what your saying......... but,

You cant Write Machine Coordinates to Machs Machine Coordinate DROs with VB.
Once you Home Mach3, and you have liner encouders you can goto the "settings Page"
there you will see an Encoders box, push the To DRO and that will load your liner encoder value
to the DRO.  Also, you can automate this by running VB code in Macropump to indirectly "Push" this button
after you Home Mach3.

scott
Commercial Mach3 & Mach 4, Design/Build/Retrofit CNC and Industrial machines.
http://www.ss-systems-llc.com/

Offline Repmo

*
  •  54 54
    • View Profile
Re: Set Machine Absolute zero in vb ?
« Reply #2 on: December 10, 2008, 07:36:06 PM »
For My Home, I do not want Use limit swich, I want use the Index pulse in my linear encoder...

my linear encoder had coded Index pulse, It was index pluse at each 10mm, but with little different distance at each index, I am able to calcul the position with only 2 index pulse....

I will like home my machine with this index pulse, with this, I do not need to go at the end of my axis, I can home machine at any position....   (See  http://wwwpdb.heidenhain.com/ansicht/Heidenhain/media/img/571_470-23.pdf  page9)

I am just not able to set Machine Zero with this value, If I Use encoder to DRO, The soft limit does'nt work,


tanks
Fred

Offline Repmo

*
  •  54 54
    • View Profile
Re: Set Machine Absolute zero in vb ?
« Reply #3 on: December 17, 2008, 06:17:22 PM »
For now My homing with reference work good.... but not like in my dream :)
I am able to Home with only .25-.75 inch of move, anywhere on my table stroke, I need to scan 2 index on my linear encoder

I use G31 to find my reference mark on my scale,  but g31 use the machine 'software position' , for calcul the position with index, I need perfect encoder position,

after find my position with G31, I return back very slowly ( 0.5 ipm) to be able to find my index with loop in VB, I am able to GetOEMDRO(29) and set variable to calcul, I need to scan 2 index like this,

but I don't catch Index pulse every times, the VB was too slow......

--->I need function similar to G31, but when the Index pulse, save zero of my encoder...

vmax549

*
Re: Set Machine Absolute zero in vb ?
« Reply #4 on: December 17, 2008, 08:22:31 PM »
To get the speed you may require to scan the index's  I believe it will take a plugin written in C. Or you may want to try a brain. It is an interesting concept (;-)

NOW for the real question IF you are using the linear encoders as a positional reference why do you need to rehome after the initial refencing at startup. THe encoders will never lose position. There is a section in mach that allows you to input the encoder data into mach and it will display the position for you. YOu could then create a brain to track this in comparison to the known Mach position and do a compare. The encoders should ALWAYS be correct reguardless of where MACH thinks it is. IT should always be  within the operation parameters of the servo drive settings for positional error.

Just a thought, (;-)TP

Offline Repmo

*
  •  54 54
    • View Profile
Re: Set Machine Absolute zero in vb ?
« Reply #5 on: December 18, 2008, 12:18:10 AM »
I don't had physical home swich, and no limit swich, at startup I make my machine home with the coded index of my linear scale, I setup the machine position with this encoder, and after startup, In my macropump, I check the difference between linear scale and machine position..... that hold the program if the difference was too big.....

i am interested by your plugin for scan input...