Hello Guest it is April 19, 2024, 12:18:21 AM

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 - RootbeerFLHX

Pages: 1
1
Mach4 General Discussion / Re: M3 Probing error THC Pokeys
« on: May 25, 2020, 07:37:46 PM »
I am having this same issue with Mach4 Plasma and Pokeys57CNC. If I type M3 into the MDI and press start it will work sometimes, and other times I get the error "MACRO ALARM; 3 The probe did not strike during our M3 touch move.". If I use G31z-3 in MDI the probe works without an issue. I've tried installing an RC filter, but that didn't seem to help.

I attached a log of my probe testing with the Plasma torch turned off. The first and the third probe were successful, the second one shows the error.

2
PoKeys / Re: PlasmaSens, Pokeys57cnc and Mach4 setup.
« on: September 27, 2019, 06:50:43 AM »
Update, turns out my PoKeys plugins were out of date. I downloaded and reinstalled the plugin the other day, and that cleared up my issue.

3
PoKeys / PlasmaSens, Pokeys57cnc and Mach4 setup.
« on: September 25, 2019, 10:11:22 PM »
I'm having an issue with setting up PlasmaSens in Mach4. In the Plasma Screen Configuration Register setting I type in PoKeys_40329/PlasmaSens HV and get the following error, "The analog input device or register you entered does not exist!!". In Pokeys software I can see the sensor working under the EasySensors setup tab. In Mach4 Register Diagnostics I am unable to find PlasmaSens. I opened a ticket with PoLabs Support, but I was wondering if anyone else had run into the same issue.

4
Mach4 General Discussion / Re: Lathe Tool Turret Change M6
« on: February 20, 2017, 10:16:04 AM »
I had to change the moves to G53 instead of G0 on the C axis, also added  turret = mc.mcAxisGetMachinePos(inst, 5).  Now the tool changer works like it should.


-- Mach4Turn Ratcheting Tool Turret

 function m6()
 
 inst = mc.mcGetInstance()
 selectedtool = mc.mcToolGetSelected(inst)
 currenttool = mc.mcToolGetCurrent(inst)
 turret = mc.mcAxisGetMachinePos(inst, 5)
 Ulock = 10 -- ' Sets the Unlock Movement in Degrees Value
 Rlock = 5 -- ' Sets the Relock Movement in Degrees Value 
 T1SafePosX =  2
 T1SafePosZ =  1.5
   
 if (selectedtool > 8) or (selectedtool < 1) then
    --DoButton(3)  --'Stop Program Run
    mc.mcCntlSetLastError(inst,"Program Stopped due to Tool Number Out of Range")
      do return end
      end
    
    
 if (selectedtool == currenttool) then
     mc.mcCntlSetLastError(inst,"Tool is the same NO tool change needed")
    do return end
    end
    
    
 
 local Tp = 0      --' Zero's the Tool Positon values DO NOT CHANGE
 
 --'------------------- Move to Safe Tool Position -----------
 mc.mcCntlSetLastError(inst," Move to Tool Safe Pos")
 mc.mcCntlGcodeExecuteWait(inst, "G53 X" .. T1SafePosX);
 mc.mcCntlGcodeExecuteWait(inst, "G53  Z" .. T1SafePosZ);
mc.mcCntlSetLastError(inst,"Safe XZ Move Completed")

--'------ Select Tool ------------------------------------
if (selectedtool < currenttool) then
 
            Turns = ((8 - currenttool) + selectedtool)
           
            Moves = turret + Ulock + (Turns * 45)
           
            mc.mcCntlGcodeExecuteWait(inst, " G53 C " ..Moves);
end

if (selectedtool > currenttool) then
            Turns =  (selectedtool - currenttool)
           
            Moves = turret + Ulock + (Turns * 45)
           
            mc.mcCntlGcodeExecuteWait(inst, " G53 C" ..Moves);
    end

if (selectedtool == 1) then
mc.mcCntlSetLastError(inst, "Tool#1 Loaded")

elseif (selectedtool == 2) then
mc.mcCntlSetLastError(inst, "Tool#2 Loaded")

elseif (selectedtool == 3) then
mc.mcCntlSetLastError(inst, "Tool#3 Loaded")

elseif (selectedtool == 4) then
mc.mcCntlSetLastError(inst, "Tool#4 Loaded")

elseif (selectedtool == 5) then
mc.mcCntlSetLastError(inst, "Tool#5 Loaded")

elseif (selectedtool == 6) then
mc.mcCntlSetLastError(inst, "Tool#6 Loaded")

elseif (selectedtool == 7) then
mc.mcCntlSetLastError(inst, "Tool#7 Loaded")

elseif (selectedtool == 8) then
mc.mcCntlSetLastError(inst, "Tool#8 Loaded")

end
--'------------ end Tool Change ------------------------
mc.mcCntlSetLastError(inst," Tool Turret LOCKING ")

mc.mcCntlGcodeExecuteWait(inst, " G52 C0" );

mc.mcCntlGcodeExecuteWait(inst, " G00 H-" ..Rlock ); --   ' Lock Turret
--,-----------------------------------------------------
 
     
     tool = selectedtool
 
 mc.mcToolSetCurrent(inst, selectedtool)


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

                                                                       
end

5
Mach4 General Discussion / Re: Lathe Tool Turret Change M6
« on: February 08, 2017, 08:31:13 PM »
Thanks! I'll give it a shot!

6
Mach4 General Discussion / Re: Lathe Tool Turret Change M6
« on: February 07, 2017, 07:37:17 AM »
So far this is what I have. Thanks to Dan Mauch for sharing his tool changer macro.
 My tool changer is a ratcheting type with 8 positions.
 Right now it will change tools if the next tool is a higher number(CW move), If it is a lower number it wants to spin CCW against the ratcheting mechanism. I'd like to be able to home the C axis and then do the tool change. I haven't figured out how to make that work, it will Home the C Axis but then it wont do the tool change after.


-- Mach4Turn 8 positon tool Turret

 function m6()
 
 inst = mc.mcGetInstance()
 selectedtool = mc.mcToolGetSelected(inst)
 currenttool = mc.mcToolGetCurrent(inst)
 Ulock = 10    --'  Sets the Unlock Movement in Degrees Value
 Rlock = 10   -- ' Sets the Relock Movement in Degrees Value 
 T1SafePosX =  2.25
 T1SafePosZ =  1.5



 
  if (selectedtool > 8) or (selectedtool < 1) then
    --DoButton(3)  --'Stop Program Run
    mc.mcCntlSetLastError(inst,"Program Stopped due to Tool Number Out of Range")
      do return end
      end
    
    

 
 if (selectedtool == currenttool) then
     mc.mcCntlSetLastError(inst,"Tool is the same NO tool change needed")
    do return end
    end
    
    
 
 local Tp = 0      --' Zero's the Tool Positon values DO NOT CHANGE
 
 
 
 --'------------------- Move to Safe Tool Position -----------
 mc.mcCntlSetLastError(inst," Move to Tool Safe Pos")
 mc.mcCntlGcodeExecuteWait(inst, "G1 F30 X" .. T1SafePosX);
 mc.mcCntlGcodeExecuteWait(inst, "G1 F40 Z" .. T1SafePosZ);
mc.mcCntlSetLastError(inst,"Safe XZ Move Completed")


 --'------ Begin Tool Change , UNLOCK turret --------------
 
 mc.mcCntlSetLastError(inst," Tool Turret UNLOCKING ")
 --mc.mcCntlGcodeExecuteWait(inst, " G91");   --'Set to INC
 mc.mcCntlGcodeExecuteWait(inst, " G52 C0");
 mc.mcCntlGcodeExecuteWait(inst, " G00 C " ..Ulock);    --'  Unlock turret
 mc.mcCntlGcodeExecuteWait(inst, " G52 C0");
 
 --'------ Select Tool ------------------------------------
 
 if (selectedtool == 1) then
 
  mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
   
    if (selectedtool > currenttool) then
       Moves =  selectedtool - currenttool
       
       Moves = (Moves * 45)
       
         mc.mcCntlSetLastError("  G00 C" ..Moves);
    end   
         
         if (selectedtool < currenttool) then
            
               Moves = ((8 - currenttool) + selectedtool)
               
               Moves = (Moves * 45)
           
        mc.mcCntlSetLastError(" G00 C " ..Moves);
    end   
       
    Tp = 0
       mc.mcCntlSetLastError(inst,"Tool#1 Loaded")
    end
--'-------------------------------------------------------------
 
    if (selectedtool == 2) then
        mc.mcCntlSetLastError(inst, "Moving to Tool# " ..selectedtool )
      
        if (selectedtool > currenttool) then
            Moves =  selectedtool - currenttool
       
            Moves = (Moves * 45)
                  
           mc.mcCntlGcodeExecuteWait(inst, " G00 C" ..Moves);
    end
                   
        if (selectedtool < currenttool) then
            
            Moves = ((8 - currenttool) + selectedtool)
               
               Moves = (Moves * 45)
                mc.mcCntlGcodeExecuteWait(inst, " G00 C " ..Moves);
    end
     
     Tp = 45
       mc.mcCntlSetLastError(inst,"Tool#2 Loaded")
    end
 --'----------------------------------------------------------
 
 
 if (selectedtool == 3) then
 
  mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
    
        if (selectedtool > currenttool) then

            Moves =  selectedtool - currenttool
           
            Moves = (Moves * 45)
                
           mc.mcCntlGcodeExecuteWait(inst, " G00 C" ..Moves);
    end
                     
         if (selectedtool < currenttool) then
               
               Moves = ((8 - currenttool) + selectedtool)
               
               Moves = (Moves * 45)
       mc.mcCntlGcodeExecuteWait(inst, " G00 C " ..Moves);
       
    end
              
   Tp = 90
      mc.mcCntlSetLastError(inst, "Tool#3 Loaded")
   
    end
--'--------------------------------------------------------------
     
    if selectedtool == 4 then

        mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
    
        if selectedtool > currenttool then
           
            Moves =  selectedtool - currenttool
       
            Moves = (Moves * 45)
       
            mc.mcCntlGcodeExecuteWait(inst, " G00 C" ..Moves);
    end   
           
         if selectedtool < currenttool then
                 
             Moves = ((8 - currenttool) + selectedtool)
            
               
               Moves = (Moves * 45)
       mc.mcCntlGcodeExecuteWait(inst, " G00 C " ..Moves);
     end
   
   Tp = 135
       mc.mcCntlSetLastError(inst,"Tool#4 Loaded")
     
    end
--'--------------------------------------------------------------
 if (selectedtool == 5) then
 
  mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
   
    if (selectedtool > currenttool) then
       Moves =  selectedtool - currenttool
       
       Moves = (Moves * 45)
       
         mc.mcCntlSetLastError("  G00 C" ..Moves);
    end                 
         if (selectedtool < currenttool) then
            
               Moves = ((8 - currenttool) + selectedtool)
               
                Moves = (Moves * 45)
           
        mc.mcCntlSetLastError(" G00 C " ..Moves);
    end   
    Tp = 180
       mc.mcCntlSetLastError(inst,"Tool#1 Loaded")
   end
--'--------------------------------------------------------------
 if (selectedtool == 6) then
 
  mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
   
    if (selectedtool > currenttool) then
       Moves =  selectedtool - currenttool
       
       Moves = (Moves * 45)
       
         mc.mcCntlSetLastError("  G00 C" ..Moves);
    end                 
         if (selectedtool < currenttool) then
            
               Moves = ((8 - currenttool) + selectedtool)
               Moves = (Moves * 45)
           
        mc.mcCntlSetLastError(" G00 C " ..Moves);
    end   
    Tp = 225
       mc.mcCntlSetLastError(inst,"Tool#1 Loaded")
   end

--'--------------------------------------------------------------
 if (selectedtool == 7) then
 
  mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
   
    if (selectedtool > currenttool) then
       Moves =  selectedtool - currenttool
       
       Moves = (Moves * 45)
       
         mc.mcCntlSetLastError("  G00 C" ..Moves);
    end               
         if (selectedtool < currenttool) then
            
               Moves = ((8 - currenttool) + selectedtool)
               
               Moves = (Moves * 45)
           
        mc.mcCntlSetLastError(" G00 C " ..Moves);
    end   
    Tp = 270
       mc.mcCntlSetLastError(inst,"Tool#1 Loaded")
   end

--'--------------------------------------------------------------
 if (selectedtool == 8) then
 
  mc.mcCntlSetLastError(inst,"Moving to Tool# " ..selectedtool )
   
    if (selectedtool > currenttool) then
       Moves =  selectedtool - currenttool
       
       Moves = (Moves * 45)
    end
         mc.mcCntlSetLastError("  G00 C" ..Moves);
                   
         if (selectedtool < currenttool) then
            
               Moves = ((8 - currenttool) + selectedtool)
               
               Moves = (Moves * 45)
           
        mc.mcCntlSetLastError(" G00 C " ..Moves);
    end   
    Tp = 315
       mc.mcCntlSetLastError(inst,"Tool#1 Loaded")
   end


--'------------ end Tool Change ------------------------

mc.mcCntlSetLastError(inst," Tool Turret LOCKING ")

   
mc.mcCntlGcodeExecuteWait(inst, " G52 C0");


mc.mcCntlGcodeExecuteWait(inst, " G00 H-" ..Rlock ); --   ' Lock Turret


mc.mcCntlGcodeExecuteWait(inst,  "G52 C" ..Tp);


--mc.mcCntlGcodeExecuteWait(inst,  "G90");   --' Reset to ABS


 
     
     tool = selectedtool
 
 mc.mcToolSetCurrent(inst, selectedtool)


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

                                                                       
end

7
Mach4 General Discussion / Lathe Tool Turret Change M6
« on: February 04, 2017, 05:26:33 PM »
Does anyone have a working lathe turret tool change macro they are willing to share? I'm new to LUA script and have no clue where to start with writing my own code.

Pages: 1