Skip to content

Multi-Channel Motor Control — Firmware Tested Without the Motors

The drives and their sensors, simulated as the counterpart — so multi-axis motor firmware is validated at the desk and on every commit, instead of on heavy-load test benches.

Industry: Manufacturer of mechatronic devices with multi-channel motor control (several drives per controller).

The challenge

Motor-control firmware has to react to what the drives actually do — currents, positions, end-stops. Validating it used to mean the real thing on the bench: motors, heavy-load fixtures, and a full drive cycle for every test run.

  • Each drive cycle is slow, and the rig is bulky and awkward to handle.
  • Units are tested one after another, rarely in parallel.
  • Corner cases, load and stress scenarios eat even more manual bench time.

The result was a validation loop measured in hours and gated by physical hardware.

The LoopCheck solution

A test board adapted to the controller stands in for the drives and their sensor feedback. A motor model runs in real time — microsecond time steps — on the test controller, and the customer's MCU is wired in through its real interfaces and run against that model.

A LoopCheck adapter board configured for drive and sensor emulation

  • Drive simulation — current profile and mechanical behavior are tuned by parameter, not by swapping hardware.
  • Driven from Python — parameters and load torques are set at runtime; the suite runs automatically on every commit.
  • Owned by the customer — they add their own test logic on top and have built their own operating GUI.

Reproducing the messy parts

What makes motor firmware hard to test is the non-ideal behavior — and that is exactly what the counterpart reproduces deterministically, and what the customer can extend at will: end-stop variants and mechanical stops, the current profile within the PWM phase matched to real inductance and parasitic effects, hard load changes, mechanical backlash and non-ideal pulse encoders.

Tested interfaces (counterpart)

High-level overview of what the counterpart emulates and measures:

  • Motor drives (H-bridge PWM) with per-drive current sensing
  • Position feedback (quadrature encoders and analog)
  • Additional application-specific PWM signals
  • Digital and analog I/O, plus serial links, for the surrounding control signals

Result

  • Development desk

    Tested at the development desk instead of on real drive hardware.

  • Parallel

    Several units under test at once, instead of serially.

  • CI/CD

    Automated test runs on every commit.

Related: Workflow integration · Cyber Resilience Act · All reference projects