PID Controllers and Setpoints

Last updated March 14, 2026


What is PID Control?

PID (Proportional-Integral-Derivative) control is a feedback mechanism that automatically adjusts an actuator output to maintain a sensor reading at a desired setpoint. For example, maintaining grow room temperature at exactly 24 degrees by modulating a heater.

PID Dashboard Widgets

SetpointInput Card

The SetpointInput card lets you adjust the target value for a PID controller:

  • Enter a numeric value in your preferred units
  • Click Confirm to send the new setpoint to the Pi
  • The card shows the current setpoint and the live process variable
  • An inline Cancel button lets you discard changes before confirming

Setpoints are written to Firebase RTDB at /devices/{id}/setpoints/{name} and picked up by the Node-RED PID node on the Pi.

PID Indicator Card

The PID indicator shows the controller status:

  • Enabled/Disabled toggle — Turn the PID loop on or off
  • Current output — The control signal being sent to the actuator (0-100%)
  • Process variable — Current sensor reading
  • Setpoint — Target value
  • Error — Difference between setpoint and process variable

PID Settings Modal

Click the settings icon on a PID indicator to open the configuration modal:

  • Proportional gain (Kp) — How aggressively to respond to current error
  • Integral gain (Ki) — How aggressively to respond to accumulated error
  • Derivative gain (Kd) — How aggressively to respond to rate of change
  • Output limits — Min and max output values
  • Setpoint — Target value

PID Runs on the Pi

PID controllers execute entirely on the Raspberry Pi via Node-RED. This is critical for safety:

  • No cloud dependency — The PID loop continues operating even if internet connectivity is lost
  • Low latency — Control decisions happen locally without round-trip to the cloud
  • Fail-safe — The Pi maintains the last known setpoint if cloud connection drops

The dashboard is for monitoring and adjusting setpoints. The actual control logic never runs in the cloud.

Initial Setpoints

When deploying a new flow with PID controllers, you can set initial setpoints in the Configurator. These are applied when the flow first starts on the Pi.

Disambiguated Labels

When multiple PID controllers exist (e.g., temperature PID and humidity PID), the setpoint labels are automatically disambiguated to avoid confusion.

Next Steps

pidsetpointcontrol