@gareth.cheyne did you ever get this working? About to order one of the Uctronics 1U rackmount setups.
I’ve started and yes had some success how ever have not finished the project yet.
Basically I created a custom add on to HASS and managed to write to the screen, just need to clean it up and present the data of choice.
Do you want me to share what I have done? It’s a bit messy but if you do any sort of coding you be able to follow.
Would love to see a link to what you’ve got. Thanks for building this!
Have a look here, garethcheyne/HomeAssistant (github.com) add this to your Addons, and run the script, I have it work. It needs a lot of work, but it is working.
This is totally a work in progress, and in no way is ready for any sort of production env.
Took code from a few places.
UCTRONICS own repo, for baseline C
garethcheyne/HomeAssistant (github.com)
This repo form adamoutler to emable I2C interface in HassOS
adamoutler/HassOSConfigurator: A set of Add-Ons to configure HassOS For various platforms and development purposes. (github.com)
Thanks to Lockdown I have this working :). Still needs work, but it is working.
I am having a nightmare trying to get this to work.
I installed the I2C configurator and followed those instructions. Then I installed your script with no luck…
What does it say in the log?
Do you see this, or something else?
Thanks for the work that you did on creating this plugin. I also struggled to get the initial steps to complete, and kept on getting a message about not being able to find run.sh. I ended up just going through the install process using the https://community.home-assistant.io/t/add-on-hassos-i2c-configurator Add On, and then installing this one to run the OLED software. Looking forward to future development on it!
Yeah, I need to try this on a clean system, and see what’s happening. But you did fine a way to get it to work
Be good is there was someone around that can code C, then we cant make it alot cooler, HS logos etc, change the F to C etc.
Yeah. I’m diving a bit into the C code now. But day job keeps me pretty busy–we will see.
I’m curious, what would the #1 thing be that you would like to be able to display also?
So the code that is being used is from UCTRONIC, and the have F set for temperature unit, but for the life of me I cant see where that is, and being able to change it to C.
Would also be very cool if we could have like a Home Assistant flash screen, that shows, with there logo etc.
The F is encoded as part of the bitmap in bmp.h
that gets drawn by OLED_DrawBMP
. It’s kind of pain to translate, but I think I got it: https://github.com/garethcheyne/HomeAssistant/pull/1
Done, thanks mate, and working fine for me.
Have you got this working for yourself?
Yeah. The C is showing up on mine now.
If you or someone with design skill wants to create a Home Assistant Banner black and white bitmap (128 pixels wide x 32 pixels tall), I can encode it and add it to the rotation.
Nice work @dcwalter. I have added a few images to the img directory. Also to note, that the Memory, and Disk screen seen to be pushed left, compared to CPU Screen.
One thing I forgot about was the CPU Usage, grep -bn1 | grep load | awk ‘{printf “%.2f”, $(NF-2)}’", “r” does not seem to work in HA Pi.
New Pull Request with the HA logo screen added and the CPU load grep command fixed. Thanks for creating the BMP and corresponding header file. I’ll work on the logo alignment and some general code cleanup next. Then I will move onto enabling for more user customization without having to modify the C code.
This is super cool, I love when I think to myself “I should figure out how to do this” and then it is already done. I am running into an issue though.
Log output:
[17:11:47] INFO: Disable Auto Start = false
/dev/i2c-1
[17:11:47] INFO: Got i2c access! WoHOo!
[17:11:47] INFO: Display Info to OLED
Screen output.
Any thoughts or tips?