Hello Guest it is April 26, 2024, 03:29:58 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 - jevs

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 »
61
I just went out and checked this. No difference. Making a dead short on the limit switch pins during bootup does not change anything.
It still gives all the limit warnings on bootup. The signal shows rock solid in the ESS diag and trips perfectly when opened while hitting a limit.
I see no issues with the limit switches.
 It could just be the way the ESS sees the BoB signal when mach4 first starts. Not sure....
I may stick my meter right on the pin at the ess and watch it to see what happens...

62
I can test this theory pretty easy by just holding down my limit override switch at bootup. This switch shorts the limit switch pins right at the BoB. It is pretty new compared to the original limit switches and should produce close to zero ohms and no possibility of a floating or resistive connection.
I will try it tommorow night.

63
This is the way the machine was made originally by Fanuc (for Pratt & Whitney). They are mechanically actuated "electrical" switches. They mechanically make or break the electrical path. They are industrial switches with the roller tips. This is all barking up the wrong tree though. The ESS reporting things being tripped has nothing to do with the switches or being wired in series. The limit switches do not need to be wired independently. The homing switches are though.

The ESS is reporting false states at initial communications presumably because of what I quoted from the Warp9 forum. I cannot say what is is actually on the pins where it is connected to the BoB at boot up. The BoB (Machmotion IO6) and the ESS are both powered up before Mach4 boots though. the ESS is powered from the BoB.

I am not sure this is anything that can be fixed. It may just be the way it is and ignore it. It does not affect any operation. I just don't like seeing the messages at bootup when they are not real. I would have to put a scope on the pins to the breakout board and try to capture things to see what the ESS is really seeing during this time. Even if I do see it, I don't know what I could do to stop it from reporting those until things are in full communications.

64
This has to be done intentionally with soft limits off or no homing but.....
if I intentionally run it thorough the home switch and on past to hit the limit switch:
Home switch X Home tripped!
Limit switch X ++ tripped!
Limit switch Y ++ tripped!
Limit switch Z ++ tripped!
Limit switch X -- tripped!
Limit switch Y -- tripped!
Limit switch Z -- tripped!
-----ESS: Limit Switch triggered on  Motor Limit 0++  Motor Limit 1++  Motor Limit 2++  Motor Limit 0--  Motor Limit 1--  Motor Limit 2--

Limits are all tied together in series. This is why you get all of these if any is tripped.

The messages I get at boot up from the ESS are kind of random also, it is not just the "----ESS: Limit Switch triggered on" It will sometimes say other things are tripped. It is kind of random. However it does not really affect anything because hitting enable clears it all and everything works. It all works fine after that and you home it. It is just a little annoying that the ESS flags this stuff until it gets itself communicating with Mach4 at bootup even though it is not real...
It would be nice if you could turn off any initial error flagging until Mach4 is fully booted and the ESS is in full communications. 

65
Does your setup think the homing switch is a limit switch? Try setting soft limits correctly and turning them on.

No and soft limits are on and set correctly. I have separate limit switches and homing switches.
The homing switches are a bit in from the limit switches at the homing side of the axis. The Z homing is real far from the limit switch because it has to move above homing to do the tool change. It should never hit the limit switches, but if you did hit the limit switches by doing something wrong your dead in the water because they kill everything until you hold down my limit override switch to bring it off of them. It should never hit the actual limit switches during normal operation unless something is done wrong. 
When it says this stuff on boot up, no switch is active. From what they said on the Warp9 forum this could just be that it sees something active during the boot up sequence before it is all done initializing, but is not really a problem since it is not really an issue once it is all booted up and homed.

From the Warp9 forum:
"......Depending on your wiring, your specific limit switches and your break out board, your limit switch signal may very well be active (as supplied to the ESS input pin) even though your limit switch itself may not be activated. A lot depends on the power up sequence and states of that other hardware. That being said, there is no issue with just ignoring that message at startup,and as soon as you press the enable button that message will be gone (assuming you are using v246 of the ESS plugin)."

66
But that is button jogging. I cannot find a way to relate that to the MPG??? I tried a couple things and had no luck.
Are those actually the functions that can be made to work for Velocity jogging with the MPG?

67
Hi,
try Continuous mode, that's what its for.

Craig

I have been trying to figure out how to get the MPG to work in continuous mode for two days.....nowhere can I find how to do this or anything in the API that sets the MPG to continuous....

68
I have all the pendant functions working now except I have no idea how to get velocity mode.

However, I have another question besides that one that I have not figured out and it is time to quit on this for tonight.

If I do get velocity mode working or add a step that moves more than the now max .001, like say .01, it could que up a bit of moving if you spin the wheel fast. This means it could still be moving even after you stopped spinning the wheel.

What I want to know is how I can make it stop moving if the enable button is let go, but it still has not finished moving the commanded distance? It seems like it would be safer if something bad happened and you let go of the switch but it was still trying to make the queued up moves.

However, I have not thought of anything that releasing the button would not cause other moves not to work also because the state of the switch will be off normally when the pendant is not being used. So, telling it to stop anything moving when the button is released also might keep anything from ever moving. If that makes sense.

So, any ideas? Here is my code on the pendant so far. Some stuff is commented out because I ended up not needing it for now. I will clean it up when I am done. I don't know what shuttle mode is and I cannot find what it is so far. I was hoping it was another name for velocity mode, but it does not seem to do anything. I read one post about it in mach3 forums and it said something about moving through g code faster or slower...would be nice to know what it is.

I don't know what mc.mcMpgSetEnable is either, so I was trying to see if that disabled and enabled the MPG. It does not seem to, but I cannot find anything about that. You will see those commented out also and put back to setting the axis to -1.

Code: [Select]
-- Add Pokeys Inputs for Pendant Switches

--[mc.ISIG_INPUT3] = function (state) -- Y, Z, 6 on Top Pendant Switch
-- if(state == 1) then
-- PendantAxis()
-- end
--end,
--[mc.ISIG_INPUT4] = function (state) -- X, Z, 5 on Top Pendant Switch
-- if(state == 1) then
-- PendantAxis()
-- end
--end,
--[mc.ISIG_INPUT7] = function (state) -- 4, 5, 6 on Top Pendant Switch
-- if(state == 1) then
-- PendantAxis()
-- end
--end,
[mc.ISIG_INPUT9] = function (state) -- .001 on Bottom Pendant Switch
if(state == 1) then
rc = mc.mcMpgSetRate (inst, 0, 100) -- Set Pendant MPG velocity rate to 100%
rc = mc.mcMpgSetInc(inst, 0, .001) -- Set Pendant MPG incremenent to .001
else
rc = mc.mcMpgSetRate (inst, 0, 100) -- Set Pendant MPG velocity rate to 100%
rc = mc.mcMpgSetInc(inst, 0, .0001) -- Set Pendant MPG incremenent to .0001 since this position has no input
end
end,
[mc.ISIG_INPUT10] = function (state) -- V on Bottom Pendant Switch
if(state == 1) then
rc = mc.mcMpgSetRate(inst, 0, 100) -- Set Pendant MPG velocity rate to 100%
rc = mc.mcMpgSetShuttleMode (inst, 1)
--rc = mc.mcMpgSetInc(inst, 0, .001)
else
rc = mc.mcMpgSetShuttleMode (inst, 0)
rc = mc.mcMpgSetRate(inst, 0, 100) -- Set Pendant MPG velocity rate to 100%
rc = mc.mcMpgSetInc(inst, 0, .0001) -- Set Pendant MPG incremenent to .0001 since this position has no input
end
end,
[mc.ISIG_INPUT12] = function (state) -- Pendant Enable Key
if(state == 1) then
--rc = mc.mcMpgSetEnable (inst, 0, 1) -- Enable MPG
PendantAxis()
else
--rc = mc.mcMpgSetEnable (inst, 0, 0) -- Disable MPG
rc = mc.mcMpgSetAxis(inst, 0, -1) -- Sets Pendant MPG to no valid axis so it cannot move anything when not pressed
end
end,

Code: [Select]
-----Pendant functions------
--Set Pendant axis
function PendantAxis()
local inst = mc.mcGetInstance()
local in3, rc = mc.mcSignalGetHandle(inst, mc.ISIG_INPUT3) -- Y, Z, 6 on Top Pendant Switch
    local axYZ6, rc = mc.mcSignalGetState(in3)
    local in4, rc = mc.mcSignalGetHandle(inst, mc.ISIG_INPUT4) -- X, Z, 5 on Top Pendant Switch
    local axXZ5, rc = mc.mcSignalGetState(in4)
    local in7, rc = mc.mcSignalGetHandle(inst, mc.ISIG_INPUT7) -- 4, 5, 6 on Top Pendant Switch
    local ax456, rc = mc.mcSignalGetState(in7)

if ax456 == 0 and axYZ6 == 0 and axXZ5 == 0 then  -- Axis Off
        --rc = mc.mcMpgSetEnable (inst, 0, 0) -- Disable MPG
rc = mc.mcMpgSetAxis(inst, 0, -1) -- Negative one to select a non valid axis
        rc = mc.mcCntlSetLastError(inst, "Pendant Axis Off")
    elseif ax456 == 0 and axYZ6 == 0 and axXZ5 == 1 then  -- Axis X
        rc = mc.mcMpgSetAxis(inst, 0, 0)
        rc = mc.mcCntlSetLastError(inst, "Pendant Axis X Selected")
elseif ax456 == 0 and axYZ6 == 1 and axXZ5 == 0 then  -- Axis Y
        rc = mc.mcMpgSetAxis(inst, 0, 1)
        rc = mc.mcCntlSetLastError(inst, "Pendant Axis Y Selected")
elseif ax456 == 0 and axYZ6 == 1 and axXZ5 == 1 then  -- Axis Z
        rc = mc.mcMpgSetAxis(inst, 0, 2)
        rc = mc.mcCntlSetLastError(inst, "Pendant Axis Z Selected")
elseif ax456 == 1 and axYZ6 == 0 and axXZ5 == 0 then  -- Axis 4
        rc = mc.mcMpgSetAxis(inst, 0, -1) -- Minus one because their is not currently an axis 4
        rc = mc.mcCntlSetLastError(inst, "Invalid Pendant Axis Selected")
elseif ax456 == 1 and axYZ6 == 0 and axXZ5 == 1 then  -- Axis 5
        rc = mc.mcMpgSetAxis(inst, 0, -1) -- Minus one because their is not currently an axis 5
        rc = mc.mcCntlSetLastError(inst, "Invalid Pendant Axis Selected")
elseif ax456 == 1 and axYZ6 == 1 and axXZ5 == 0 then  -- Axis 6
        rc = mc.mcMpgSetAxis(inst, 0, -1) -- Minus one because their is not currently an axis 6
        rc = mc.mcCntlSetLastError(inst, "Invalid Pendant Axis Selected")
end
end

69
Mach4 General Discussion / Can someone define mc.mcMpgSetEnable ?
« on: August 28, 2019, 09:23:42 PM »
I could not find anything in the API manual to disable and enable the MPG, so I was going to do it by setting the axis to -1.

However, by dumb luck I noticed mc.mcMPGSetEnable in the editor. Hovering will give you the usual parameters, but not actually what it does of course. However I cannot find this in the API manual either.

So, does it do what I think it will do and enable/disable the MPG from working? I have coded this to the deadman (pendant enable) switch to see if it works this way, but I am still finishing the code for the pendant and have not tested it yet.

At the very least this thread may show up with an answer for the next person that searches until it gets in the API manual..

Thanks

70
Mach4 General Discussion / How to put MPG in Velocity mode?
« on: August 28, 2019, 09:16:29 PM »
Not sure how to change MPG modes from incremental to velocity only? My pendant with MPG has 3 settings (.0001, .001, V).

I can change the rate or increment, but I am unsure if these commands change the mode also?
mc.mcMpgSetRate
mc.mcMpgSetInc

I would think the rate just changes how fast it moves the increment, but maybe it also changes modes and there is no way to set the rate the increments occur?

Or... is velocity mode the shuttle mode? I cannot find anything with search so far that says what shuttle mode is or does?
mc.mcMpgSetShuttleMode

Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 »