Lovelace Raspberry Pi Status Card

Am new to the entire HA scene, so please bear with me.

  1. I was able to get HA working in the supervised mode, got the Daemon working and and able to check status and the MQTT message.

Now when I got to my Configuration for the MQTT, I see the entities, but all the results are not available. In addition, I did get HACS and used the front end to get the card. But I am not sure how to add it to Lovelace.

Thanks in advanceScreen Shot 2021-10-05 at 10.57.15 PM

Screen Shot 2021-10-05 at 10.58.00 PM

When you see the {hostname} you have the Daemon config.ini not edited correctly. There should never be a value in braces if the config.ini is correct.

Sorry I missed this when you first reported it. -Stephen

Have you used HACS to install the RPI Monitor Card itself?

Hi, Iā€™ve just installed this and all up and running ok, however can I just run a quick query past anyone thatā€™s using this.?
The lovelace card for mine is showing ā€˜Storage use 72%ā€™ and the Sensor Card is showing ā€˜Fs free prcnt 72ā€™.
The first to me implies that itā€™s using 72% currently, whereas the latter Iā€™d take to be saying thereā€™s 72% free?

Hello. Install from hacs the integration. But even though the js file is loaded I canā€™t find any entity. I donā€™t quite understand something. If I have Home assistant OS installed, what do I have to do besides installing the integration? I have MQTT installed for other reasons. But what else should I do? Thank you very much

Hi everyone Iā€™m using the code
Lovelace Raspberry Pi Status Card, but I have a problem on the Home assistant board I can see the information of the raspberry on which I have loaded Volumio, while I see instead the information of either the raspberry Deluge or the raspberry NAS, but not both. Basically I see only 2 of 3 cards could you help me understand the problem I followed to the letter what is described in the guide. thank you

@claudiovillani58 please check the unique id for each of your RPiā€™s - it is affected by values in your config.ini files on each of the RPiā€™s. If two of your RPiā€™s happen to use the same unique id then you will only see two instead of all three. Use a utility ( e.g., Mqtt Box, or MQTT Explorer) to see whatā€™s being reported from each RPI - when you see three different values then you should see all three RPis on your home assistant board.

Thanks Stefano for your quick reply, tomorrow I will do the tests and I will let you know the result

Hi Stefano, I take some time before asking you for new info or giving you my information as you requested. Iā€™m using MQTT explorer but I still have to understand where the error I described in the first message is. Iā€™m afraid I have some problem on Home Assistant like something is left dirty. With MQTT Explorer it seems that the IDs of the other Raspberry are unique everyone has their own I will investigate and let you know thanks
Claudio

Hello Stefano, here I am to ask you again how to see the daemon information for a single raspberry on Home Assistant?
As I mentioned previously, I have 4 Raspberry divided as follows:
Home Assistant
Deluge
Volumio
NAS
Now when they are all up and running, I find myself that on the Home Assistant board dedicated to collecting the Raspberry temperature monitoring information, sd occupation etc, I only see the info for Raspberry Deluge and Volumio and I donā€™t see those of the NAS.
If I turn off Deluge and restart Home Assistant then I see those of Volumio and the NAS.
In this regard, I looked at the DAEMON configuration of each one that I am attaching below and they are the same in everything. I cannot understand if the distinction between the Raspberry NAS and Deluge must be made within this configuration if you could tell me where?
For completeness using MQTT Explorer I also captured the info of both the Raspberry NAS and Deluge individually and I saw that both have a unique ā€œid identifiersā€, but when they are both active I can monitor either only the Raspberry NAS or only the Deluge it is as if one wrote on the other.
I premise that the Home Assistant configuration is completely new.
Can you help me?
Thanks Claudio

NAS

{ā€œinfoā€: {ā€œtimestampā€: ā€œ2022-07-18T16:43:56+02:00ā€,
ā€œrpi_modelā€: ā€œRPi 4 Model B r1.5ā€,
ā€œifacesā€: ā€œe,w,bā€,
ā€œhost_nameā€: ā€œraspberrypiā€,
ā€œfqdnā€: ā€œraspberrypiā€,
ā€œux_releaseā€: ā€œbullseyeā€,
ā€œux_versionā€: ā€œ5.15.32-v7l+ā€,
ā€œup_timeā€: ā€œ4 days, 19:27ā€,
ā€œlast_updateā€: ā€œ2022-07-13T20:13:38+02:00ā€,
ā€œfs_total_gbā€: 32,
ā€œfs_free_prcntā€: 13,
ā€œnetworkingā€: {ā€œeth0ā€: {ā€œIPā€: ā€œ192.168.178.35ā€,
ā€œmacā€: ā€œe4:5f:01:b0:91:80ā€},
ā€œwlan0ā€: {ā€œIPā€: ā€œ192.168.178.36ā€,
ā€œmacā€: ā€œe4:5f:01:b0:91:81ā€}},
ā€œdrivesā€: {ā€œrootā€: {ā€œsize_gbā€: 32,
ā€œused_prcntā€: 13,
ā€œdeviceā€: ā€œ/dev/rootā€,
ā€œmount_ptā€: ā€œ/ā€},
ā€œmnt-musicaā€: {ā€œsize_gbā€: 1024,
ā€œused_prcntā€: 53, ā€œdeviceā€: ā€œ/dev/sda1ā€,
ā€œmount_ptā€: ā€œ/mnt/musicaā€},
ā€œmnt-backupā€: {ā€œsize_gbā€: 1024,
ā€œused_prcntā€: 81, ā€œdeviceā€: ā€œ/dev/sdb1ā€,
ā€œmount_ptā€: ā€œ/mnt/backupā€}},
ā€œmemoryā€: {ā€œsize_mbā€: ā€œ7898.922ā€,
ā€œfree_mbā€: ā€œ7415.949ā€},
ā€œcpuā€: {ā€œhardwareā€: ā€œBCM2711ā€,
ā€œmodelā€: ā€œARMv7 Processor rev 3 (v7l)ā€,
ā€œnumber_coresā€: 4,
ā€œbogo_mipsā€: ā€œ432.00ā€,
ā€œserialā€: ā€œ10000000561b74bfā€,
ā€œload_1min_prcntā€: 0.0,
ā€œload_5min_prcntā€: 0.0,
ā€œload_15min_prcntā€: 0.0},
ā€œthrottleā€: [ā€œthrottled = 0x0ā€,
ā€œNot throttledā€], ā€œtemperature_cā€: 41.3,
ā€œtemp_gpu_cā€: 41.3, ā€œtemp_cpu_cā€: 40.4,
ā€œreporterā€: ā€œISP-RPi-mqtt-daemon v1.6.0ā€,
ā€œreport_intervalā€: 5}}

{ā€œnameā€: ā€œRpi Used Raspberrypiā€,
ā€œuniq_idā€: ā€œRPi-e45f01Monb09180_disk_usedā€,
ā€œunit_of_measurementā€: ā€œ%ā€,
ā€œstat_tā€: ā€œ~/monitorā€,
ā€œval_tplā€: ā€œ{{ value_json.info.fs_free_prcnt }}ā€,
ā€œ~ā€: ā€œhome/nodes/sensor/rpi-raspberrypiā€,
ā€œpl_availā€: ā€œonlineā€,
ā€œpl_not_availā€: ā€œofflineā€,
ā€œicā€: ā€œmdi:sdā€,
ā€œavty_tā€: ā€œ~/statusā€,
ā€œdevā€: {ā€œidentifiersā€: [ā€œRPi-e45f01Monb09180ā€]}}


DELUGE

{ā€œinfoā€: {ā€œtimestampā€: ā€œ2022-07-18T21:04:40+02:00ā€,
ā€œrpi_modelā€: ā€œRPi 4 Model B r1.4ā€,
ā€œifacesā€: ā€œe,w,bā€,
ā€œhost_nameā€: ā€œraspberrypiā€,
ā€œfqdnā€: ā€œraspberrypiā€,
ā€œux_releaseā€: ā€œbullseyeā€,
ā€œux_versionā€: ā€œ5.15.32-v7l+ā€,
ā€œup_timeā€: " 3:51",
ā€œlast_updateā€: ā€œ2022-07-13T09:55:16+02:00ā€,
ā€œfs_total_gbā€: 32, ā€œfs_free_prcntā€: 13,
ā€œnetworkingā€: {ā€œeth0ā€: {ā€œIPā€: ā€œ192.168.178.33ā€,
ā€œmacā€: ā€œe4:5f:01:67:f1:8dā€},
ā€œwlan0ā€: {ā€œIPā€: ā€œ192.168.178.34ā€,
ā€œmacā€: ā€œe4:5f:01:67:f1:8eā€}},
ā€œdrivesā€: {ā€œrootā€: {ā€œsize_gbā€: 32, ā€œused_prcntā€: 13,
ā€œdeviceā€: ā€œ/dev/rootā€, ā€œmount_ptā€: ā€œ/ā€},
ā€œmnt-torrentsā€: {ā€œsize_gbā€: 64, ā€œused_prcntā€: 29,
ā€œdeviceā€: ā€œ/dev/sda1ā€,
ā€œmount_ptā€: ā€œ/mnt/torrentsā€}},
ā€œmemoryā€: {ā€œsize_mbā€: ā€œ3838.922ā€,
ā€œfree_mbā€: ā€œ3463.617ā€},
ā€œcpuā€: {ā€œhardwareā€: ā€œBCM2711ā€,
ā€œmodelā€: ā€œARMv7 Processor rev 3 (v7l)ā€, ā€œnumber_coresā€: 4,
ā€œbogo_mipsā€: ā€œ504.00ā€, ā€œserialā€: ā€œ10000000844dfbe2ā€,
ā€œload_1min_prcntā€: 0.0, ā€œload_5min_prcntā€: 0.5,
ā€œload_15min_prcntā€: 0.0}, ā€œthrottleā€: [ā€œthrottled = 0x0ā€, ā€œNot throttledā€],
ā€œtemperature_cā€: 41.8, ā€œtemp_gpu_cā€: 41.8,
ā€œtemp_cpu_cā€: 41.4,
ā€œreporterā€: ā€œISP-RPi-mqtt-daemon v1.6.0ā€, ā€œreport_intervalā€: 5}}

{ā€œnameā€: ā€œRpi Monitor Raspberrypiā€,
ā€œuniq_idā€: ā€œRPi-e45f01Mon67f18d_monitorā€,
ā€œdev_claā€: ā€œtimestampā€, ā€œstat_tā€: ā€œ~/monitorā€,
ā€œval_tplā€: ā€œ{{ value_json.info.timestamp }}ā€,
ā€œ~ā€: ā€œhome/nodes/sensor/rpi-raspberrypiā€,
ā€œpl_availā€: ā€œonlineā€, ā€œpl_not_availā€: ā€œofflineā€,
ā€œicā€: ā€œmdi:raspberry-piā€,
ā€œavty_tā€: ā€œ~/statusā€,
ā€œjson_attr_tā€: ā€œ~/monitorā€,
ā€œjson_attr_tplā€: ā€œ{{ value_json.info | tojson }}ā€,
ā€œdevā€: {ā€œidentifiersā€: [ā€œRPi-e45f01Mon67f18dā€],
ā€œmanufacturerā€: ā€œRaspberry Pi (Trading) Ltd.ā€,
ā€œnameā€: ā€œRPi-raspberrypiā€,
ā€œmodelā€: ā€œRPi 4 Model B r1.4ā€,
ā€œsw_versionā€: ā€œbullseye 5.15.32-v7l+ā€}}


Dati per configurazione file: config.ini

Configuration file for RPi-Reporter-MQTT2HA-Daemon

Source: https://github.com/ironsheep/RPi-Reporter-MQTT2HA-Daemon

Uncomment and adapt all settings as needed.

Some settings can be configured by environment variables.

If an env variable is set, it takes precedence over settings in this file

[Daemon]

Enable or Disable an endless execution loop (Default: true)

#enabled = true

This script reports RPi values at a fixed interval in minutes [2-30], [Default: 5]

#interval_in_minutes = 5

default domain to use when hostname -f doesnā€™t return a proper fqdn

#fallback_domain = home

[MQTT]

The hostname or IP address of the MQTT broker to connect to (Default: localhost)

Also read from the MQTT_HOSTNAME environment variable

hostname = 192.168.178.30

The TCP port the MQTT broker is listening on (Default: 1883)

Also read from the MQTT_PORT environment variable

port = 1883

Maximum period in seconds between ping messages to the broker. (Default: 60)

#keepalive = 60

by default Home Assistant listens to the /homeassistant but it can be changed for a given installation

likewise, by default this script advertises on the same default topic. If you use a different

discovery prefix then specify yours here. [default: homeassistant]

discovery_prefix = homeassistant

NOTE: The MQTT topic used for this device is constructed as:

{base_topic}/{sensor_name}

The MQTT base topic under which to publish the Raspberry Pi sensor data topics.

#base_topic = home/nodes

The MQTT name for this Raspberry Pi as a sensor

#sensor_name = rpi-{hostname}

The MQTT broker authentification credentials (Default: no authentication)

Will also read from MQTT_USERNAME and MQTT_PASSWORD environment variables

username = mqtt_user
password = bioversityundesa2018

Enable TLS/SSL on the connection

#tls = false

Path to CA Certificate file to verify host

#tls_ca_cert =

Path to TLS client auth key file

#tls_keyfile =

Path to TLS client auth certificate file

#tls_certfile =

ok, maybe I see whatā€™s happening.

In each of your config files uncomment the above line.

Then change the value to be appropriate to your host name:

  sensor_name = rpi-nas

-or-

   sensor_name = rpi-deluge

Then restart the daemon on each and see if they both appear.

If you send me the advertisement info for each I can better see whatā€™s happening.
You sent the advert for different sensors for the NAS and DELUGE RPiā€™s - it would be better if you sent the advert. data for the same sensor .
(meaning you sent DISK USED sensor: ā€œuniq_idā€: ā€œRPi-e45f01Monb09180_disk_usedā€, and MONITOR sensor: ā€œuniq_idā€: ā€œRPi-e45f01Mon67f18d_monitorā€)

Send the _monitor sensor data for both instead so they can more directly be compared.

Anyway, this should help you. I think your systems just need an adjustment to their config.ini files.

I look forward to hearingā€¦

Regards,
Stephen

Good evening Stefano finally following your suggestions I was able to get individual information for the NAS and DELUGE as you said You were just a matter of writing in the config.in the value rasy-xxxxx
Thank you for your contribution and if I need to, I will disturb you again.
I must also thank you for suggesting the use of MQTT Explorer, a really great tool.
Thanks Claudio

I had a ton of issues getting and keeping this thing working and it only gave 5 sensors. I switched to Glances, it can run on Linux, windows, Piā€™s and it allows you to track much more about the hardware if you want. Also, it requires no messing with any annoying MQTT and took a fraction of the time to set up multiple pcā€™s and piā€™s than it did to get RPi monitor to work on 1 pi.!

https://glances.readthedocs.io/en/latest/api.html
Screenshot from 2022-11-03 17-07-02|616x500

I tried the Glances integration, but it is missing some key sensor, most notably, network throughput. I have had no problems RPi-Reporter-MQTT2HA-Daemon once I read ALL the directions over the three GitHub links. (I missed how to get the command buttons working when the script is run as a daemon.)

The script is running well, and I have been customizing the sensors using templates, but for the life of me, I cannot figure out how to get the health chips/buttons to appear. https://github.com/ironsheep/lovelace-rpi-monitor-card/blob/562180b6a35bb76cbd332e15bf3d4c581048f58e/DOCs/images/newIndicatorsV2.png

If someone has done this, Iā€™d really appreciate a nudge in the right direction.

Thank you.

Thanks for everyoneā€™s help. Was able to get all 4 piā€™s reporting and doing remote commands by following the guide.

There was some back and forth on setting this up on the HAS - anyone get that successfully completed? How can I have a card w/ the HAS Pi information? ended up just using systemmonitor

How do I get more data into the cards? i.e the IP address? I only have the 5 sensors created

First I am only just getting started on home assistant and trying to use the card on my home assistant running on a raspberry Pi 4. I have installed mqtt and terminal and ssh but I cannot work out how to get the daemon installed as I keep getting the error sudu is an unknown command. How do I get to where I can install it or do I need to do something different in Home assistant. I have the card installed and the java script so I assume once I get the daemon installed it will fly.

are you installing on a DIFFERENT rpi4 (not your HAS)?

Ok, so I am a dumb you know what! My mqtt config just never changes and I forgot about the sensor file format change a few versions back and was editing my old reference file, in the wrong format and was expecting the thing to work!

So, I love and use this card oftenā€¦ but I have hit a snag in my latest attempt with a new pi. I have built a pi terminal server for a couple of random devices that I want remote console access to, the pi is not online all of the time like my others. This is where the problem appears, I would like to create a card that appears when the pi is up and hides when the pi is down. The appear is very easy, just turn it on and waitā€¦ the disappear is not so easy, when I turn it off it never goes away!

I think the problem is that the main sensor is retained, and I do not know how to change that behavior.

If I turn the pi off and reboot HA, the card is properly hidden as the sensors return unavailable state.

Off state:
image

On state:
image

Card config:

type: conditional
conditions:
  - condition: state
    entity: sensor.rpi_ts_pi_home_rpi_monitor_ts_pi
    state_not: unavailable
card:
  type: custom:rpi-monitor-card
  entity:
    - sensor.rpi_ts_pi_home_rpi_monitor_ts_pi
  card_style: glance
  temp_scale: f
  temp_severity:
    - color: '#00e64d'
      from: 0
      to: 60
    - color: '#ff944d'
      from: 61
      to: 80
    - color: '#ff4d4d'
      from: 80
      to: 100
  fs_severity:
    - color: '#00e64d'
      from: 0
      to: 40
    - color: '#ff944d'
      from: 41
      to: 75
    - color: '#ff4d4d'
      from: 76
      to: 100

So further updateā€¦ I found an mqtt topic that reflects the state of the piā€¦
image

And I added the following sensor to my mqtt.yaml included file:

    - name: "rpi_ts_status2"
      icon: mdi:lan
      state_topic: "home/nodes/sensor/rpi-ts-pi/status"

The mqtt broker sees the inbound state, but the sensor is never built or populatedā€¦ it does not appear in developer tools as a sensor. Why, what in the hell am I doing wrong? I have dozens of sensors in my mqtt.yaml and all of them are working.

@IronSheep

Hi,

Was hoping for some clarification. Very new to MQTT. Some degree of experience with Piā€™s. I have several running NUT.

On the Piā€™s themselves Python needs to be installed in order for the data to be sent back. Sorry if this is obvious but for the data to get to HA all you need is MQTT on HA. Your python script has MQTT built in? In terms of MQTT will the one included with HA suffice. Assuming so. My HA installation is not exposed to internet and probably never will be. Any other gotchaā€™s or tips in setting this up. I got a spare Pi 5 not running NUT so I want to start with that and if I hose it then thatā€™s ok. Rather to get this right before installing on my NUT Piā€™s. Thanks for any tips