MQTT Monitor with a HyperPixel


#1

I’m running Home Assistant as an IoT/home automation hub, and one of the things I wanted to achieve was to have a status display somewhere near the front door so I could quickly check the state of the house when I leave / enter.

I picked up a couple of HyperPixel displays from Pimoroni and thought it was the ideal platform for this stuff, so I put together a fairly simple start point. Since the display is sitting on a Zero W, I wanted to make it as lightweight as possible so I disabled X and use fbi to output the images to the display.

You can find the source of the project over on GitHub. If you have any suggestions for accepting touch input at the command line I’d be interested to hear. I’d like to make the display accept touch so I can cycle through different layouts, and possibly write values back to MQTT to control things I forgot to turn off.


#2

Aha. Touch input can be read from the screen using

import evdev
device = evdev.InputDevice('/dev/input/event0')
for event in device.read_loop():
    if(event.type == 3 and event.code == 57 and event.value == 00):
        print(event)
        print('screen touch detected');

I just need to tie it all in now.


#3

Very nice. :) Makes me want one, must stop, trying to save money.


#4

It’s worth waiting.

The project has stalled somewhat for me due to work pressure but I’m aiming to accept touch input soon


#5

With the new Hyperpixel 4.0 that I’ve just bought, I’m very interested in your solution to integrate with Home Assistant. Unfortunately I can’t program, so I was hoping you might have had chance to implement touch into the code? Thanks!