Home Assistant Blue - RTC backup battery sensor

Is it possible to create a sensor for monitoring the RTC backup battery level?
Did find this on a forum. Please advise.


batstat=`cat /sys/class/power_supply/battery/status`
batcap=`cat /sys/class/power_supply/battery/capacity`
bathealth=`cat /sys/class/power_supply/battery/health`
batvoltnow=`cat /sys/class/power_supply/battery/voltage_now`
batvoltnow=`awk "BEGIN {print $batvoltnow*0.000001}"`
battemp=`cat /sys/class/power_supply/battery/temp`
battemp=`awk "BEGIN {print $battemp*0.1}"`

msgbox "Battery Details:
Status: $batstat
Capacity: $batcap %
Voltage: $batvoltnow
Health: $bathealth
Temperture: $battemp C"

sudo chmod 755 "/opt/system/Battery Status.sh"

Tried this without luck:

  - platform: command_line
    command: "cat /sys/class/power_supply/battery/voltage_now"
    name: BTC backup battery
    unit_of_measurement: V

From HA logg:
2021-10-24 20:27:03 ERROR (SyncWorker_5) [homeassistant.components.command_line] Command failed: cat /sys/class/power_supply/battery/voltage_now

If ODROID Home Assistant OS are missing libraries/classes (power_supply?) then please add the classes necessary to create battery sensor for the backup battery.