I noticed under MQTT you can have a sensor with the class of ‘Battery’, this is nice because the icon changes based on the value.
I have created a ESP8266 device that reports its own WiFi signal strength, this is published to MQTT. It would be great to have a WiFi RSSI class that measures in ‘dBm’ and changes the icon based on strength.
The negative value of dBm is somewhat confusing for basic users.
I think signal displayed with the bars might be helpful
I am actually doing that with the custom template card… the MQTT sensor reports strength from 0-100 but using a template you can convert to dBm and then set the icon according to the strength. I have my Lovelace code for how to do it in that thread for the 100% Templatable something… search 100% template and you’ll see it
David how did you do this template card. I want to show the dbm in the negative form but MQTT shows the RSSI as a positive number. I saw where you did the section in your lovelace for “MQTT & Wifi Connections” but I could not figure out how to convert that from the Lovelace file format to the UI format but from I see it will show the -dB value in the card correct?
Now I took what you had to work the device I needed it for but not getting a result am I doing it wrong? This is an manually entered card in the Lovelace UI on the dashboard so things maybe out of order some.
Yeah it shows the attributes under the status part of the sensor. I am using Tasmata too on this Sonoff S31 plug. I renamed it for wifi strength but it should be all the attributes or am I missing something?
Ah found it type on my part. When I copied the sensor name it did not copy the “sensor.xxxxx” part. Awesome working great now. I can you pull up time off that attributes too, I see it there but how would you change the code to pull that?
Thanks a bunch for the help, you are the code master…lol
Just duplicate the format of the other attributes… Just remember var[0] is the first variable and there are 3 variables in my example for each sensor so thus var 0-2 so if you add another one it’s var[3] - just follow the format of the other ones.
Hi, I’m trying to get something similar set up for getting the signal strength from my pool controller. Mine is based on an ESP32 board, so I’ve had to modify your code a bit, and didn’t need as many variables for my application (I only want to know the wifi strength and change the icon).
Basically, I’d like it to look exactly like the top card, but to change the icon, and maybe say “Pool Controller Wifi Signal: Weak/Fair/Good” in the title, based on the wifi signal strength.
-130 if the state is -60 looks right o me…
But…
With Tasmota, the state is an RSSI and with yours the state is already dB so why are you converting it?
Next, this author’s code doesn’t work. It provides regularly unfinished business. Or just parts unusable from larger units. This code is an example of this. It only unnecessarily takes up space here and mystifies users looking for solutions.
Sir. When presenting some code, especially a card, next time I would like a comprehensive comprehensive and functional solution not just a malfunctioning torso!
The code works perfectly fine, it just requires a custom card (config-template-card) and the custom card won’t display if entities presented to the card do not exist. Next time, ask a question instead of insulting other users on your first post when you can’t figure something out.
i want the dynamicSignal strength symbol and words (Excellent/Weak/ … ) like in this topic. Iam using ESPHome with ESP8266 and send the RSSI/Wifi Status in dbm to HomeAssistent. So how i can put your Code in my Code?