Hello Guest it is April 26, 2024, 07:18:00 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 - Cbyrdtopper

431
Mach4 General Discussion / Re: coding help
« on: September 28, 2018, 10:10:30 AM »
Bill,
There are already buttons to adjust the FRO. 
But you can use the code in this post below, see if it works. 

http://www.machsupport.com/forum/index.php/topic,38406.0.html

432
Oscar,
You can make your own m30 that has the scr.StopTimer() in it.  All you have to do is make a new macro and name it m30.  
This will override the stock m30 that Mach4 uses.
Be aware of the functions that m30 takes care of automatically.  
Steve does a great job explaining what needs to be put back into a custom m30 in this thread.  His post is the 4th one down.

http://www.machsupport.com/forum/index.php/topic,33831.0.html

So when you make a custom m30, be sure to add back in the listed functions as well as adding your scr.StopTimer().

433
Mach4 General Discussion / Re: Max velocity for Nema 24 motors
« on: September 27, 2018, 08:26:07 PM »
Gerry is correct.  lol  You will know when it stalls.  The table will stop moving and it'll make a funny noise.

434
Mach4 General Discussion / Re: Max velocity for Nema 24 motors
« on: September 27, 2018, 04:42:59 PM »
I think Craig has given someone a good "formula" for stepper velocity before, somewhere on this forum.

But here at the shop, I keep bumping the velocity up a little at a time until the motor stalls; once I find where it is as fast as possible without stalling, I back off about 20%.  Works pretty good for us.

435
Daz just did a video on timer scripts.  I haven't tried this, this is just a theory.  Have a timer script to call a Feedhold and start another timer; once the second timer reaches it's limit call Cycle Start and restart the first timer.

Just an option, don't know if it would work, but that's where I would start.

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

436
Mach4 General Discussion / Re: Mach4 Spindle lag problems
« on: September 25, 2018, 08:58:40 PM »
I didn't have this problem when I first started using Mach4 on this mill.  Don't know what changed. 
I don't have this problem on any of my HiCON Integras.

437
Mach4 General Discussion / Re: Mach4 Spindle lag problems
« on: September 25, 2018, 01:52:40 PM »
My spindle does the same thing.  I'm running an AC motor with a VFD and not a servo, but none the less, after I jog it will sometimes wind down for a fraction of a second and wind back up.
Also running the ESS

438
Mach4 General Discussion / Re: PMC. Need help to toggle an output
« on: September 24, 2018, 07:12:27 PM »
As far as the FRO and SSO.  I plan on adding panel buttons to a lathe to adjust the FRO and SSO so I went ahead and worked on some code to do this.

--FRO is read from 0 - 250
--FRO + 10%
function FROPlus()
    local inst = mc.mcGetInstance()
    local FRO = mc.mcCntlGetFRO(inst)
    if FRO == 250 then
       mc.mcCntlSetLastError(inst, "Can't increase FRO anymore.")
    else
       local NewFRO = (FRO + 10)
       mc.mcCntlSetFRO(inst, NewFRO)
    end
end

--FRO is read from 0 - 250
--FRO - 10%
function FROMinus()
    local inst = mc.mcGetInstance()
    local FRO = mc.mcCntlGetFRO(inst)
    if FRO == 0 then
       mc.mcCntlSetLastError(inst, "Can't decrease FRO anymore.")
    else
       local NewFRO = (FRO - 10)
       mc.mcCntlSetFRO(inst, NewFRO)
    end
end

These are functions I made to increase and decrease the FRO by 10%.
You can add the function to a button in the signal script.  
Again, much like the coolant toggle discussion, just add this function into the signal.

The Spindle Override will read from 0.5 - 1.5.  So when you make the Script for them, just make it SSO = 1.5 and SSO = 0.5  and increase and decrease by 0.1

You can also have a "Reset FRO" and a "Reset SSO" button to set it back to 100%.
Just use the Set command and set it to FRO 100 and SSO 1
 

439
Mach4 General Discussion / Re: PMC. Need help to toggle an output
« on: September 24, 2018, 04:43:15 PM »
You started the thread on the coolant toggle.  It will be similar to that for your air blow.
Just have your m111 turn on the output and m222 turn it off.  

For your button override, just have it check the state of the air blow.  If on then turn off; if off then turn on.  This will go in your signal script.

I don't use the PMC so someone else will have to answer about running an M code from the PMC. 


440
I put this code into Mach4 on my laptop at home, it is just running the SIM but I had no issues with it disabling my jog functions or any buttons for that matter; I am unable to duplicate your issues.

I have MPGs on a mill and a lathe here in the shop.  When the MPG is set to an active state for an axis I still have keyboard and button click jogging available for all axis.