Author Topic: How to query current units (inch/mm) in MACH4  (Read 1313 times)

0 Members and 1 Guest are viewing this topic.

Offline simpson36

  • Active Member
  • Posts: 1,374
    • View Profile
How to query current units (inch/mm) in MACH4
« on: March 01, 2015, 08:05:12 AM »
Searched and cannot find how to query the current units being used in MACH4.

Cannot find a LuaCall for this. How is it done?

Offline MachMotion Development Team

  • Active Member
  • Posts: 55
    • View Profile
    • MachMotion
Re: How to query current units (inch/mm) in MACH4
« Reply #1 on: March 01, 2015, 09:42:39 AM »
Hi,

MACHINE_DEFAULT_UNITS = mc.mcCntlGetUnitsDefault(inst)
MACHINE_CURRENT_UNITS = mc.mcCntlGetUnitsCurrent(inst)
Andrew
MachMotion

Offline simpson36

  • Active Member
  • Posts: 1,374
    • View Profile
Re: How to query current units (inch/mm) in MACH4
« Reply #2 on: March 01, 2015, 01:49:16 PM »
Thanks!

This call is not listed in LuaCalls.txt that was distributed with MACH4

Is there another more current list available?

Offline MachMotion Development Team

  • Active Member
  • Posts: 55
    • View Profile
    • MachMotion
Re: How to query current units (inch/mm) in MACH4
« Reply #3 on: March 01, 2015, 02:08:38 PM »
I always work off of the MachAPI.h... It's formatted for C# but always up to date.

Andrew
Andrew
MachMotion

Offline simpson36

  • Active Member
  • Posts: 1,374
    • View Profile
Re: How to query current units (inch/mm) in MACH4
« Reply #4 on: March 01, 2015, 05:22:15 PM »
I always work off of the MachAPI.h... It's formatted for C# but always up to date.

Andrew

That header file is not with the MACH4 distribution. Is it available to users/developers?