4.3 Connect External Relay

Hardware Connection · Driving a PiBot IsoSwitch V4 relay board from a V4.96 Pro
Mains voltage never touches the controller. The V4.96 Pro only ever supplies a low-voltage signal. All mains wiring stays on the relay’s contact side, inside a rated enclosure. Switch everything off and confirm the LEDs are out before changing a wire or a jumper.
This page is the V4.96 Pro-specific wiring procedure. The common relay-board terminal map, full-size jumper drawing, servo-enable use and cross-model table are on the PiBot IsoSwitch V4 reference page.

Two ways to trigger it from a V4.96 Pro

PiBot V4.96 Pro wired to a PiBot IsoSwitch V4 from the I2SO terminals, with the 5 V buffered output header shown as the alternative
V4.96 Pro. The drawing wires the relay board from the I2SO terminals; the 5 V output header at the top is the alternative. Click the image to view it full size.
RoutePinsLevelNotes
I2SO output
recommended
I2SO.23 I2SO.21 I2SO.20 + GND5 VThe green TBX terminals of an unused motor slot. Needs the slot routing jumpers — see the warning below.
5 V buffered output header
(labelled Outputs 5V)
GPIO.4 GPIO.12 GPIO.14 GPIO.13 + GND5 V signalUse if the I2SO terminals are already committed. GPIO.4 and GPIO.12 also drive the on-board MOSFET channels; the header is a control-signal source, not a relay-coil supply.
Never leave an on-board stepper driver in a slot whose routing jumpers are installed. Bringing I2SO out to the green TBX terminals requires the routing jumpers for that slot (item ⑯ on the V4.96 Pin Definition Overview). With a driver still fitted, this damages both the driver and the mainboard chips. A mixed setup is supported and normal: slots 1–4 with no jumpers for on-board drivers, slots 5–6 jumpered to bring I2SO out for relays.
💡 V4.96 Pro also has an on-board relay, which is a different thing from this external board: it is driven by GPIO.26 and needs the GPIO.26 function jumper set to “Relay Output”. Its bench test is List 4: Test Onboard Relay Output.

Set the trigger jumpers

Each relay has its own jumper block on the relay board — JP4→S1, JP5→S2, JP6→S3. Rows are numbered 1 (bottom), 2 (middle), 3 (top); each column takes one jumper, down bridging 1–2 and up bridging 2–3.

SettingLeft columnRight columnEffect
Active High — defaultdown (1–2)down (1–2)A high signal energises the relay.
Active Lowup (2–3)up (2–3)A low signal energises the relay.
Always onup (2–3)down (1–2)Stays energised, input ignored.
Always offdown (1–2)up (2–3)Stays de-energised, input ignored.
Active High ↔ Active Low reverses which input level energises the coil. At a given V4.96 idle level this reverses the practical contact behaviour without changing the signal wire or YAML. It does not rename the terminals: with the coil de-energised, COM–NC is closed and COM–NO is open. Choose polarity and the physical NO/NC terminal together, then verify boot, reset, alarm and power-off states with a continuity meter before connecting the load.

Wiring and first test

  1. Everything off. Controller and relay-board supply both disconnected; LEDs out.
  2. Set the jumpers on JP4/JP5/JP6 for the behaviour you want. Leave them at the default Active High unless you have a reason not to.
  3. Wire three signals and a ground from one of your board’s outputs to S1 S2 S3 and GND. Use fewer than three if you only need one or two relays — the unused inputs simply stay unconnected.
  4. Power the relay board from its own 4.5–40 V DC supply on the / + terminals. 24 V is the default.
  5. Declare the pins in your YAML — see below — and reload the configuration.
  6. Test with no load connected. Send one command at a time and confirm only the intended relay clicks and its LED changes.
  7. Check the contact with a meter before wiring the real load, so you know NO and NC are where you expect in the resting state.
  8. Only then wire the load through the contacts, on the far side of the relay, with its own protection.

YAML — a worked example

This matches the wiring in the drawings above, where I2SO.23 → S1, I2SO.21 → S2 and I2SO.20 → S3. Coolant gives you two relays with the simple M7/M8/M9 commands; a user output gives you the third.

coolant:
  mist_pin: I2SO.23        # S1 - M7 on, M9 off
  flood_pin: I2SO.21       # S2 - M8 on, M9 off
  delay_ms: 0

user_outputs:
  digital0_pin: I2SO.20    # S3 - M64 P0 on, M65 P0 off
RelayInputSignal in this exampleTurn onTurn off
K1S1I2SO.23 — mistM7M9
K2S2I2SO.21 — floodM8M9
K3S3I2SO.20 — user output 0M64 P0M65 P0
💡 Which command drives which relay is entirely your YAML’s business, not the relay board’s. Swap the pin names above and the commands follow. If you are wiring from the 5 V header instead of I2SO, put that header’s GPIO numbers in the same places — for example mist_pin: gpio.4.
Pass: each command switches only its assigned relay, the LED follows, M9 releases K1/K2 in this example, and M65 P0 releases K3. The continuity reading matches the selected jumper polarity and physical NO/NC terminal.
Fail: more than one relay changes, a relay starts in an unsafe state, a command does not release it, or the measured contact state is wrong. Disconnect both supplies and correct the YAML mapping, routing jumpers, relay-board jumpers or NO/NC wiring before adding a load.

Quick troubleshooting

💡 Looking for the 0–10 V VFD example? That belongs to the spindle wiring rather than to relays — see 4.6 Connect Spindles → 0–10 V VFD example.
💡 Relay-board terminals, servo-enable use, Always-on/off bench override and the full-size jumper drawing are on the PiBot IsoSwitch V4 reference page.