Joolee / nl.joolee.homey.espeasy

ESP Easy is a firmware for ESP8266 boards like the WeMos D1 and NodeMCU. It allows you to quickly make custom devices with switches, sensors and other hardware. This app adds support to Homey for connecting with ESP Easy units.
GNU General Public License v3.0
6 stars 5 forks source link

[REQUEST] LCD display support #14

Closed MrBlue90 closed 2 years ago

MrBlue90 commented 3 years ago

Dear developer,

First I would like to thank you for creating this app. It really opened a complete new world for me in the domotics landscape!

I've been connecting my cheap RFID door opener to my nodeMCU and got it connected to Homey. So far, so good..

Now I've been looking into LCD displays like these to display my alarm status: https://www.aliexpress.com/wholesale?catId=0&initiative_id=SB_20200727125628&SearchText=ssd1306 They are supported in ESP Easy, but I don't believe there's a way to control them over Homey.

Would it be possible to add a display device so the lines can be set over a flow? image

Thanks, Rick

Joolee commented 3 years ago

I think I'll be able to make that work: https://www.letscontrolit.com/wiki/index.php?title=OLEDDisplay

Can you test if you can use these commands?

[<taskname>].OLED,<row>,<col>,<text> 
[<taskname>].OLEDCMD,<value>

I want to be able to target a specific OLED display that is connected, otherwise, I will be sending commands to all of them... Also, can you find out whether sending text like {D} to get a degree sign actually works? And what happens when you send a degree sign without translating it to {D}? I can include the translation table in the app but It's nice to know it works and it actually is necessary.

Homey will be sending commands with a HTTP GET request like so: http://192.168.xxx.xxx/control?cmd=mydisplay.OLED,1,1,test%20text Can you test your commands that way?

MrBlue90 commented 3 years ago

I currently don't own such a display yet. Want to make sure it's supported before ordering. I was indeed looking into the commands, and since I receive an 'OK' from the webserver, I feel that at least that should be working. Is there a way to see the values (virtually) that I shared over cmd?

Joolee commented 3 years ago

You might be able to see them in the log if you set logging to high. I don't know for sure though.

MrBlue90 commented 3 years ago

It gave me this: 15254991: HTTP: OLED,1,1,TestTextOnDisplay 15254994: Command: OLED

So not really the outcome I was looking for. I obviously can order a display at Ali, but it might take some time to get shipped.

Joolee commented 3 years ago

It looks good though. Worst case, you can use it by triggering custom rules or commands (which is on my to-do list #2) with Homey.

I can't make the <taskname> version give me an OK though, that's a bit weird.

Joolee commented 3 years ago

I have fixed issue #2 so in the next version, you can run custom commands on the unit.

I want to see the commands below working before I add the plugin as a device. I don't want a user to accidentally control multiple OLED displays, that would get confusing.

[<taskname>].OLED,<row>,<col>,<text> 
[<taskname>].OLEDCMD,<value>

I'll look into this a bit more some time but if you can confirm you got the commands above working, I'll make the plugin. Shouldn't be too much work now that I have action cards implemented.

MrBlue90 commented 3 years ago

Great news! I've received the displays and did some testing.

In fact, there seems to be a difference between OLED and OLED FRAMED and in my scenario, OLED FRAMED worked best so far.

By triggering the following URL, I get to change text on my display: http://<IP>/control?cmd=OLEDFRAMEDCMD,<ROW>,<Text>

Joolee commented 3 years ago

Is there also a way to specifically control a single oled panel? Otherwise, I'll have to restrict the oled devices to a single one per unit.

MrBlue90 commented 3 years ago

Beat me to it, but I don't believe you can connect more than one display. https://espeasy.readthedocs.io/en/latest/Plugin/P036.html

Joolee commented 2 years ago

Decided not to implement this for now. It's a lot of work to implement the most used display plugins and they can all be controlled by just sending commands to the unit with the available action flowcard.