Hello Guest it is April 25, 2024, 01:27:26 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 - Pedio

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 »
61
Mach4 General Discussion / Re: Map Lua Code to ShuttlePro button
« on: May 24, 2016, 08:21:35 AM »
I would like to get the same functionality on a button for the ShuttlePro. I would like to bring the spindle on CW at a power of 1 and then toggle off if the button on the ShuttlePro is pushed again. I don't seem to understand signal scripts. I posted what I was trying to insert into the screen load script for the main screen. It fails the compile.

The laser control script works on a button; however, the screen is far away from the CNC so I would like to put it on a ShuttlePro button.

62
Mach4 General Discussion / Re: Map Lua Code to ShuttlePro button
« on: May 23, 2016, 04:10:57 PM »
I am still trying to get the spindle button to work to turn the laser on my CNC on and off for positioning the work piece. I came back to this issue after I got a couple of other things fixed on the machine. Seems there is not enough time in the day.

Sorry if I am being remedial. The code after the siglib toggles the spindle (I use this to control the laser). The code after the second end statement works when used in a button.

Do I need to insert the following code in the 'screen load' load script on the top level of the tree? Is there any place special it should be inserted? I know nothing about Lua.

-- Map laser to shuttle pro button 8
SigLib = {
[mc.OSIG_MACHINE_ENABLED] = function (state)
    machEnabled = state;
    scr.SetProperty('btnRefAll', 'Enabled', tostring(state));
    scr.SetProperty('btnRefAll2', 'Enabled', tostring(state));
    scr.SetProperty('btnGotoZero', 'Enabled', tostring(state));
    scr.SetProperty('tabJogging', 'Enabled', tostring(state));
    if (state == 1) then
        AxisEnable();
    end
end,
mc.ISIG_INPUT6 = function (state)
local inst = mc.mcGetInstance();
local sigh = mc.mcSignalGetHandle(inst, mc.OSIG_SPINDLEON);
local sigState = mc.mcSignalGetState(sigh);
if (sigState == 1) then
    mc.mcSpindleSetDirection(inst, 0);
else
    mc.mcSpindleSetDirection(inst, 1);
    local rpm = 1;    -- Set this to the actual RPM you want as your starting point
    mc.mcSpindleSetCommandRPM( inst, rpm );
end

63
Two problems and two people. I chimed in because I am having the same problem - Pedio.

I have my M4 logging to see if I can catch the same thing as Vandabrackin. So far it has been behaving and has not locked up.

64
This is what I have for my set up.

65
The problem occurs when I can see the toolpath on the screen. I did load the Gcode file before I zeroed out the axis so the toolpaths were off from where they should be.
I will play with this some more and see if I can replicate the problem.

66
I had it before the upgrade. Also, I have been meaning to check the toolpath display. Sometimes I forget and load the Gcode before I zero the axis so the tool path may be off of the display area. I have not tried to see if there was any correlation.

If I run the machine into the limit / home switch a couple of times I can usually get it to replicate the problem; however, occasionally it does it when running a file. It may get half way through and just stop at a toolchange. I can usually get the line number, disable M4, enable M4 press the Goto zero button, and restart M4 (sometimes have to use the task manager to kill M4 after I exit the program). I can then restart M4, reload the Gcode, amd start it at the line where it stopped.

The code does not really lock up. If I disable M4 and reenable it the Gcode will often progress to the next tool change and then stop.

I will play with the machine and see if the toolpaths are showing when the problem occurs.


67
Also, the problem seems to occur more often after I hit a limit switch while jogging the machine.

68
I have a similar problem that has been plaguing me. Most of the time the code runs fine; however, occasionally it will freeze on a spindle command. It grays out the cycle start button. I can disable M4 and reenable it but the code will just jump to the next spindle command without moving or anything. I can move the machine with the GoTo Zero button but it will not run Gcode. Most of the time I have to shut down M4 and restart it. Occasionally when I am doing this it tells me another version of M4 GUI is running. I have to use ctrl+alt+del to kill the process before it will let me do anything else.

I am running as administrator
I checked for accel and decel in the spindle box.
The wait for spindle to stabilize box was not checked but the value was 90 - I changed this to 1 (it would not let me insert 0).

Thoughts?

69
Mach4 General Discussion / Re: Shuttle Pro plugin - When?
« on: April 29, 2016, 09:03:56 AM »
Check to see what jog increment you have Mach 4 set to. I had this same problem. It was jogging just not fast enough for me to see.  The inner and outer wheel look to see what the jog increment is set to and then takes a % of that increment.

70
Mach4 General Discussion / Re: Shuttle Pro plugin - When?
« on: April 27, 2016, 10:13:51 PM »
I have been using the shuttlepro for the past several months with M4. Works fine. The jog wheels increments are set by the jog increment in M4 so if you change the increment in M4 it will change the jog wheels on the ShuttlePro.

Also, be careful that you do not have anything programed for M4 in the ShuttlePro control panel or both commands will execute. You might want to run ShuttlePro as administrator. there are some flukey things that can happen if you do not.


Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 »