I am trying to get this working with an old phone, but I have problems with the sensors. Image camera works great, even I can turn off the screen but still working.
My problem is with the sensors. After a while, in home assistant the sensors stop refreshing and only if I restart HA they start working again for a while.
Now I am trying to set up the sensors manually, like this:
sensor:
- platform: rest
name: battery level
device_class: battery
resource: http://IP:PORT/sensors.json?sense=battery_level
value_template: ‘{{ value_json.battery_level.data[0][1][0] | round(0) }}’
If I go to http://IP:PORT/sensors.json?sense=battery_level in my browser, it is allways working. I am not sure how HA is able to read that page as the web ask for credentials…
But it does not work (unknown) and I can not see any errors in the log. Any suggestions?