abse/isv57t090-motion-controller
A 36 V-powered RP2040 motion-controller PCB that regulates 5 V, drives isolated STEP/DIR servo inputs, monitors alarms, temperature, limits and E-stop signals, and provides protected safety/field connectors.
- Version
- 0.0.67
- License
- unset
- Stars
- 0
examples/ISV57T090MotionController/README.md
# iSV57T-090 RP2040 motion controller
This 78 × 76 mm, four-layer board controls the StepperOnline iSV57T-090
integrated servo through 5 V STEP/DIR opto-inputs. The motor has its own
driver and encoder; its separate 20–50 V DC supply is **not** carried by this
PCB. The RP2040 is the controller, not the power-regulator or sensor ICs.
## Power and USB-C
- The motor's DC supply must be wired directly to the motor through an
appropriately rated external power-interrupt device.
- The board's auxiliary **36 V maximum** input feeds a 5 V buck for the
STEP/DIR input supply and the control electronics. An SMBJ36A TVS, placed
cathode-to-positive after reverse-polarity protection, limits transients;
it is not permission to operate this auxiliary input at the motor's 50 V
maximum rating.
- The single programming/data USB-C port can power the RP2040 logic through
a Schottky diode. It cannot power the motor, the 5 V STEP/DIR supply, or
the external relay coil. USB-C Power Delivery is not implemented.
- `J_SAFE` coil supply comes from the board's regulated 5 V rail, so a USB-only
controller cannot accidentally energize the motor-supply contactor.
- The four-layer PCB has autorouted power traces plus GND copper pours on both
the top and bottom layers; its four plated M5 mounting holes connect to GND.
## Thermal and fault shutoff
- TMP117 `U_TEMP` monitors the board via I²C0 (RP2040 GPIO8 SDA, GPIO9 SCL).
- A **10 kΩ B3950 NTC**, bonded to the motor heatsink, connects from `J_IO`
pin 5 to pin 6 (GND). Its divider is read by RP2040 GPIO26/ADC0. An open
or shorted NTC is a fault, not a valid temperature.
- `J_IO` pin 3 is a normally closed E-stop contact to pin 4/GND. An open loop
is a fault. This is a firmware input, **not** a safety-rated E-stop.
- The motor alarm is normal-low and fault-open; the 3.3 V pull-up and 1 kΩ
series resistor feed RP2040 GPIO5. The motor alarm's default polarity must
be retained in motor configuration.
- RP2040 GPIO12 drives the `Q_SAFE` logic MOSFET. Its gate has a pull-down, so the
external relay coil output at `J_SAFE` is off while the MCU is resetting or
unpowered. A flyback diode is installed. The contactor itself is external.
- `firmware/main.py` polls both temperature channels and fault inputs every
50 ms. It energizes `J_SAFE` only after ten healthy temperature/E-stop
readings, then gives the powered motor alarm up to two seconds to become
normal-low. Motion must remain disabled until this happens. It trips at
**65 °C motor heatsink** or **75 °C board**, de-energizes `J_SAFE`, stops
pulses, and latches any sensor, alarm, or E-stop fault until reset. The
motor manual limits heatsink temperature to 70 °C.
- The onboard GPIO25 status LED is solid on while disarmed/faulted and blinks
when armed. The separate 5 V LED indicates the STEP/DIR supply.
## Critical release boundary
This repository is **not yet proven fabrication-ready or safety-rated**. It
contains a PCB and a MicroPython thermal supervisor, but not a complete
motion-command implementation. Before ordering or operating a motor:
1. Select and validate a specific relay/contactor: its coil must operate from
the actual `J_SAFE` voltage after diode drops, its coil current must be
within `Q_SAFE`/diode/trace limits, and its **DC** contacts must safely
interrupt the motor's 20–50 V, up-to-6 A supply including regenerated
energy and the required fault category. Do not use an unspecified relay.
2. Flash and validate the firmware on assembled hardware. Test NTC open,
short, overheat, TMP117 disconnect, E-stop open, motor alarm, reset, and
brownout while observing both the relay and motor supply.
3. Check actual NTC B-value and thermal mounting against the 65 °C trip;
adjust the firmware constants only after measurement on the installed
motor. A board-mounted TMP117 cannot directly measure motor temperature.
4. Complete schematic/electrical review, BOM stock and footprint checks,
copper/thermal-current review, DRC/shorts, assembly files, and a first-
article power-up before production.
The motor manual states the drive is enabled on power-up and its enable cannot
be changed in software. Merely stopping STEP pulses does **not** remove
motor torque. The external power-interrupt device is essential to the
requested overheat shutoff. Neither firmware nor this board substitutes for
a certified machine-safety circuit.
## Firmware tests
From this package directory:
```sh
python3 -m unittest discover -s examples/ISV57T090MotionController/firmware -p 'test_*.py' -v
```
For a MicroPython bench test, copy `firmware/main.py` and
`firmware/thermal_guard.py` to the RP2040. The safety supervisor deliberately
does not generate motion; a motion application must preserve its fail-closed
GPIO12 output and continuous sensor polling.
Motor documentation: [iSV57T user manual](https://www.omc-stepperonline.com/download/iSV57T.pdf).