MagicMirror module for Hoymiles Wifi inverter info
This module is still under development.
It might not work, can show incorrect results, will lack some counters, etc.
Test environment:
Installation can be done using the original repository or the develop repository.
cd ~/MagicMirror/modules/
git clone https://github.com/schris88/MMM-Hoymiles-Wifi
cd ~/MagicMirror/modules/
git clone https://github.com/evroom/MMM-Hoymiles-Wifi
Edit the file ~/MagicMirror/config/config.js
to add or modify the module.
{
module: "MMM-Hoymiles-Wifi",
position: "top_left",
config: {
width: "300px",
height: "320px",
updateInterval: 60000, // in milli seconds
frames : [
{ src: 'http://127.0.0.1:5000' },
]
},
},
Install all Python requirements:
pip install -r requirements.txt
If you see this error:
error: externally-managed-environment
then try this:
python -m pip install -r requirements.txt --break-system-packages
Use you favorite editor to make the change (here nano).
nano HoymilesWifi.sh
Line to edit:
python hoymiles_data.py --dtu_ip_address <DTU_HOST_IP>
Where <DTU_HOST_IP>
is the IP address of the DTU.
To turn on debugging:
python hoymiles_data.py --dtu_ip_address <DTU_HOST_IP> --debug
To start HoymilesWifi.sh
manually:
./HoymilesWifi.sh
To add HoymilesWifi.sh
to pm2:
pm2 start HoymilesWifi.sh
pm2 save
hoymiles-wifi --host <DTU_HOST_IP> identify-inverters
Where <DTU_HOST_IP>
is the IP address of the DTU.
When this message is printed, it means that the inverter is turned off (mostly after sunset):
No response or unable to retrieve response for identify-inverters
pm2 status
pm2 info HoymilesWifi
pm2 logs HoymilesWifi --lines 100
Use you favorite editor to make the change (here nano).
nano HoymilesWifi.sh
Line to edit (add --debug --test):
python hoymiles_data.py --dtu_ip_address <DTU_HOST_IP> --debug --test
Where <DTU_HOST_IP>
is the IP address of the DTU.
The test dataset is taken from response_test_data.json
.
Do not forget to remove --test
after testing.