All projects
Automation / IoT

Modbus LED Control

The tool connects to Modbus modules, sets supplemental lighting levels for individual zones and reads power consumption. Automatic mode calculates setpoints from PAR measurements and configured thresholds.

Modbus control cabinet and laptop for zone-based LED lighting control in a greenhouse

An application for real greenhouse lighting control over Modbus TCP, divided into independent zones.

Delivered scope

  • Tkinter application controlling eight lighting modules over Modbus TCP
  • Manual control for an individual zone or the complete installation
  • Automatic brightness calculation from PAR measurements and operating limits

Concrete outcomes

  • Real device communication through Modbus register reads and writes
  • Zone-based supplemental plant lighting control in a greenhouse
  • Power consumption visibility and response to installation energy limits

Problem

Greenhouse supplemental lighting requires independent zone control, reactions to current light measurements and power consumption monitoring. Setting every module manually makes consistent growing conditions difficult to maintain.

Solution

The Python application connects to eight slave devices over Modbus TCP. An operator selects a zone, sets its brightness percentage or applies a setpoint to all modules, while the interface reports connection state and power consumption.

  • Operating mode and setpoint writes to device registers.
  • Power consumption register reads for every zone.
  • Automatic control running in a separate thread.
  • Brightness interpolation from PAR measurements and thresholds.
  • A 10% reduction across all setpoints and a WhatsApp notification when import or export limits are exceeded.

Key decisions

The Tkinter interface handles zone selection, Modbus operations and background automation. Automation maps eight modules to PAR readings and calculates setpoints from five thresholds.

The public repository uses placeholder values for the module address, API endpoint and notification integration, keeping installation data private. The code shows real register read and write operations.

Result

The project demonstrates a complete operator application and Modbus installation integration, from light measurements and setpoint calculation to luminaire control and zone power monitoring.

Collaboration

Working on a similar technical problem?

Let us discuss an application, integration, automation workflow or device prototype.

Next projectFloraCue