4
« on: May 22, 2022, 02:54:58 AM »
Hi,
This post is for reference in case somebody need it.
On a machine driven by an ESS (Ethernet Smooth Stepper), i changed the mobile switch for an active one, delivering 5V if hitted. The fixed switch remains a simple passive switch. There were no way to wire both switches to the same ESS input. Since there's only 1 probe input in mach 3 settings, and an intelligent controler like ESS dont works properly with brains summing the logic of both switches connected to separated inputs, there were only 2 remaining soluions :
- The hardware one, making a little board for adaptating levels and ORing switches
- The software one.
The software on is not properly documented since it needs a function only available in 066 mach3 version. It uses a function named SetInputData. Some forums are talking about it, sometinmes unproperly named, and with wrong parameters definition. This function takes 3 parameters :
SetInputData(Mach3FunctionNum,PinNumber,ActiveLow)
- Mach3FunctionNum : Number of function as noted in machine XML definition file. Probe is 22.
- PinNumber : Port Pin Number on output Board (ie 11, 12, 13..). Beware of port number, wich must be the same for both input, since SetInputData don't have paralell port number parameter.
- ActiveLow: Mus be set to One if Active Low.
Usage :
- Setup Mach 3 settings with Probe port number with mobile switch. IE pin 11, non inverted, on port 1
- Note settings for alternate input for fixed switch. IE Pin 12 Inverted on port 1
- Modify m6nd.m1s as following (Tool Change)
Line138
SetInputData(22,11,0) ' Fixed switch
Line 162
SetInputData(22,12,1) ' Back to mobile Switch
- Modify m881.m1s ( compleete tool probing init)
Ligne 181
SetInputData(22,11,0) ' Fixed switch
Ligne 201
SetInputData(22,12,1) ' Back to mobile Switch
Modified macros will probe mobile switch with mach 3 settings, the will change pin port to reach fixed switch and will probe it, the will revert port pin to mobile switch.
This have been successfully tested on 2010 screenset + Mach3.043.066fr
Hope this will helps...
Cheers
JPC