Governing equations
The motor and roller are represented by one rotational degree of freedom:
J dω/dt = τmu − bω − τL ω / √(ω² + ωs²)
The controller samples a delayed encoder value and holds its command between updates:
ek = ω* − ω(tk − τd)
u = clamp(Kpe + Ki∫e dt, −1, 1)
ω is shaft speed (rad/s), J is inertia (kg·m²), b is viscous drag (N·m·s/rad), τm is maximum motor torque (N·m), u is the normalised drive command, and τL is conveyor load torque (N·m). The small ωs term smooths the load transition around zero speed.
Fixed illustrative constants: τm = 2.4 N·m, b = 0.018 N·m·s/rad, and ωs = 0.25 rad/s. The drive-roller radius is 0.08 m (scaled).
Why delay matters
A delayed measurement describes an earlier motor state. By the time the controller reacts, the motor may already have accelerated or slowed further. The controller can therefore add torque after the original error has begun to disappear, then remove torque too late. Sampling also holds each command until the next update. Together, measurement age and sample-and-hold behaviour add phase lag to the feedback loop.
What is simplified
The electrical current loop is assumed to be much faster than the speed loop, so the motor is treated as a torque source with a hard command limit. Gear compliance, belt elasticity, sensor quantisation, PWM ripple, bearing friction details, and structural vibration are omitted. The load torque is a smooth resisting term rather than a detailed package-by-package model.
What is illustrative
Motor torque, viscous drag, inertia, roller radius, controller gains, and preset values are illustrative teaching parameters, not specifications for a real machine. The model is suitable for exploring qualitative feedback behaviour, not selecting industrial control settings.
Numerical method
The mechanical state is integrated with fourth-order Runge–Kutta at a fixed 1 ms time step. Controller updates occur on the selected sample clock; the delayed encoder value is read from a fixed-step history buffer. Rendering uses a separate animation clock and does not set the physics step size.
A generic educational motor-and-conveyor model. Not affiliated with any motor, drive, or control-system manufacturer.