Hello Guest it is January 26, 2020, 09:42:06 PM

Author Topic: MACH4 & ESS & POKEYS pendant  (Read 1960 times)

0 Members and 1 Guest are viewing this topic.

MACH4 & ESS & POKEYS pendant
« on: March 06, 2016, 06:26:30 PM »
Hey Guys,

I have MACH4 version 2.2914, Pokeys 7.24.0.2914, and the last release of ESS plugin.

I can move the X,Y,Z axis and run gcode and all seems to work fine.

I then setup the Water Cooled Spindle using CNC4PC board C41 and the relays and the analog voltage outputs range 0-10V

So, the next step before the big switch from Mach3 was to get my pendant working which is based on the Pokeys 56U, the USB version.

The pendant works perfect on MACH3 with their plugin no issues at all.


POKEY 56U version of firmware is 3.1.68 which is the latest for this particular POKEYS it checks each time you run the POKEYS software.

First thing I configured was the Matrix keyboard which is 8x6, then the LCD 4x20, then the LED Matrix.  All of the configuration looks identical to the way it is setup under MACH3.

I decided to take this in small steps.  I decided since the Axis Selector switch (X,Y,Z,A,B) was connected directly on dedicated POKEY pins it should be easy to get working.

On the Pokeys Plugin configuration page for Pendant the following are set.
Enable Pendant Mode
Pendant on Pokeys I/O
I did NOT have the MAP pendant Signals to MACH4 checked might be an issue, not sure.

The enable Dead-man switch I could not get to work by using the 5th axis position as OFF, so I figured I can always add a dedicated switch to enable the pendant later, so I Set that switch to Always ON for debugging.
MPG1-X is switch,Pin44,inverted
MPG1-Y is switch, Pin43, inverted
MPG1-Z is switch, Pin42, inverted
MPG1-A is switch, Pin 41, inverted
MPG1-B is switch, Pin 40, inverted.
Emergency Switch, pin 55, estop switch

On the POKEYS encoder page
Encoder 1, Pin1, Pin2 is enabled.

When I save this and exit and then restart MACH4, I can get in and enable MACH4, then move the MPG selector to X,Y,or Z and spin the MPG and the axis move as expected.  So I started to get excited as this is the first time I have ever been able to get the Pokey plugin to move an axis with the MPG.  I still need to work out the dead-man switch issue so the MPG is not enabled all the time.

Next I decided to do something simple like turn on an LED on the pendant, sounds pretty simple.  The LEDS are all connected to the POKEYS on the 2nd LED Matrix.  If I use the Pokey application I can tell it to turn on all the LEDs on the pendant and that works perfect.  So the next step was to just turn on one LED from inside of MACH4.

I decided that an easy on would be "Feed Hold"

I configure MACH4 Output signals as follows:

Feed Hold, mapping enabled, Pokeys_32062 Matrix LED2, Row 6, Column 7, and did not activate it low... i actually tried it active high and low still nothing.

To test if this worked.  I exited MACH4 came back in and ensured all the configuration was still valid, and it was all exactly the same, so it saved the configuration.

Next I enabled MACH4, and loaded the roadrunner Gcode file.  I pressed cycle start and the axis start moving drawing the roadrunner.  I  press Feed Hold on the MACH4 screen and the program is paused and stops motion.  However, the Feed Hold LED on the pendant does not light up and no other LED lights up either.

Now I go back into the pokey standalone application and go to the diagnostic page to test peripherals, and manually light up R6,C7 and the Feed Holder LED lights right up perfect.

I also decided to test some of the other peripherals, I figure I should check the Matrix Keyboard, which all works perfect on prior version of Pokeys for MACH3 and the pokey application.

This time I discover the Matrix Keyboard is not seeing all the keys.  The keyboard is setup as an 8x6 keyboard.   Eight Rows 1-8, and six Columns A-F
A1,A2,B1,B2,C1,C2,D1,D2,E1,E2,F1,F2, and A5 are not working.

The next thing I discovered was I could not get the LCD to function on the Pendant either, again this is not a MACH4 issue, the standalone Pokey application would not initial the display this all works on prior versions under MACH3.

Not sure if the latest release of POKEYS had issues with the Matrix Keyboard and the LCD???

Anyway I was still trying to get some of the LEDs to light but it appears to have something to do with the MATRIX feature in the POKEYS.

Anyone else had any luck getting this stuff to work.  Thanks

Russ

 
Re: MACH4 & ESS & POKEYS pendant
« Reply #1 on: March 08, 2016, 04:56:16 PM »
After spending several hours attempting to get the pendant to work in MACH4, I finally discovered why the MATRIX LED in the POKEY unit was not working correctly.

The Pokeys' application allows you to test the various peripherals attached to the device.  When I tested the Matrix Keyboard many keys are not found and I have opened a ticket with Polabs who is investigating.

The Matrix LED was using the second display and I could turn on the LEDS attached using the Pokey application but not inside of MACH4.

The root issue for this was the fact the application shows the LED Matrix as an 8x8 matrix which is the case, however they numbered the columns from Left to Right as 8,7,6,5,4,3,2,1, so exactly backwards.

You can verify this by assigning each Row/Column combination inside of MACH4 one at a time and verify the output.  Now that I figured that part out when I hit FeedHold on the Mach4 display it indeed lights up FeedHold LED on the pendant.

The one question I have is when you assign outputs in MACH4 you seem to be limited to one output.  For example Say you want to turn on your spindle and you have a pendant with three buttons Spindle FWD, Spindle Stop, Spindle Reverse.  But you also need to send the Spindle command via ESS.  Inside of MACH4 output signals you assign Spindle On to ESS Spindle PWM, and Spindle FWD to ESS Spindle FWD, which controls the relays and the PWM signal.  Now you you also have it control LEDs in this same output?   Thanks

Russ Larson