Skip to main content

Sprinkler Control 5: Web Dashboard

Loading...

In this next iteration of the Sprinkler Control project, the ability to monitor the state of and control the sprinkler relay remotely is added. This is done through the dashboard, a page of your device's web interface that can host widgets. The dashboard is configured on the General subpage of the Web Dashboard page of the Features tab. Open this page to see the widget this project uses:

sprinkler_widgets

The widget is of the Switch type. The switch is "connected" to the manual_override variable:

sprinkler_dashboard_variable

This "connection" is bi-directional:

  • If you push the "ON" or "OFF" button on the TPS, the dashboard switch will reflect the current manual_override state.
  • If you flip the switch on the dashboard, the manual_override variable will be updated.
sprinkler_control_5

To react to the dashboard switch flips, an On Variable Changed event block has been added to the application. This event triggers when the corresponding variable value changes.

The On Variable Changed block was first introduced in the Settings project.

This, and many other projects, takes advantage of the LUIS interface. The application makes two settings -- Ethernet DHCP and Ethernet IP -- accessible from the LUIS smartphone app.