Introduction: Lieo Power First PF906 Treadmill Controller Circuit Investigations and Schematic
This Instructable is intended to describe the motor controller board, generally how it works, and how to run it from an Arduino. Or maybe a new PIC chip if I eventually go down that rabbit hole.
The motor controller has 240AC inputs and around 340VDC at the motor terminals. Make no mistake, these voltages are lethal, so anything you do with this information is at your own risk. This Instructable does not describe safety procedures, so think carefully about your experience level and skills before attempting this. This Instructable is intended only for people with the necessary skills to keep themselves safe.
I bought the DKN treadmill from the local dump recycle shop and found it had a 2.5hp DC motor and DC control board. It had a "E1" fault and the motor wouldn’t go while controlled by the treadmill controller board. Throwing out a perfectly good motor goes against the grain, particularly as I only wanted the motor and the motor controller, so I started investigating.
First I tested the motor and it turned over happily on just 30V DC so it’s good. Must be the controller is faulty. My board was built in 2008, so it’s 12 years old - still a reasonable age.
The only help I found on the Internet was a comment that these boards are hard to fix, that they have component glue that ages and causes faults & lots of other videos with ideas how to replace the controller. Some similar controllers have YouTube videos of component level repair. I hope this Instructable and YouTube video make it possible for a hobbyist to apply to their lathe, drill press or milling machine.
Having mucked about with it for a while now, my view is that the board is well built. has many good components.
Your treadmill knows that it has a fault as it senses the DC bus voltage and when it closes the relay, expects confirmation that the DC voltage is present. When the relay contacts are worn, then the DC bus voltage feedback is missing, and hey presto, an error is generated.
Step 1: PF906 Controller Pcb Description
I have uploaded a YouTube video about the board if you prefer watching that. For those still reading, here’s the video in text (almost):
The latest versions of the circuit diagram and my Arduino code is available on my GitHub site.
The board has:
- a power section consisting of the 240VAC terminals, snubber and filter capacitors, fuse, relay, rectifier, smoothing caps, IGBT’s, motor current sensing resistors, freewheeling diode and snubber, and the DC motor terminals
- A second AC bus that drives the raise/lower motor.
- a dual output SMPS using control IC TOP244YN with TL431 voltage monitoring and PC817C opto-coupler feedback
- some electronics to drive the incline motor
- a PIC for control with some motor protective sensing via a TL082 dual op-amp.
The power section supplies the motor power and all other power is separately provided. One separate source is for the SMPS which is powered up immediately on mains power-up.
I have no interest in the treadmill's raise/lower feature so Ive not looked at that further, but it is the other separate power supply off the incoming AC supply.
The SMPS provides 2 outputs and galvanically isolates them through the transformer. One side of the SMPS supplies a completely separate 12V (or thereabouts) to the external treadmill control panel. This supply ground is not shared with the other grounds so it floats relative to the rest of the circuit on the motor controller PCB - this is probably a safety feature protecting the treadmill user from the high voltages present on the PCB. The treadmill controller PCB is of no interest to me so I've not delved further into it except to note that the treadmill controller board has a smoothing capacitor and 5V linear regulator installed (although the displays look interesting and I may have a bash at driving those from an Arduino).
The other output from the SMPS supplies around +12V and -12VDC to all the other control circuits on the motor control board and has a common ground shared with the motor '+' terminal. Two linear voltage regulators provide +5V and -5V power. These voltages provide power to the PIC (+5V, gnd) and the TL082 op-amp (+5V, -5V, gnd). Note that motor "+" terminal is connected to the circuit ground, so the motor "-" terminal is at around -320VDC relative to circuit ground.
The TL082 op-amp is used to sense both motor current and motor voltage. The DC bus is direct coupled to the PIC by a resistive voltage divider. A more modern PF906 board has a preset pot for torque control added above the PIC. Mine doesn't have that so there is no torque control. I'm assuming it is a simple voltage divider for the voltage or current detection signal, but I've really no idea. Given this motor drives a belt that a 100kg human can stand on and be pitched over from a standing start, I don't think motor torque is going to be a problem.
The motor voltage control is provided by PWM of the DC bus voltage via the twin parallel IGBT's (K30N60). The IGBT's control input (gate) is driven by a totem pole driver. The PWM signal and the totem pole power control signal is generated by the PIC. The PIC can turn off the motor voltage by disabling the IGBT gate PWM drive by driving the totem pole power control signal low.
The PIC can send signals back to the treadmill control board via an opto-coupler (FR6). The treadmill control board sends control signals to the PIC via 5 opto-couplers. Only one of those is of much interest, and that's the one (FR7) that closes the DC bus control relay RL2.
LED's are attached to the PIC and opto-coupler inputs as follows:
- LED 1 (green) when lit confirms the PIC has power and is running (ie the PIC drives one of its outputs low to light the LED)
- LED 2 (red) lights when either opto-couplers FR1 or FR2 are driven by the treadmill controller board
- LED 3 (red) lights when either opto-couplers FR3 or FR4 are driven by the treadmill controller board
- LED 4 (red) lights when the treadmill controller board drives the power relay to close.
All the above is shown on the schematic diagram I drew of the critical parts of the motor controller board.
Step 2: The Treadmill Startup Sequence
I don't know if this is correct but I'd expect the treadmill start up is as follows:
- Mains power on (manual)
- SMPS starts
- onboard PIC starts, turns on LED 1 and turns the motor totem pole driver
- When the treadmill control board is ready, the person safety key is present, and the user presses the "Power" button, it sends a close signal to one side of the relay RL1 coil.
- The onboard PIC:
- senses the DC bus voltage is present (HV signal)(having charged through R55), then sends a close signal to the other side of the RL1 coil. Hence the relay can only close if the user presses the "power" button, and the onboard PIC can sense the presence of HV DC
- starts receiving speed increase pulses from the treadmill control board as the uses presses the speed + button
- turns on PWM at the lowest speed, then turns on the totem pole driver
- the motor starts turning, and the PIC senses its rotation speed by counting pulses from the motor speed sensor
- increases PWM duty cycle to match the user's speed setting and regulates the speed around the set point
- If something goes wrong, for example:
- the user falls off the treadmill and pulls out the safety switch, the controller drops off the RL2 drive and the motor stops, or
- the DC bus voltage is missing, or
- the motor voltage is excessive, or
- it draws excessive current
then the onboard PIC sends a fault signal to the treadmill controller via FR6. Its likely that the fault message is encoded, for example 1 pulse and a long gap is no DC bus voltage, 2 rapid pulses followed by a long gap is over voltage and 3 rapid pulses and a long gap is over current. There may be other encoding signals for the raise and lower motor faults.
Step 3: Making an Arduino Drive the Motor Controller Board
An Arduino can be substituted for the PIC, but you need to do some work to make it happen. I used a Chinese* Arduino Pro-mini - you need a 5V version.
- Program the Pro-mini using the code from my Github repository or write your own. You will need a 10k pot (with a plastic insulating handle) wired Vcc to Gnd and the wiper to pin A3 to alter the PWM signal. The circuit diagram I drew of that using Kicad is in the Github repo too. Original diagram attached
- I'm not certain, but I think R61 pull-up resistor interferes with the Arduino, so remove it. Experiment if you like, not sure of your mileage.
- Remove the PIC
- Under the board install a bridge wire across the RL2 relay contacts (check the photo)
- Assuming you use a Pro-mini too, and use pin 10 as PWM output and pin 13 to drive the totem-pole power signal, wire the Arduino into the circuit as follows (check the photo):
- connect pin 10 of the pro-mini to the pad just above the "R" of R61
- connect pin 13 to the track under the R21
- When I figure out the connections I'll use pin 7 to drive RL2 to close when you want the motor to run.
- Power for the Pro-mini is provided by the gnd-5V pads on the controller board. Make sure you're using "+" 5V and not "-" 5V. Ensure the Pro-mini is insulated from all conductive materials.
- Wire up the mains supply making sure to connect the "earth" cable. I recommend you use the filter and inductor that came with the treadmill - it will filter the electrical noise going back into your mains supply.
- If you're experimenting, then clamp the motor to the table so it doesn't spin up and jump off the table like mine did.
- I recommend that you connect a 500W tungsten globe in series with the supply mains on the first test just in case there is something wrong with your motor controller board. At mains power "on", the lamp will light briefly, which is the capacitor charging current and is normal. At low speed, the motor will draw little current and the lamp will likely be off, but if you dial up the speed the lamp will light dimly as more current is drawn.
- That's it, connect the motor and power it up from the mains! Adjust the motor speed by turning the pot.
NOTE: DO NOT TOUCH ANY PART OF THE ARDUINO OR ANY OTHER PART OF THE CIRCUIT THAT IS NOT DIRECTLY COUPLED TO "EARTH" WIRE FROM THE MAINS. Better yet don't touch the circuit at all!
*Sometimes the Chinese ones are rubbished on YouTube. I've had no trouble since I realized that the through plating on the pin holes was not always reliable. Soldering both sides of the PC board fixed that one, and I have had no trouble with the rest.
Step 4: A Note About the Treadmill Controller Board
I've tried to separate the "Treadmill controller board" from the "motor controller board" in this Instructable. The former provides a way for the treadmill user to operate the treadmill and has 2 large LCD displays. The latter drives the motor and manages the power supply.
The treadmill controller board has a PIC 18F45J10 - I/SS mounted on it and that drives the displays and the buttons. The displays are beaut and I'd like to try drive them with another Arduino or other microcontroller so I can put what I want on the screen/s, but that's another project.
Thanks for your interest!
Participated in the