Hello,
In the instructions it says to edit the display on the OLED display I would like the script under: sudo nano /opt/pironman/main.py this file no longer exists.
Can someone tell me the correct path?
Or is this only for the Version 2
Thanks
Hello,
In the instructions it says to edit the display on the OLED display I would like the script under: sudo nano /opt/pironman/main.py this file no longer exists.
Can someone tell me the correct path?
Or is this only for the Version 2
Thanks
To modify the OLED display of Pironman5:
1.The main code for controlling the OLED display and other functions is located in the pm_auto library’s pm_auto.py file:
2.You need to clone the repository and modify the oled_handler() function in the pm_auto.py file:
3.After making your changes, reinstall pm_auto in the virtual environment:
cd ~/pm_auto
/opt/pironman5/venv/bin/pip3 install ./
4.Then restart the Pironman5 service:
sudo systemctl restart pironman5.service
Hi,
any advise how I can change the Units in the OLED display under home assistant ?
I use a small 128GB nvme, currently it show 0.0 / 0.1TB which is not useful, better would be in GB for me.
I already installed the addon which is working fine but I could not find a way to change the units there
Well, AFAIK, you can get what you want but only if you hack the oled.py file. I did and now see 16/459 GB as opposed to 0/.4TB.
that’s what I thought but were can I find the oled.py /pm_auto.py file in home assistant ?
that’s the question
Well, I don’t run home assistant, but if runs on Linux, I would start with:
sudo apt install locate
sudo apt updatedb
locate oled.py
(that is what I did on Debian).
yes under a linux distribution I found it too but home Assistant is quite different
that’s why I was hoping someone knows where to look
➜ / uname -a
Linux a0d7b954-ssh 6.12.47-haos-raspi #1 SMP PREEMPT Tue Nov 4 13:30:17 UTC 2025 aarch64 Linux
➜ / find . |grep oled.py
➜ / pwd
/
➜ / ls -la
total 128
drwxr-xr-x 1 root root 4096 Dec 9 14:21 .
drwxr-xr-x 1 root root 4096 Dec 9 14:21 ..
-rwxr-xr-x 1 root root 0 Dec 9 14:21 .dockerenv
drwxr-xr-x 4 root root 4096 Dec 4 14:17 addon_configs
drwxr-xr-x 2 root root 4096 Oct 6 14:34 addons
drwxr-xr-x 2 root root 4096 Dec 9 04:47 backup
drwxr-xr-x 1 root root 4096 Nov 27 21:55 bin
drwxr-xr-x 2 root root 12288 May 7 2025 command
lrwxrwxrwx 1 root root 14 Dec 9 14:21 config → /homeassistant
drwxr-xr-x 4 root root 4096 Dec 9 14:21 data
drwxr-xr-x 16 root root 4420 Dec 9 14:20 dev
drwxr-xr-x 1 root root 4096 Dec 9 14:21 etc
drwxr-xr-x 1 root root 4096 Dec 9 14:21 home
drwxr-xr-x 8 root root 4096 Dec 9 14:21 homeassistant
-rwxr-xr-x 1 root root 1012 May 7 2025 init
drwxr-xr-x 1 root root 4096 Nov 27 21:55 lib
drwxr-xr-x 2 root root 4096 Nov 27 21:55 lib64
drwxr-xr-x 2 root root 4096 Oct 6 14:34 media
drwxr-xr-x 2 root root 4096 Oct 8 11:29 mnt
drwxr-xr-x 2 root root 4096 Oct 8 11:29 opt
drwxr-xr-x 1 root root 4096 May 7 2025 package
dr-xr-xr-x 335 root root 0 Dec 9 14:21 proc
drwxr-xr-x 1 root root 4096 Dec 9 16:05 root
drwxr-xr-x 1 root root 4096 Dec 9 14:21 run
drwxr-xr-x 1 root root 4096 Nov 27 21:56 sbin
drwxr-xr-x 2 root root 4096 Oct 6 14:34 share
drwxr-xr-x 2 root root 4096 Oct 8 11:29 srv
drwxr-xr-x 2 root root 4096 Oct 6 14:34 ssl
dr-xr-xr-x 12 root root 0 Dec 9 14:19 sys
drwxrwxrwt 1 root root 4096 Dec 9 16:05 tmp
drwxr-xr-x 1 root root 4096 Nov 27 21:54 usr
drwxr-xr-x 1 root root 4096 Nov 27 21:54 var
➜ /addon_configs ls -la
total 16
drwxr-xr-x 4 root root 4096 Dec 4 14:17 .
drwxr-xr-x 1 root root 4096 Dec 9 14:21 ..
drwxr-xr-x 2 root root 4096 Dec 4 14:17 6fa7f6d2_pironman5-max
drwxr-xr-x 3 root root 4096 Oct 30 12:23 core_zwave_js
➜ /addon_configs cd 6fa7f6d2_pironman5-max
➜ 6fa7f6d2_pironman5-max ls -la
total 8
drwxr-xr-x 2 root root 4096 Dec 4 14:17 .
drwxr-xr-x 4 root root 4096 Dec 4 14:17 ..
➜ /opt ls -la
total 8
drwxr-xr-x 2 root root 4096 Oct 8 11:29 .
drwxr-xr-x 1 root root 4096 Dec 9 14:21 ..
➜ /opt ll
total 0
At the risk of stating the obvious, perhaps you forgot an /?
This works for me:
sudo find / | grep oled.py
find: ‘/proc/378976/task/378976/net’: Invalid argument
find: ‘/proc/378976/net’: Invalid argument
find: ‘/proc/378977/task/378977/net’: Invalid argument
find: ‘/proc/378977/net’: Invalid argument
/opt/pironman5/venv/lib/python3.11/site-packages/pm_auto/oled.py
/opt/pironman5/venv/lib/python3.11/site-packages/pm_auto/oled.py.edited
➜ / sudo find / | grep oled.py
find: /proc/666/task/666/fdinfo: Permission denied
find: /proc/666/fdinfo: Permission denied
find: /proc/668/task/668/fdinfo: Permission denied
find: /proc/668/fdinfo: Permission denied
➜ /
nope but thanks for your effort , as I sad home assistant is quite different
Are you running HA inside a VM container or as a native OS?
Good question. To satisfy curiosity, I installed the OS downloaded from raspberrypi. AFAICT, all is in docker container/images and the Pironman5 is an addin image. That would pretty much eliminate any hacking. Not sure.
If I’ve understood your configuration correctly, but probably not, that would place your system files either side of that docker container, would it not? Possibly why you can’t find them, as you’re at the wrong side?
If one pursues further by cloning the addon and reading the dockerfile, one sees that it clones https://github.com/pironman5.git and runs it. I suppose one could clone, edit the oled.py file and then create their own repository, etc. Probably an exercise in learning docker as well as a black hole to throw time. I am not a home assistant user, but would probably try the option of installing Debian, add the Pironman stuff and then install home assistant. Thanks for the lesson ![]()