Skip to content

A13 - Interfaces and Applications

Brief


  • Write an application that interfaces a user with an input and/or output device(s) on a board that you made.

Picking my application


A user interface will be paramount to being able to easily use the PlantPulse system, being able to access it on multiple devices and letting it be customisable are essential.

That's why Flask will be used.

For this weeks assignment, I'll create a simple Flask Server to send a message to our ESP32 (through MQTT (AdafruitIO) to control an LED matrix on the Hub.

Programming

Like all good projects it started with some research then straight to ChatGPT.

I reviewed the docs page to make sure what I was doing is possible, and started by asking ChatGPT to do the heavy lifting and customise it from there.

xxx TODO: chatGPT prompts

Then this was integrated with MQTT, a topic was setup with the colour and coordinate of the pixel to be set on the matix display.

xxx TODO: receiver code

Using the inteface

The user can enter the X-Y coordinate, then select: 'Red', 'Green' or 'Blue' (or their own RGB value), and click send to send a message over MQTT.

The Hub is listening to that topic and upon receiving a message will set the pixel and colour values accordingly.

xxx TODO: video of the thing working

FILES

DOWNLOAD LINKS HERE