Hello Guest it is April 25, 2024, 03:14:35 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 - smurph

461
The way to disable the automatic scaling of the screen elements is to develop the screen in the resolution that it will used.  E.g. 1200x1920 instead of 1024x768.  You will most likely need to start with the blank screen set, and then set the resolution before adding any elements. 

Mach 4 Industrial has tool table, offset, and in screen editor controls. 

Steve

462
I have no idea where GetXin() comes from.  :(

What is mInst?  Typically the instance is garnered with:

local mInst = mc.GetInstance('my function')

And it is usually going in a function. 

Code: [Select]
function JogAxis(axis, direction)
    local inst = mc.mcGetInstance('My JogAxis Function') -- just a label so that API tracing works. 
    if (direction > mc.MC_JOG_STOP) then
        mcJogVelocityStart(inst, axis, mc.MC_JOG_POS)
    elseif (direction < mc.MC_JOG_STOP) then
        mcJogVelocityStart(inst, axis, mc.MC_JOG_NEG)
    else
        mcJogVelocityStop(inst, axis)
    end
end

And to call that function to jog the Y axis:

Code: [Select]
JogAxis(mc.Y_AXIS, mc.MC_JOG_POS) --Jog positive
...
JogAxis(mc.Y_AXIS, mc.MC_JOG_STOP) -- Stop the positive jog

JogAxis(mc.Y_AXIS, mc.MC_JOG_NEG) --Jog negative
...
JogAxis(mc.Y_AXIS, mc.MC_JOG_STOP) -- Stop the negative jog

Steve

463
You really DON'T want to press a button with a script call.  Why?  M code scripts don't natively have access to the screen.  And the script to press a button paradigm was more of a Mach 3 thing.

What you want to do is DUPLICATE the functionality of the button in script.  You do this with the Mach API.  For example, mcJogVelocityStart/Stop will do what pressing the X jog button does, etc...

Steve

464
Mach4 General Discussion / Re: Loop Counter
« on: May 01, 2019, 12:17:03 PM »
Well...  no.  Other than the way G code already gives you.  This is usually done in the G code with a #var.  Set the var to zero before the M98 L10 call and in the sub increment the #var.

Steve

465
G10 only needs G11 if it is a multi-line or modal G10 operation.  Most G10 calls are on shots. 

Steve

466
Mach4 General Discussion / Re: Loop Counter
« on: April 30, 2019, 10:25:32 PM »
Not at the moment. 

Steve

467
Mach4 General Discussion / Re: plasma thc
« on: April 28, 2019, 06:52:35 PM »
THC only needs to be as fast as the Z motor can accelerate.  :)  The "script based" solution will probably handle > 90% of any THC application in the hobby world. 

Steve

468
Mach4 General Discussion / Re: GALIL 413x M11Px M10Px
« on: April 24, 2019, 01:04:45 AM »
No, the Galil plugin does NOT support M10/M11 in Mach 3. 

M62/M63 in Mach 4 is supported in the Mach4 Galil plugin somewhat.  What I mean by that is that the output fires immediately when received by the plugin.  But the motion attached to it will be executed buffer depth milliseconds later.  This may not make much of a difference to you if say you had a buffer of 50 milliseconds or less.  Because 50 milliseconds is pretty much instantaneous to humans.  And 50 milliseconds probalbly isn't going to make much of a difference in a plasma application either. 

Steve

469
Allan hit the nail on the head.  All of the probes, 31, 31.1, 31.2, and 31.3 will write to those variables.  The 4 probe moves are there so that a tool setting probe can be differentiated from a surface probe, etc...

Steve

470
mc.OSIG_SPINDLEON means the spindle is moving.  And there are also mc.OSIG_SPINDLEFWD and mc.OSIG_SPINDLEREV.

The motor enable is separate.  You don't need to even look at it because the above signals will do what you want. 

Steve