Author Topic: PWM Output on the 422  (Read 4068 times)

it_guy

  • Posts: 17
    • View Profile
PWM Output on the 422
« on: March 02, 2015, 12:54:41 AM »
I know that this is a coming feature and I will be using it in conjunction with the SuperPID router controller for my Bosch 1617EVS Router.
So far I have the Router working with the 422, but it auto starts and when the spindle CW button is on in Mach4 it will stay at 5000 rpm. When the button is turned off after completing a cut and returning to zero or home, the router spools up to max. I am looking at my end to be sure everything is wired correctly. I do know that this feature is being added, so I am not expecting it to fully work until then. I just wanted to put it out there so everyone doing something similar (or the same thing) has a place to look at all of the configuration and wiring to get this feature to work as it should in the future.

Thanks and good luck to everyone out there!
V/R
Mike
PS bob there is no rush, the SuperPID still lets me manually operate the RPM.

Bob at PMDX

  • Administrator
  • Posts: 368
    • View Profile
    • PMDX
Re: PWM Output on the 422
« Reply #1 on: March 02, 2015, 09:58:03 AM »
It sounds like you have the "Spindle On" Mach4 signal mapped to a PMDX-422 output, and that output is then connected to the SuperPIDs "PWM" input.

The PWM spindle speed output on the PMDX-422 has been fully supported since plug-in version 0.15.77 (12 Jan 2015).  To enable this, go to the Mach4 "Configure" menu then select "Plugins".  When the "Configure Plugins" dialog appears, click on the "Configure..." button on the PMDX-SmartBOB-USB line.  In our configuration dialog, click on the "Feature Config" tab.  In the center you should see a "PWM Spindle Speed Control" section.

- Select either pin 14 or pin 16 (do not select "PMDX-407" unless you have one plugged in to the PMDX-422, which you do NOT need in order to control the SuperPID).

- Set the "PWM Frequency" field to "50" for 50 Hz, which is what the SuperPID manual says that it is expecting (see page 26 of the SuperPID manual in the "Setting up Mach3 for speed control").

- You can leave the "Min PWM Duty Cycle" at the default of 5%, of if you really need lower speeds than that you can set this as low as 0.

- Leave the "PWM Output Polarity" set to "Active High".

- The setting for "Report calculated spindle RPM to Mach4 as actual spindle RPM" is up to you.  If you check this box, the PMDX-422 plug-in will calculate what it *thinks* the spindle RPM should be (by [% duty cycle * max RPM]) and tell that to Mach4.  If this is un-checked, then Mach4 will not know anything about the actual spindle speed.  Our plug-in does not yet support the "Timing" input (which would connect to the SuperPID's "Tach" output).  So the only way to give Mach4 any idea of the actual spindle speed is to check this box, though I'm not sure what Mach4 would do with the reported spindle speed - there isn't any closed-loop control in Mach4.  All it could do is report the speed to the user.

- Click on "OK" two times to get back to the main Mach4 screen.

- Go to the mach4 "Configure" menu and select "Mach.." item.  Then click on the "Spindle" tab.

- In the first line set your min and max RPM (0 and 30000 according to the SuperPID manual).  This will determine that range of values for the "S" commands that control the spindle speed.

- You can also set the "Accel Time" and "Decel Time", though at the moment our plug-in ignores this.  And I don't remember if the Mach4 core handles these delays.

- At the bottom of the spindle tab, set the "Max Spindle Motor RPM" to the same value you entered for the "maxRPM" above (presume your spindle is directly driven by the spindle motor, which is the case for wood routers).

- Leave the "Step/Dir Spindle Axis" set to "none".

Click on "OK" to save these changes.

Now connect the PMDX-422 "Pin14" or "Pin16" output (whichever you chose above) to the "PWM" input on the SuperPID controller.  Also connect the "GND" terminal on the PMDX-422 to the "PG" terminal on the SuperPID.

You should now be able to issue "S" commands (along with an "M3" to actually start the spindle) and have the PWM control the spindle speed.

Bob
Engineering Hell: Everything's right and nothing works.
Bob's Corollary: If everything's right and nothing works, double check your assumptions.

it_guy

  • Posts: 17
    • View Profile
Re: PWM Output on the 422
« Reply #2 on: March 04, 2015, 04:13:12 AM »
works perfect now!
Thank You Bob!

V/R
Mike