Hello Guest it is January 20, 2022, 09:23:57 PM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Tony Bullard

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 »
11
Mach4 General Discussion / Mach4 Lathe Home with limit and encoder index
« on: December 06, 2020, 07:56:27 AM »
I have encoders with index pulse on the lead screws and X and Z limit switches. I would like to home on the limit switches then move off to the first index pulse using a probing call, mc.mcCntlGcodeExecute(inst, "G31.3 X-.5000 f2"), near the end of the refAllHome function.

There is no Probe, Probe1 or Probe2 Signals under the Control Configuration Input Signals. There is Digitizing, and Probe3 through Probe9. The G31 doesn’t work even in the MDI with a probe signal from a push button for test and a LED assigned Input Signal = probe3. The LED lights but the motion doesn’t stop until G31.3 finishes. At that point the X, Z and A probe # variables are updated.

Any help with this would be appreciated. Also is the a different or better way to do this?
Thanks

12
Mach4 General Discussion / Re: How to run functions in macros
« on: February 04, 2020, 03:54:09 PM »
Thank you, RT. And thanks to DazTheGas I did get it to work following his great video.

https://www.youtube.com/watch?v=TMzAT0eb3p0

13
Mach4 General Discussion / How to run functions in macros
« on: February 04, 2020, 11:03:45 AM »
I have this function in my Screen Load Script:
----------
function SetSigState (sig,state)
      local hSig = mc.mcSignalGetHandle (inst,sig)
      mc.mcSignalSetState (hSig,state)
end
----------

It works like this in signal and button scripts:

--Example: local state = GetSigState(mc.OSIG_OUTPUT1)
       SetSigState(mc.OSIG_OUTPUT1, 1)  --turns on output 1
     Or    SetSigState(mc.ISIG_INPUT1, 0) set input 1 off

This is M code m111:
function m111()
   local inst=mc.mcGetInstance()
   
   mc.mcCntlSetLastError(inst, 'Test m111')
   
   SetSigState(mc.OSIG_OUTPUT2, 0)
end
if (mc.mcInEditor() == 1) then
m111()
end

When I run it in the debugger I get the following error:

Debugging session started in 'C:\Mach4Hobby\Profiles\TBtest\Macros\'.
m111.mcs:6: attempt to call a nil value (global 'SetSigState')
stack traceback:
   m111.mcs:6: in function 'm111'
   m111.mcs:9: in main chunk
Debugging session completed (traced 6 instructions).
Program completed in 19.11 seconds (pid: 3412).

Any help would be appreciated. Thanks, Tony


14
Mach4 General Discussion / Re: Motion Device Grounding
« on: January 05, 2020, 08:21:47 AM »
I don't know what I'm talking about but I think the ground you are referring to is the Ethernet transmit and receive common (ground) which is independent of the PC or Pokeys power ground. There is no connection between the Pokeys RJ45 contacts and the Pokeys power ground.

15
Mach4 General Discussion / Re: Motion Device Grounding
« on: January 04, 2020, 04:46:26 PM »
I took the picture while I was wiring it. The cable was not plugged into the PoKeys57E at that time. Three Ethernet cables connect the PC, PoKeys57E and the PoKeys57CNC to a router. The PC and the PoKeys57E are in the console and the PoKeys57CNC and the router are in the control cabinet.

16
Mach4 General Discussion / Re: Motion Device Grounding
« on: January 03, 2020, 09:39:49 AM »

Thanks Steve, I’ve been worried about this for a long time.
None of the devices/components NEED a common between them. The PC, PoKeys57E control panel I/O and the PoKeys57CNC motion controller communicate through Ethernet so they don’t use a ground or common. All other components like limit switches, VFDs, servo drives and solenoids are either optically coupled, galvanic isolated or relay controlled.

Katz, I use the PoRely8 driven by the PoKeys57CNC controller which is in the machine control cabinet. I use the PoKeys57E in the control console for digital and analog inputs from switches and pots. For control console outputs I use 2 open collector PoExtBusOC16s for the illuminated pushbuttons. The control cabinet and control console are 10 feet apart an this Hurco KM3P mill retrofit with Mach4 and Gecko G320X servo drives. One Ethernet cable communicates between the two.

Some pictures under construction attached:



17
Mach4 General Discussion / Re: Weird problems.
« on: January 01, 2020, 08:25:15 AM »
A little off subject but the "missing .dll" problem I had was only in "Edit debug scripts" and not in "Open script editor". Also the Zero Brane F11 key doesn't work for me in Mach4 Build 4300.

18
Mach4 General Discussion / Motion Device Grounding
« on: December 31, 2019, 03:58:57 PM »
I’m using a PoKeys57CNC Ethernet CNC motion controller and a PoKeys57E Ethernet I/O device powered by a 12 volt isolated power supply. That is the 12 volt common (Vo) is not connected to machine or earth ground. I will not be using any input signals that connect to machine ground like some probes do. Is it best to ground  it anyway or let it float which would reduce the risk of ground loops?
Thanks for any help,

Tony

19
Mach4 General Discussion / Re: msvcp140.dll missing
« on: December 30, 2019, 09:27:18 AM »
First the good news. No more errors and the editor/debug works as it should! The bad news is I don’t know exactly why. I did all as Steve said, even deleted the Mach4Hobby directory. Deleted all system32 and systemWOW64 msvcp140.dll files and uninstalled Microsoft Visual C++ 2015 Redistrubable (X86) and (x64). Installed Microsoft Visual C++ 2015 Redistrubable (X64) and Mach4Hobby. Then right back to my original problem. While working in the debugger a message came up something like this. “Some features of ZeroBrane may not work because of public/privet network settings. Click here to repair” I did and it works. I’m sorry I didn’t capture the message. I’m not much help.

Thank you all for the help.
Tony

20
Mach4 General Discussion / Re: msvcp140.dll missing
« on: December 29, 2019, 04:15:48 PM »
I also installed Microsoft Visual C++ 2015 Redistrubable (X86) for 32 bit. And reinstalled Mach4. No change.

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 »