Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: smaug on September 10, 2021, 09:32:51 AM

Title: Is there a Parameter, LED, or DRO to Signify Whether Mach3 is Currently Homing
Post by: smaug on September 10, 2021, 09:32:51 AM
I've recently been learning about Mach3 after starting a new job, and can't seem to find what I'm looking for in the Mach3 Programmers Reference Manual, the MachMotion G & M Code Reference Manual, or other resources about OEM Functions and Parameters.

The product I'm working on is a desktop application that automates the control of some CNC machines, including homing up to six axes depending on the machine.
It uses the standard Mach3 API calls to start the homing process for a given axis (e.g.
Code: [Select]
DoOEMButton(1022) to home X).
It also has a component that monitors Mach3's status (e.g. is a limit switch active, are any axes moving, etc.).
If the monitor sees that any axis is moving, it needs to know if that's because Mach3 is currently homing.
I could find DROs like 33 for "X axis Ref Sw DRO" and Parameters like #5161 for "G28 home X", but am unsure if those signify whether the X axis is currently homing.

If there isn't a built-in for it, then I might just pair every call to a home button with a call like
Code: [Select]
SetParam(#100, 1) so that the monitor can check Parameter #100 to see if any axes are currently homing, and then unset the Parameter once it sees that no more axes are moving.

This is my first time posting, so any suggestions are welcome.
Title: Re: Is there a Parameter, LED, or DRO to Signify Whether Mach3 is Currently Homing
Post by: TPS on September 17, 2021, 01:22:23 PM
easier way is to use OEMLed's. they can be displayed easy on screen's.