Roland PNC-3000 tabletop mill
I got my hands on a Roland PNC-3000 already more than a year ago. I found it on Markplaats a Dutch plaza for 2nd hand stuff. It was a proper barn find as I picked it up at a farm and it litterally came out of a barn where it probably resided for years, clearly not months. The paint was flakey, the guide rails rusty and there was dirt and spiderwebs all over it.The spec
The plan
The execution
Testing the machine
Disassembly
Removing all the covers was a breeze, it became clear that the machine had been partly disassembled before. Most of the crosshead screws where heavily abused wth a screwdriver that obviously did not fit properly, so when reassembling I need to find myself some nice M3 and M4 screws that do this machine justice.
Next up was the removal of the X/Y table, this is done by removing the round guiderails from the base and the table. The steel rods are secured with imbus screws at one end and the fit is H7 precision milled holes. Under normal conditions the rod would just slide out as it is not press fit, but after years of moisture and temperature changes the aluminum body and the steel rods cold welded together. It took a few hours and some custom tooling to remove the rods from the base and the table. It also was clear the the X and Y axis guide rails did not have a layer of fly rust but had some serious, dents and scratches. While trying to sandpaper them into a smooth and even surface again I realized that this would be come a nightmare and that whatever precision the machine once had would go out the door.
With the ballscrews, motors, coupling etc removed it it was posible to clean and inspect the different components. As the ballscrews where mostly covered in dried out grease they had not suffered the same fate as the guide rails. So these could luckily be reused. This grade of ballscrew would set you back a couple of hundreds when replacing them with the same quality. Alternatively a cheap 1204 ballscrew could be used, possibly sacrificing some precision.
Cleaning and fixing
The base
The covers
The spindle support
The spindles
Cleaning the spindles
Yikes, there is a lot to say about this motor, for one it uses carbon brushes, the color of the motor is the ugliest shade of grey they could find and the thing is noisy as hell. No wonder I considered replacing it ... but with what.
Currently the motor controller is in working order. The motor fits snuggly in the Z chassis and delivers a decent amount of power given its size. Replacing it would also mean replacing the motor controller, which in turn would make the tacho/rotary encoder on the pully of the spindle useless without conjuring up a electrical circuit or modifications to the software to actualy have a feedback loop.
The remaining electronics
A few components remain relevant, the transformer has powered this machine in the past and it would surely be able to do so in the future, right? The motor driver PCB features a solid state relay that is used to chop the sine wave and regulate the RPM of the motor. When the motor is not replaced al can remain the same and the orginal wiring can be used. The display that is mounted to the front of the Z axis unibody, showing the cartesion coordinates of the three axis in 0.01 mm increments. If this display can be reused that would be awesome as it would mean that the physical appearance remains unaltered. More on this later. The last piece of electronics that I would like to salvage is the controller. The base has a magnetic sheet glued to the front and the manual control box just stick to this with a large metal bottom plate. Once attached it looks like part of the machine.
Autobots transform
When measuring the actual voltages I did not end up with the expected values but slightly higher which would bring the voltage for the stepper motors close to the maximum allowed value. After looking at the diagrams again I found out that the transformer can be wired for 110, 220 and 240 volt and this one was wired for a primary voltage of 220 volt, in line with the net supply of the Netherlands in the 1980s. Gradually the net voltage has been increased in roughly a decade of time. Checking an outlet gives me a 235 volt reading. A quick rewire brought the output voltage back on spec. Nice if some things are so easy to solve. Wat remains for now is to create a small voltage regulator for 12 volt output to make it possible to power some of the electronics. As a workarond I've added a switching powersupply for this for now.
The motor driver
Nice to have all this stuff in place. A small, white, 4 pin molex connection is used to control the motor. While testing it scared the shit out of me as I was making a connection on the female molex connector, providing the 12 volt powe to drive the circuit. Then making a connection to the motor on pin. Stupid that when you connect something to let a motor spin that I still was caught by surprise that the the thing started spinning, at full RPM as there was no feedback from the tacho yet. What is tricky is that the encoder (tacho) is connected to the display (VF signal) to show the actual RPM as a bar on the display, a control voltage signal is then connected to the motor driver. I'm not sure yet if the machine in its orriginal state controlled the RPM or if this was always done with the potentiometer on the motor controller PCB.
The display
There is a lot of things that can be said about the display, it is actually a smart module as the actual pulse counters are part of this assy. Also the RPM to bargraph conversion is done here. The feedrate that is at the lower right hand side of the display is controlled from the original control board. What I like about this is that during normal operation it shows the feedrate setpoint, when an error occurred the LEDs are used to give a status indication what is wrong. Nice dual function. For now GRBL does not make it easy to do anything with the feedrate, maybe I need to switch to GRBL HAL in the future as this has a plugin architecture that allows you to extend the functionality. Don't know how yet but it looks promising.
Following the schematics I found out what pins are used to drive the display from the motherboard. A 15 pin connector holds the step and direction for each axis. The display is literally counting the pulses that are sent to each stepper motor driver. When hooking up the display with a breadboard as a proxy to an Arduino (Mega in this case) I got the Z and the X axis to work relative quickly. The Y axis however failed to stick to the promis of the diagram. OK, deduction mode on! With a 1k resistor in series I probed all the different pins and I could not get the Y axis to respond to amanually induced step signal. As I was about to give up and put the display back on my desk the Y axis came to life without any input. To cut a long story short. Through the year of use, the 24 wire cable moved up and down with the Z axis. The cable was mounted to the metal backplate and the plasitic clamp was a pinch/hinge point with a relatively sharp bend in the cable. I tried to solve the problem with three wires that were not connected, but I ended up discovering that more than one wire was actually broken. I ordered a new cable, molex pins and I'm still trying to find the correct crimp equipment to properly fix this. Until then I will have to solder 21 wires onto the existing connectors using a short piece of the original wire to connect it. Not pretty, but workable, nothing that a piece of braid and a crimpsleeve can not hide from sight :)
The 7 segment display units have a decimal point, this is however not used. It would make it a lot easier for quick readout if the display would show 100.00 instead of 10000 for 100 mm. There are some jumpers on the display board so maybe this is
Stepper motor drivers.
The new electronics
Overview
The stepper motor controller
As a stepper driver controller I used something that I once had bought and used in several test setups. The board I'm talking about has 4 stepper motor drivers on a single PCB and a delta 25 printer connection to provide the steps and direction, with the users of Mach 3 in mind, using a paralel port on a PC. The board however has a very bad reputation of being unreliable, lots of stepper noise and even claims of spontanious blowups within the voltage specification. So I stay way below the maximum of 36 volts that the board should be able to handle, I run the motors at 25% current, and do not use microstepping. With what I tested, in a 100 minute run the board seems to stand its ground. If it would fail misserably it should take no more than a day to replace with 3 separate drivers. The fourth stepper driver (for a rotary A axis is currently not connected) due the use of an Arduino Uno with a limited capacity and pinout, software for the uno not being available for 4 axis.
If you are thinking; "why no microstepping". This has to do with the display. The original configuration used the Vexta stepper's 400 steps per revolution to divide every millimeter of the ballscrew (4 mm per revolution) into 100 steps per mm. This makes it easy to create a direct relation between the steps and the lineair movement. The display counts these steps and comes to a 1/100th of mm precision on the display by just counting the steps. By using microstepping the amount of steps go up without the displacement changing, resulting in the display being incorrect.
Not too bad, I often like to do some mechanical trickery to end up with integer values instead of floating point values.
The micro controller (and electronics)
I first thought there was nothing that I would be able to say about the arduino micro controller, besides that it survived some serious stupidity so far.
To be able to get everything neatly tied up in the original enclosure of the milling machine I thought it made sense wire everything on an experimentation PCD that piggybacks on the Arduino. I found out that not knowing how to use a design program for circuits boards can make your life misserable
I first created the layout of the solder islands in an overview drawing. I wanted to put a 26 pin boxed header on the print to use a flatcable with a delta 25 connector going to the stepper controller. Since the driver board is restricted to what data terminals there are within the parallel port the layout for these pins is predetermined. On the connector the driver enable, step and direction pulses are present for the 3 (some 4) axis, 3 limit switches are handled here and a switch for the emergency stop. This emergency stop is also present on the display (effectively the only control in the form of a button)
This is a table of the different pins on the delta 25 and a drawing of the physical layout. I always seem to forget what pin 1 is on a connector.
So the step and direction pulses for the display also need to go somewhere. I added the 15 pin molex connector tot he drawing and labeled the pins where appropriate. Last but not least I marked the pins on the arduino where, with the standard layout of GRBL, the input and output signals should be.
Now the great puzzle begins, I decided to use the soldering islands as vias. Al the tracks run horizontally on the bottom side and vertially on the top side (isolated wires). After a few hours of connecting the dots I had a design that in my opinion had the shortes path from point to point and required the least amount of soldering work. After switching the tip of my soldering iron the process of wiring everything sped up. Even after quadruple checking the soldering there were several things wrong. Most of them in the design phase. Luckily the strategy of shortest paths and horzintal and vertical distribution made the fixes relatively easy.
In its current state both the stepper driver board and the display are doing what I tell them to do.
The software
When I ran a test with the milling machine connected I had to figure out if I could get the homing cycle to work.
Some theory
Homing in the CNC world means, First retract Z to make way for X/Y moves. The z axis moves all the way back to a limit switch. When the switch triggers the machine immediately stops, it then reverse the motion for a few milimeters and then appoaches the limit switch at a much lower speed to alow the switch to more accurately trigger (also reducing the timing component). When Z is homed, The X and Y axis both move at the same time in the direction of teh limit switch that is set up for homing. The same procedure as with the Z axis takes place. When all the axis are homed, the software has a 0,0,0 reference where to start from.
Cartesian mindfuck
I also have a portal mill, this mill has a stationary bed and the milling spindle is attached to the gantry and moves over the bed. So sending the mill in a positive position for X or Y moves the mill in the positive direction, away from me and to the right.
The Roland PNC-3000 has different approach, the mill is stationary and only moves up and down in the X/Y plane and the table moves under the mill. While testing (without the home switches) I used UGS (Universal Gcode sender) to move in a positive direction, so X+ moved the table to the right. Y+ moved the table upwards.
Only when trying to get the limit switches working I realized that the table moved in the oposite direction. If the tool needs to move to the right in respect to the object that is processed the table is moving to the left. same applies to the other axis in this plane.
So where can these direction be changed?
- Flipping 2 wires of the coil of the stepper motor makes it move in the oposite direction.
- The direction can also be changed by inverted the direction signal from the arduino to the stepper motor.
- The homing direction can also be changed.
What can't be changed though is what the display uses as a positive or negative movement.
For me it seem logical that the part is placed as it is designed and that the path that is calculated is visible as such. UGS has a visualizer and I'm sure that you can rotate the axis in UGS for the visualizer but for me.
Positive move means the tool moves to the right or the top of the object. I will have to see how all this wil work out.
Doing your home work (aka getting homing to work)
So when a homing command is given first the Z axis and then the X/Y axis are homed. So the table needs to move into the direction of the limit switch.
The limit switches are at the top and the left hand side.
To check the configuration of GRBL you can type $$ in the console window of UGS (or any other terminal application)
This dumps
$1 = 25 (Step idle delay, milliseconds)
$2 = 0 (Step pulse invert, mask)
$3 = 0 (Step direction invert, mask)
$4 = 1 (Invert step enable pin, boolean)
$5 = 0 (Invert limit pins, boolean)
$6 = 0 (Invert probe pin, boolean)
$10 = 1 (Status report options, mask)
$11 = 0.010 (Junction deviation, millimeters)
$12 = 0.002 (Arc tolerance, millimeters)
$13 = 0 (Report in inches, boolean)
$20 = 0 (Soft limits enable, boolean)
$21 = 0 (Hard limits enable, boolean)
$22 = 0 (Homing cycle enable, boolean)
$23 = 0 (Homing direction invert, mask)
$24 = 25.000 (Homing locate feed rate, mm/min)
$25 = 500.000 (Homing search seek rate, mm/min)
$26 = 250 (Homing switch debounce delay, milliseconds)
$27 = 1.000 (Homing switch pull-off distance, millimeters)
$30 = 1000 (Maximum spindle speed, RPM)
$31 = 0 (Minimum spindle speed, RPM)
$32 = 0 (Laser-mode enable, boolean)
$100 = 200.000 (X-axis travel resolution, step/mm)
$101 = 200.000 (Y-axis travel resolution, step/mm)
$102 = 200.000 (Z-axis travel resolution, step/mm)
$110 = 600.000 (X-axis maximum rate, mm/min)
$111 = 600.000 (Y-axis maximum rate, mm/min)
$112 = 500.000 (Z-axis maximum rate, mm/min)
$120 = 50.000 (X-axis acceleration, mm/sec^2)
$121 = 10.000 (Y-axis acceleration, mm/sec^2)
$122 = 10.000 (Z-axis acceleration, mm/sec^2)
$130 = 200.000 (X-axis maximum travel, millimeters)
$131 = 200.000 (Y-axis maximum travel, millimeters)
$132 = 200.000 (Z-axis maximum travel, millimeters)
ok
The settings that are relevant for homing are
$23 = 0 (Homing direction invert, mask)
$24 = 25.000 (Homing locate feed rate, mm/min)
Seek rate
This is the setting of the velocity for fast moves. Please take into account that a machine can not stop immediately. The mass of the machine will make rapid deceleration impossible. When the machine reaches the limit switch it needs to stop immediately. Setting a value that is too high might damage your machine as it cant stop in time and crashes into your limit switch or mechanical hard stop. Start with a lower value first and if visually validate the speed. The seek rate is expected to be higher than the locate rate.
Debounce delay
When the metal contact of a switch moves it is a spring action. As a result, when making contact, the metal part bounces a few times, giving not one but multiple short pulses before the contact is fully made. This behavior is noticable when the contact is normally open and closes (making contact to indicate the switch is triggered). When a switch is normally closed, it is opened when the switch is triggered. Normally closed is preferred as it would also trigger a machine stop if for some reason there is something wrong with the cabling. The debounce time suppresses the repetive triggers of bouncing.
Switch pull-off distance
The pull-off distance is the amount of mm that the cariage of the axis is pulled back after the switch was triggered. It should be enough to break the contact of the switch. A switch has a hysteresis, the point of making contact and the point of breaking contact are a little bit apart. This is by design to make sure that a switch that is just triggered wouldn't keep triggering due to mechanical vibration. after moving 1 mm as in the example setting the machine is at 0 (origin)
No comments:
Post a Comment