Hello Guest it is March 29, 2024, 11:07:42 AM

Author Topic: Set Rapid Override insurmountable limit with panel keys.  (Read 963 times)

0 Members and 1 Guest are viewing this topic.

Set Rapid Override insurmountable limit with panel keys.
« on: January 28, 2020, 06:31:44 AM »
hi, I immediately ask the question.
I would like to impose an insurmountable limit in Rapid Override in Mach4.
I will explain.
with CSMIO I have the possibility to constrain both Feed Override and Rapid Override with a single potentiometer, and this is very convenient!
the problem arises when a new gcode written on the machine occurs.
to maintain the correct feed you must keep the value of 100%.
the problem is that even the rapids are at 100% of the value.
I would like to impose an insurmountable limit on the Rapid Override type 5% 25% 50% 75% 100% via panel buttons.

this however must not affect the Feed.
hypothesis.
I press button at 25%
keeping the potentiometer at 100% to keep the Feed programmed, the rapids must not go beyond its 25% speed.
it's possible to do it ??
« Last Edit: January 28, 2020, 06:35:31 AM by daniba73 »

Offline smurph

*
  • *
  •  1,544 1,544
  • "That there... that's an RV."
    • View Profile
Re: Set Rapid Override insurmountable limit with panel keys.
« Reply #1 on: February 02, 2020, 02:45:44 PM »
mc.mcCntlSetRRO(inst, percent)

Put a global RRO control variable in your screen laod script

masterRRO = 0 -- let 0 equal the normal state where the potentiometer controls both the FRO and RRO.

Then in a button left up event script for the 25% button:

inst = mc.mcGetInstance()
local rc = mc.mcCntlSetRRO(inst, 25);
if (rc ~= mc.MERROR_NOERROR) then
    mc.mcCntlSetLastError(inst, "RRO to 25% failed!!!")
end
masterRRO = 25 -- set the global variable.

Now, you will probably have to do some work in whatever code evaluates your potentiometer and make it NOT adjust the rapid rate override while one of your % buttons is in effect.  Test for masterRRO == 0 for normal FRO/RRO operation and masterRRO ~= 0 for keeping the pot from affecting RRO. 

Steve
Re: Set Rapid Override insurmountable limit with panel keys.
« Reply #2 on: February 04, 2020, 02:46:56 AM »
Hi,
in this period I am out on business.
as soon as possible I try!
thank you!
Re: Set Rapid Override insurmountable limit with panel keys.
« Reply #3 on: December 28, 2020, 10:23:20 AM »
Sorry, sorry huge delay !!
I have had various difficulties that have kept me away from my hobby!
I gave you wrong instructions at the beginning of the post.
I want to create the keys on the Mach4 screen and not from the panel.
can you kindly explain to me what steps I have to take?