Hello Guest it is June 20, 2021, 09:26:37 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 - jamie325i

Pages: 1 2 »
1
I have been working on trying to get the latest plasma build to work and ran into some strange issues today.

My machine uses a PMDX-410 USB SmartBOB connected to a PMDX BOB. I am using PMDX plugin version 0.52.254 because I had signal problems with the latest update.  This machine is fully functional on the GA release of Mach4 (build 3804), obviously without the Touch and Plasma features.

I started today with a clean install of build 4225 and didn't transfer anything over from previous profiles.  I am using the  defaule Mach4_Plasma Profile.  Once I configured I/O, Motors, and the PMDX plugin, I added the latest configs for the slave Z motor, enabled the THC ON signal, and setup the new Plasma Screen Configuration panel.  Note: I have not connected an arc voltage signal yet so I am running in THC manual mode for now.  I will get back to that later.

Once I homed all axes, zeroed up a piece of stock, and loaded a test file, I started testing.  Some things seem to work as expected:
-With torch powered off, the code will halt at M3 because there is no arc OK signal.  It will timeout and stop.
-with the torch on, I noticed that M3 now has a touchoff routine built-in.  This is great progress guys, I need to learn more about it.

Here is what didn't work correctly:
-The "Omit Touchoff" button initially lead to a probe move down until probe signal comes on, hung the Touch function, and then crashed Mach.  Restart required to get back into action...
-With the Touchoff routine enabled, the machine would touchoff correctly, zero the Z DRO, move up to my pierce height, fire and make the first cut.  The second M3 command would initiate a Touchoff, seek down until probe signal on, then hang.  The errors are 'PMDX DEVICE ERROR 'SYSTEM ERROR(7): Motion Calc Underrun' followed by "MACRO ALARM:3 MERROR_NOT_NOW"

For unknown reasons, the Omit Touchoff button started working after several restarts of Mach, I didnt change anything.  Unfortunately the Touch feature still hangs after the probe signal lights up.

Can anyone help me step through the config, and debug the error I am seeing?  I feel like I am close to having a fully functional plasma rig, I just need to work out the kinks. 

Thanks a lot,
Jamie



2
Mach4 General Discussion / Re: Mach4 plasma THC using Pokeys 57E
« on: June 19, 2019, 09:53:45 PM »
Hey thanks for the reply, we thought that might be the case. I will experiment with the Pokeys this week and see if I can get Mach4 to read some volts.

Jamie

3
Mach4 General Discussion / Mach4 plasma THC using Pokeys 57E
« on: June 18, 2019, 08:53:55 PM »
Hello All,
I am experimenting with the latest build of the Mach4 Plasma profile and using a Pokeys 57E analog input card to read in the divided arc voltage (I am using a variable DC source for testing, not the torch voltage).  I have set the Plasma config to the correct register and it changes with the voltage input, but I cant figure out how to relate this to an arc voltage on the THC screen. 

-We are using Mach4 build 4225 for reference
-Is there a scaling factor somewhere in the Mach4 config?
-In Pokeys, the analog value is 0-4095, which equates to 0-3.3 volts.  Once you connect Pokeys to Mach via the plugin, the Pokeys diagnostic screen shows a value of 0-1 with no units in the register.
-If you copy the Pokeys register to the clipboard and paste it into the THC config screen for the register used, when you go back to THC diagnostic the iRegs0/nf/thc/ThcActualVoltage register only reads the default 120 value, same as before changing the register. 

Any help is appreciated.
Thanks,
Jamie

4
Mach4 General Discussion / Re: TouchOff Module Error... need help
« on: January 19, 2019, 08:45:28 AM »
Hello,
What version of Mach4 are you running?  I experienced various errors and crashes when using the Touch routine in Dev version 4006 but they seem to have been fixed in version 4026.  I do not have any experience using Touch in the GA version.

Jamie

5
Mach4 General Discussion / Re: Plasma table - Dry Run feature in M3 macro
« on: January 19, 2019, 08:34:23 AM »
Hey Craig and Steve,
Thanks so much for taking the time to help me understand how all of this works.  I'm sure that others will benefit from these responses in the forum.

Hopefully you guys are involved with writing the Lua scripting manual, if not, you should be ;)

Jamie

6
Mach4 General Discussion / Re: Plasma table - Dry Run feature in M3 macro
« on: January 18, 2019, 08:42:47 PM »
Hey Steve,
thanks for tuning up my modified M3 script.  I am very new at LUA scripting so as you can see, I am just working with a basic understanding.

I am going through your version line by line trying to understand it all.  If you don't mind, I have a few followup questions.

What is local inst = mc.mcGetInstance() and why does it need to be first?

In your version, you start each section by breaking out "local *********" first, instead of all on one line.  Is that required?

Is "local rc" what gives you the ability to read the error code?

local hsig
   local rc
   hsig, rc = mc.mcSignalGetHandle(inst, mc.OSIG_OUTPUT0);

I see this at the bottom of many scripts and I read about it in the Lua manual.  What does this do?
if (mc.mcInEditor() == 1) then
    m3();

Thank you again for the help,
Jamie

7
Mach4 General Discussion / Re: Plasma table - Dry Run feature in M3 macro
« on: January 17, 2019, 09:01:21 PM »
Hey Craig,
that explanation jives with what I have been reading in the scripting manual, etc.  I don't want to over-complicate things so for now I will make the modified M3 work for what I am doing. 

Jamie

8
Mach4 General Discussion / Re: Plasma table - Dry Run feature in M3 macro
« on: January 16, 2019, 10:40:41 PM »
Hey Craig,
Sorry for the long delay, I have been tied up building a new plasma table.

I used your suggestions to make the following M3 macro changes.  It does what I need it to do: when the Dry Run button is pressed, it skips the Arc OK monitoring function and lets me run g-code with the torch off.

Once I ran it, I realized that M3 is probably not the best place to implement this feature.  It works but should probably be run outside of the g-code.  Do you know if I could run this logic in a screen script or some other place where it works while Mach4 is running?

Code below:
Thank you,
Jamie

mc.mcCntlSetLastError(inst,"Dry Run feature test");

--INITIALIZE OSIG_OUTPUT0 (INTERNAL SIGNAL FOR DRY RUN BUTTON)
local hsig = mc.mcSignalGetHandle(inst, mc.OSIG_OUTPUT0);

--READ THE STATE OF OSIG_OUTPUT0, SET buttonstate VARIABLE
local buttonstate = mc.mcSignalGetState(hsig);

--Begin modified M3 for ARC OK signal detection
local inst=mc.mcGetInstance();
mc.mcSpindleSetDirection(inst,mc.MC_SPINDLE_FWD);

--DRY RUN LOGIC SECTION
   if (buttonstate == 0) then
      
      mc.mcCntlSetLastError(inst,"Dry Run feature not activated, cutting will commence");
      mc.mcCntlSetLastError(inst,"m3 waiting for Arc");

local returncode=mc.mcSignalWait(inst,mc.ISIG_INPUT62,mc.WAIT_MODE_HIGH,2);

      if (returncode==mc.MERROR_TIMED_OUT) then

         mc.mcCntlSetLastError(inst,"Arc does not respond");
         mc.mcCntlCycleStop(inst); --end program *****
         mc.mcSpindleSetDirection(inst,mc.MC_SPINDLE_OFF);

      else;

         mc.mcCntlSetLastError(inst,"m3 Arc OK");

      end;
   
   else;
      mc.mcCntlSetLastError(inst,"Dry Run feature activated, torch will not fire");
      
   end


end

if (mc.mcInEditor() == 1) then

    m3();

end

9
Mach4 General Discussion / Plasma table - Dry Run feature in M3 macro
« on: December 31, 2018, 11:57:12 AM »
Hell All,
I created a custom M3 macro that will wait for an Arc OK signal from my plasma torch before allowing movement.  This is working well and has already improved the cut quality.  Code posted below.

Now I need to add a Dry Run feature so that I can run the G-code with the torch turned off.  The new M3 macro will of course not allow this.

I added a "Dry Run" button to my screen that turns on/off an LED, and is tied to Output0 (see picture attached).  I believe I need to put some kind of IF statement into the macro to allow the machine to move when Dry Run is enabled, even with the Arc OK signal missing.  This is also useful if I need to start the torch on an edge or in a hole.

Can anyone help with the specific code to read the state of Output0 and make my M3 macro work accordingly?

Modified M3 macro:
function m3();

local inst=mc.mcGetInstance();

mc.mcSpindleSetDirection(inst,mc.MC_SPINDLE_FWD);

mc.mcCntlSetLastError(inst,"m3 waiting for Arc");

local returncode=mc.mcSignalWait(inst,mc.ISIG_INPUT62,mc.WAIT_MODE_HIGH,2);

    if (returncode==mc.MERROR_TIMED_OUT) then

        mc.mcCntlSetLastError(inst,"Arc does not respond");
      mc.mcCntlCycleStop(inst); --end program *****
        mc.mcSpindleSetDirection(inst,mc.MC_SPINDLE_OFF);

    else;

        mc.mcCntlSetLastError(inst,"m3 Arc OK");

    end;

end

if (mc.mcInEditor() == 1) then

    m3();

end

10
Mach4 General Discussion / Re: Mach4 Arc OK THCON signal programming
« on: December 19, 2018, 11:21:52 AM »
Thanks for the suggestion Chad.  I will look into the PLC script idea.

As for the new version coming soon, I cannot wait!  The screenshots look very promising.  I am building a new plasma table now and I was not certain that I could use Mach4 to run it so this would definitely change things for me.

Thanks again,
Jamie

Pages: 1 2 »