I had to carry out this project in a hurry because the motor of my milling machine gave up the ghost. So please be indulgent because there are still sentences in French on the schematic that I have not taken the time to translate. There may also be inconsistencies, particularly in the pinouts of the connectors. Also the software looks more like a draft but it's working rather well.
Note that you need advanced skills before embarking on this achievement.
The motor:A DC motor was lying around in my workshop for a while. On the motor's identification plate is written: Type: TTB-2923-00A / 156V - 11.3A - 210 rad/s / Peak: 50V - 55A
I have measured an inductance between the terminals of about 4.2mH at 1kHz
This gives us round 1.76 kW of power at full speed. I planned to use it on my mill at a lower voltage and speed, say at 120Vdc. So I expected an angular velocity of 210/156*120 = 160 rad/s which equals more or less to 160*60/2π = 1520 RPM. This is little more than the specified 1400 RPM of the original ac motor. At the end I measured the real speed of the motor: 1680 RPM. This corresponds to a spindle speed of 2600RPM with the belts on the maximum ratio.
I have a three-phase mains supply at home. So I can obtain this voltage by a three-phase rectification of the 48V output of the star-connected transformers. This gives approximately 48*√3= 83Vac between phases and 83*√2= 120Vdc after rectification and filtering.
The power switching board:I am not used to deal with such high power switches, since I was a telephone technician, much more specialized with very low currents. After some tests and the destruction of several power mosfets, I tried my luck with IGBTs. Since they are quite expensive, I used them as a low side switch, relying on relays and contactors for reverse and for braking rather than using a full bridge structure.
A “low-side switch” structure also has the advantage of being able to lead to a cyclic conduction rate of 100%. You don't have to worry about charging a bootstrap capacitor like with a high side switch. To divide the current and reduce the saturation voltage, two IGBTs are connected in parallel. A 12 milliOhm balancing resistor is connected from each IGBT source pin to ground. These resistors are also used to limit and to measure the current through the IGBTs. A low pass suppresses spikes and a section of an LM393 serves as a comparator to inhibit the IR2109 driver if the current exceeds the setpoint. An adjustable resistance makes it possible to adjust the limitation from approximately 10 to 30 Ampere. I set it to 80mV which corresponds approximately to 13.3 A. The second section of the LM393 is connected as a pseudo integrator and provides an image of the average current for displaying it on the OLED. To avoid having to deal with inverted logic, the high side section of the IR2109 drives the IGBTs.
On the diagram I have provided a NTC resistor to measure the temperature of the heatsink. I finally did not mount it because the heatsink remained barely lukewarm.
The two vertical white components on the left are 10KΩ / 5W resistors in parallel on the 120V to discharge the capacitors when off. The small 10µH chokes were salvaged from old ATX power supplies. Likewise with BY74-400 freewheeling diodes. Most components are SMD parts mounted on bottom side.
The PCB was made on a 3018 CNC milling machine. But not everything went well and some tracks and ground planes have disappeared... I replaced them or supplemented them with wires. In particular, the power tracks (in blue on the diagram) have been reinforced with 16 gauge wire (Ø 1.29mm). I also made changes during the development. A dremel with a round cutter was a good help to add some more SMD components by cutting out part of the ground plane on the bottom of the PCB. Missing connections were made with 30AWG wire (Ø 0.25mm).
There are two 1/2W axial resistors in a strange "fly assembly" at the left rear, near to the brown 2 pin connector marked "CTN". They form a divider for measuring the drain-source voltage at the oscilloscope during development. The other probe for current measurement was connected to a golden coaxial connector matched to the probe on the midpoint of the current summing resistors R6-R7.
In order to avoid false triggering of the IGBT, the inhibit pin of IR2109 is held down at the power up by Q8 as long as the inhibit signal from the arduino does not pull to GND the cathode of D12. The collector of Q8 is OR-wired with the output of the LM393 overcurrent comparator. GND, +15V and inhibit are on the black HE14 connector in the middle left of the board. On the white HE14 are the PWM input and the I_measurement and I_limit signals. NTC temperature measurement was provided at the beginning but is finally not needed and thus not wired.
I used part of a broken RJ45 cable to connect the power board to the arduino. Each pair carries a signal and a GND or +15V (eg "GND-PWM", "GND-meas_I", "GND-I_limit", "+15V-inhibit") giving a total of 4 pairs. The GND wires are doubled with the shield wire. No wires remains for carrying temperature measurement... It is important to respect this allocation to limit the crosstalk between the signal wires.
The heathsink is an 40x20mm extruded profile with 6 wings, cut at a lenght of 200mm. It's thermal resistance is a little less than 3K/W. Insulation from the PCB's undelying tracks is done with 3 layers of kapton tape (in orange under the heatsink). The diodes and IGBTs are insulated from the heatsink with TO218 silicone rubber pads. They have about 0.5 K/W thermal resistance with thermal grease on each side.
The control board:The control board is mainly built around an Arduino micro pro on a perforated vero board. Arduino micro pro was not the best choice because A4 (SDA) and A5 (SCL) pins are not easy to catch. Arduino nano would be the better choice but in the hurry I had none readily avalaible. Small on-board relays make the interface with the power relays and contactors. The driver transistors (BC337) are secured with hot glue.
The analog inputs of the Arduino are filtered with 18KΩ - 100nF low pass. The digital input "I_limit" has a 1KΩ - 100nF low pass.
An HE10 connector and a flat cable lead to the "control pannel".
It features :
- A 0.96" OLED for future use (tachometer)
- A 1.3" OLED to diplay different value in form of bargraphs
- A 10KΩ potentiometer to select the maximun speed
- A switch to select forward/reverse rotation. And in center of it:
- a red LED indicating if current limit has been reached (in this case the LED will light up for 2s)
- A switch to select if the air blow valve shall be activated (I often mill PVC, nylon or other plastics, so the air blowing is useful for clearing chips and cooling the cutter). And in center of it:
- a green LED to indicate if the switch is set to air blow or not
- A pneumatic valve to adjust the air flow
- A switch shunting the external pedal for running permanently at the speed chosen with the potentiometer
- A connector for an external pedal with a 20KΩ resistor for hand-free controlling the speed
The aluminum box screwed at the top with the green and red push buttons are the controls for the three-phase mains power contactor. As we deal with mains voltage, protective eath connection (PE) is mandatory on the metal boxes !
The 220V power supply for the control card passes through a hole between the two boxes. It is filtered by 4 passages of both wires through the hole of a ferrite core. There is an other ferrite with 4 passages on the ground wire that lead to the control box (e.g. TDK HF70RH16X28X9 or FAIR-RITE ref: 2643102002). These are 16x28mm ferrites with a 9mm hole that I had available. Perhaps another ferrite could also be suitable.
I had to put these two ferrites because the I2C OLED screen crashed regularly due to disturbances from the relay box.
A 1.3" graphic OLED is connected to the I2C A4-A5 port. It displays in combined form of a frame and a bar, the speed limit and the speed setpoint. On the bottom line of the display, a bar indicates the approximate current in the IGBTs. After 10 seconds without sollicitation, the OLED screen darkens to save its lifetime. After turning the potentiometer or pressing the pedal, the screen lights up again for 10 seconds. You can see it on the video below.
The 0.96" dark OLED at the top is planned for a tachometer to be made in the future.
The relay box:I didn't have a box big enough to put everything in. So I had to separate the PWM chopper board and the relays in two separate boxes.
The brake resistor was eventually replaced with a homemade 2.2 Ohm wirewound resistor to increase braking.
The transformers:There are 3 single-phase 400V-48V / 250VA transformers. The primaries are delta wired. The secondaries are star wired. I thus obtain 83Vac at the secondary. This gives 120Vdc after rectification and filtering. If you missed it, you can see the explanation at the end of the "The motor" chapter above.
Oscilloscope measurements:The output voltage of the three phases after the transformers is a little different. This follows the mains-side primary voltage. But filtering a three-phase rectification is much easier than single-phase rectification. Despite the voltage difference between the phases, the ripple without filter capacitor is only 23V. With half-wave rectification the ripple would be of the full voltage (120 to 135V).
- Top trace: IR2109 PWM input (duty cycle ~20%)
- Bottom trace: IGBT collector-emitter voltage
- Top trace: IR2109 PWM input (duty cycle ~80%)
- Bottom trace: IGBT collector-emitter voltage
- Top trace: IR2109 PWM input (signal is inverted as it was the first prototype - where I used the low side section of the IR2109)
- Bottom trace: IGBT collector-emitter voltage
This measurement was made during early development. It had been taken with a 60V-10A supply before the final supply was available. The current limitation had been set to the minimum. The PWM signal is inverted compared to the final realization because I had used the "low side" driver of the IR2109. To simplify the inhibit circuit at the startup, the high side driver section of the IR2109 was finally used to drives the IGBTs.
This measurement shows the action of the IR2109 inhibition input by the current limitation. The current limit is triggered once during the phase when the IGBT should be saturated. With the current limit hardware setting and the ramp-up timing chosen in the sofware, this normally does not happen.
Logic timing diagram:On power-up, the inhibit input of the IR2109 is held low while the arduino boots up. First, the arduino closes the power relay by shunting the resistor used for slow capacitor pre-charge. After that, the inhibit input of IR2109 goes high. Only after, and if the switch or the pedal are activated, the PWM does start its ramp-up until the desired speed is reached.
When the switch or the pedal are released, the PWM start a ramp-down sequence. When PWM signal remains low and after a short delay, a brake cycle is initiated by shorting the motor on a low Ohm power resistor.
If the position of the reverse switch is changed, nothing happens as long as pulses are sent on the PWM. As soon as PWM remains low, a braking cycle is initiated. After that, the relay changes its position. This prevents a reversal of direction while the spindle is still rotating in opposite.
The air blow solenoid valve is activated if the corresponding switch is ON and if speed is more than about 10% of the max. There is no need to blow air below this speed for my use.
Update:At the chopper output I was relying on the motor inductance for filtering the pused current. BUT It turns out that the motor has a stray capacity between the winding and the housing of round 9nF. That can be approximated by two capacitors of 4.5nf forming a divider between the two wires and the frame. Half of the switching voltage is therefore found on the housing (about 55V measured with the oscilloscope). This causes an entry into limitation of the chopper if the ground wire is directly connected to the motor.
Since this capacity cannot be suppressed, the best way would be to feed the motor with filtered DC. I have built an 1.4 mH inductor with an old 150VA transformer. The winding removed, I rewound with 45 turns of enameled wire Gauge 12 (Ø 2.05mm).
Iron core salvaged from an 150VA transformer
- Outside dimensions of the iron core alone 96x80x45mm
- Section of the central iron leg: 14.4mm² (32x45mm)
- Air gap : 1.5mm (presspahn or rigid cardboard)
- Winding: 45 turns of enameled wire Gauge 12 (Ø 2.05mm)
- Resulting inductance: 1.4mH (measured at 1KHz)
The capacitive part of this filter is built with a 10000uF/125V high current polarized capacitor, and in parallel three 10uF/160V MKP1840 to reduce the current stress in the polarized capacitor.
The ferrite core coil between ground and the CONTROL board can now be removed. The motor also runs a little quieter and there is no longer a current limiting problem as long as the torque demand does not exceed the limit.
Comments