681
Mach4 Videos / Re: Mach4 Quicky #3 Using wxTimer
« on: May 21, 2016, 05:05:13 PM »
That is a good one Daz! Very useful. Thanks!
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.
--Change this ***********************
-------------------------------------------------------
-- Set Feedback Ratio DRO
-------------------------------------------------------
--local spindlerpm = scr.GetProperty('droSpindleRPM', 'Value');
--local truerpm = scr.GetProperty('droTrueRPM', 'Value');
--local feedbackratio = (truerpm / spindlerpm);
--scr.SetProperty('droFeedbackRatio', 'Value', tostring(feedbackratio));
--To this ********************************
-------------------------------------------------------
-- Set Feedback Ratio DRO
-------------------------------------------------------
local range, rc = mc.mcSpindleGetCurrentRange(inst)
local fbratio, rc = mc.mcSpindleGetFeedbackRatio(inst, range)
scr.SetProperty('droFeedbackRatio', 'Value', tostring(fbratio))