Home assistant sensor device class (See ?, line ?) Here is my Jul 26, 2022 · The duration device class was added in HA 2022. Jun 12, 2023 · Hello HA Community, I have a air quality sensor with different sensors that are defined this way is the Yaml ESPHome: (I can share the complete code if that helps) sensors: - name: "${friendly_name} PM1" id: daikinpm1 unit_of_measurement: "μg/m³" accuracy_decimals: 0 device_class: pm1 - name: "${friendly_name} PM2. But this device class also supports other UoMs like "mV (0. home-assistant#1106; Add running device class to binary sensor home-assistant. They work on the Zigbee protocol and connect to zigbee2mqtt which pushes to MQTT their “declaration” for autodiscovery their status (temperature or humidity) It happens sometimes, though, that the devices simply vanish from HA, which states that they are unknown (in yellow in the UI). And my door and window sensors all have square icons that are either filled or unfilled depending on sensor state. This is the configuration: template: - sensor: - name: gas_meter state: "{{ (states ('counter. I tried with “alias” in customize but no effect. BATTERY. High speed “sent” Low speed “sent” Feb 12, 2023 · Hi all, I created a sensor for my gas meter that shows up in the energy dashboard correctly. Home Assistant Customizing entities. Can I get Oct 30, 2019 · Hi All, i have an issue with a sensor configured, when the state changed from off to on, the color of the entity is not changing to yellow, it’s remain the same. This makes it sound like the ESPHome device_class list is unified with HA’s. 6. The mapping tables seems to indicate that sensor with co2 and pm25 in name or as device_type are automatically mapped based on their namer or type being pm25 or co2. I have now borrowed the power_factor device class and that works but my question is Feb 18, 2023 · The implication from the link you posted is that z2m cannot set the alarm state, which is why it is configured as a binary sensor rather than a switch. attributes. So this is maybe a bug. However from the documentation an several examples this should be possible. zigbee2mqtt is still sending information to the MQTT Jan 10, 2024 · Hi there, I am trying to change a binary_sensor to a motion sensor. io. The name of this entity will be My device temperature. bulb_energy_meter_gas_meter Last Jan 10, 2020 · Take a look at the docs here, there’s also an explanation on how to change the device class. Would be really usefull. k_garage')}} should respect the device class and return Open/Closed, but instead I get On/Off. io The screenshot shows a few examples of different device classes for binary sensors: Example of various device classes icons in on and off state. 05. Thanks a lot Stefano May 6, 2024 · Below is a screen shot showing the start of the sensor section with the single switch entry above. Nov 5, 2023 · I have time-based electrical tariffs and I created a simple automation in node-red using a cron which updates a sensor with the price: Adding devices via the energy integration using the price sensor seems to give the right kind of result that I am looking for: That works well enough for an overview, but I have energy metering on pretty much all the devices in my house, so I would also like to Oct 10, 2022 · I have a modbus integration supporting the SDM630 energymeter. ) I then used a helper Utility Meter to create the following: I have tried to add the utility meter to the energy dashboard, but the helper is not May 6, 2024 · Below is a screen shot showing the start of the sensor section with the single switch entry above. The following device classes are supported for sensors: None: Generic sensor. While there already is a pressure device class, the unit for atmospheric pressure is in many cases different. gas_meter_counter. Apr 27, 2023 · as_timestamp() existed before the concept of a timestamp device_class was introduced. Aug 2, 2019 · Hi all, Hoping someone can assist, as i am stumped. sensor. server_temp: device_class: measurement Reloading the core should be all that is required but it wont update the sensor customization until the sensor state updates. This is the entirety of my configuration. This can be useful for date and time calculations. In /config/configuration. Anyway, it appears that a Binary Sensor Group Helper sets its device class based Jan 13, 2022 · I have an Everspring ST812 moisture sensor that doesn’t come in with a device type (so just on/off). Feb 6, 2023 · We already have a lot of different device classes for the different types of sensors. yaml : template: &hellip;. Thanks, had it in the wrong file Nov 10, 2019 · Giving an device_class to a input_boolean. server_power_consumption - > add device_class: energy to the yaml Dec 17, 2022 · Hi, I’m trying to add a smart plug with energy meter function to my energy dashboard as an “individual device”. 2 & 12. 3 of these are calculations from other sensors as you can see in my yaml. yaml - platform: template sensors: sensor_40: friendly_name: 'Hp Printer' value_template: "{% if is_state('device_tracker. ) can keep track of costs in some way. config file how do I make my sensors into energy sensors ? I think they need to have device_class: energy and state_class: measurement I am new to HA and would appreciate any help Dec 10, 2020 · I’ve recently installed Home Assistant and have integrated deCONZ with various devices. Through this, it will establish a connection between Home Assistant and your KNX bus. I can achieve what I want to do in node red, but getting everything working after that is too much trouble, and I already have an automation working perfectly, just Dec 14, 2021 · @DrCoolzic "apparent power" and "reactive power" is not the same thing as "power", and we can't convert between them. If I understand it correctly, the icon will automatically be changed if I define the door and window sensors as door and window device classes. This example is determining if anyone is home based on the combination of device tracking and motion sensors. Consequences. Implementation reference: Add tamper device class for binary sensor core#57632; Add tamper device class for binary sensor frontend#10268; Add tamper device class for binary sensor developers. They are all temperature sensors and been given the device class of temperature. So if an input_boolean had a device_class, how would that Mar 23, 2022 · Hi @zuz242,. Obviously, I had Sep 11, 2021 · Customize is the way to do it. Powered by a worldwide community of tinkerers and DIY enthusiasts. This is the default and doesn’t need to be set. I use an OWL cm180i meter with 3 clamps. Since I want to track its power usage, I created a helper using the “Integration - Riemann sum integral sensor”, as described here. is only the state shown in the frontend, the “real” state will always be “on” and “off”, this is important when you do automations for example. template->sensors->battery_front_door_sensor->device_class. The last_reset was necessary for the Energy tab to accept the Slimmelezer as a source for energy consumption. However, the device ends up returning none for name Sep 18, 2024 · When creating a template sensor, there is no device class for entities that track cost / money / price. But there is no device class for “volumes”. With this integration I can readout every register in the SDM630. The options property must be set to a list of possible states when using this device class. 01) | round(2) }}" unit_of_measurement: "m³" device_class: gas state_class: total_increasing Can I give it a display name? Regards, Jan Feb 16, 2023 · I’d like to create a rest sensor for json values such as {“timestamp”:1676502393000,“power”:153}. While power is measured in watts, if there’s a phase difference between voltage and current, which causes a power factor less than 1, then you need a way to indicate the difference between real power and reactive power. A search in Documentation - Home Assistant for “device_class” responded with every possible hit for “device” and “class”, but none for “device_class”. But this brings me to the next: I also wanted to change the device_class for a sensor, but the Aug 20, 2021 · Hi, I have a zigbee powermeter which doesn’t count correctly (wrong pulse config), so I thought creating a “virtual” sensor with the right counting. I can set the device_class: moisture in the Dev Tools for the binary sensor and for awhile it reflects correctly. g 3 days 12 Hours 20 mins and 12 secs, instead of current template, which mention largest unit only. What was the last working version of Home Assistant Core? 2023. template: - Invalid config for [sensor. The documentation says that I can use device_class: enum to do this, using options to define the possible states: SensorDeviceClass. Device classes are a way to give context to an entity. This would enable the new statistics graph for these types of sensors. In my case, I want to report intervals such as uptime etc. But when I add this new entity to the energy dashboard, it says it doesn’t have the correct “device class”. home-assistant Aug 5, 2021 · Hi @Mariusthvdb,. 3. Mon May 14 2018 15:21:44 GMT+0100 (GMT Daylight Time) Invalid config for [sensor. home-assistant. 4. Available for free at home-assistant. It could be great for many things with a float switch Such as a rain barrel, overflow tank, Aquarium, a fuel tank, water tank. 1 and am getting this now as well. lumi_lumi_sensor_magnet_aq2_ce212304_on_off', 'off') }} Trouble is the domain appears as ‘binary_sensor’ I need it show as lock. yaml as such: sensor: - platform: template sensors: gas_meter_counter_m3: value_template: "{{ ((states. alias_on: ‘Running’ alias_off: ‘Stopped’ Jun 19, 2019 · doh! I knew I was missing something. loft_sensor_window_ias_zone: device_class: window The same page (and various forum posts) mention that the ‘customize’ needs to be in the ‘homeassistant:’ section as: homeassistant: name: Home unit_system: metric # etc customize: Oct 21, 2022 · From your screenshots it looks like your sensor has a device_class of ‘energy’ and the integral helper a device class of ‘total’. Dec 12, 2021 · Now that Hass 2021. server_power_consumption - > add device_class: energy to the yaml Sep 18, 2024 · When creating a template sensor, there is no device class for entities that track cost / money / price. See Sensor - Home Assistant for a list of available options. I was very excited to see we can now also use gas meters. To change entity attributes, follow these steps: Go to Settings > Devices & services > Entities and select the entity from the list. This is the code under sensor: in configuration. As can be seen in the image below, I am receiving a temp value from the sensor and a ‘normal’ value from the device_class: heat. Earlier the icon depended on state, now it is always same: Code: sensor: - platform: template sensors: test_battery_level: unit_of_measure&hellip; Apr 25, 2021 · Sensors with timestamp device class: a sensor that has a timestamp. Temperature conversion for entities without correct device_class is deprecated and will be removed from Home Assistant Core 2022. I feel like {{states('binary_sensor. I have a Sonoff sv configured with esphome yaml and a ds18b20 temperature sensor. Sep 6, 2021 · The ESPHome docs Sensor Component — ESPHome say: device_class (Optional, string): The device class for the sensor. I’m also able to trigger the relay on the sv board as a dry circuit contact, which toggles the power on my gas fireplace. I used the Riemann Sum helper to convert this to energy used (kWh). Jun 8, 2021 · I would like a device class for sensors that are measuring volume and flow. Thanks They will automatically appear in the Home Assistant front-end and have several configuration options. My problem is to be able to track energy in the new energy dashboard of HA, my sensor needs to have a measurement class definition, which I can’t set. What type of installation are you running? Home Assistant OS. But I post here too if one or you having a smart work around to answer to my need. I was told that this should automatically assign the device a name based on the device_class. These are used by Home Assistant for various purposes like: Allowing the user to switch to another unit of measurement than what the device provides. template]. To be the most flexible, I really want to NOT creating a Dec 2, 2022 · I have many sensors from my solar systems and emporia energy monitors that work on my own dashboards but not on the main HA energy dashboard. well, in my case, I only have two of those devices. And when I delete device_class with the “x”, it is set to “none” but I can not save it. Jan 16, 2022 · Assume a sensor is created by some integration with some device_class (let it be “voltage”). yaml file sensor. By default UoM=“V”. Aug 25, 2023 · In that case you can use customise to add the attributes you need: homeassistant: customize: sensor. So it would come in as a “On/Off” sensor or 22/23 sensor, but then being able to select that and change type to “Window/Door” etc. Maybe the customization panel wasn’t the best tool possible, but now there State based binary sensor - Is Anyone Home . If you like yaml The configuration. Mar 25, 2023 · Hi! New to the forum and HA overall. Mar 9, 2023 · I’m trying to set up a sensor with a couple of strings as available states. the angle (in degrees) between voltage and current. home-assistant#1084; Add tamper Mar 10, 2022 · I have an automation that is triggered by doors opening/closing. ENUM: The sensor has a limited set of (non-numeric) states. We current Nov 9, 2020 · As it is not possible to edit the documents to update the out of date screenshot showing the current binary sensor device classes I’ll put the update here instead: Home Assistant Community Binary Sensor Device Classes Aug 29, 2020 · HI, thanks for your reaction. gascounter') | float * 0. My sensor section has four temperature sensors and the configuration is shown below: Notes: Many of the settings for the fours sensors are the same. (A problem with the search feature?) So, a bit more digging and I found such a list. The smart plug entity has a “power (W)” sensor. I have a few entities in which I track the price of things that fluctuate (ex. SQUARE_METERS. Mar 4, 2023 · Hi, I’m trying to offset by 6°C one of my temperature sensors so I added the following to configuration. Not yet. Sep 6, 2019 · Hi. Pressure or temperature expressed in different units are all measuring the same physical quantity, with units other than SI units used in some regions or for certain applications - that's the internationalization Martin is referring to. Now, if you don’t want to touch yaml, you’re stuck with the white square icons. Now i read the themes website section called The color rules can be customized using theme variables and also made note of Note that the variables will be used in the listed order, so if multiple match your entity, the first matching variable (= most specific one) will be used. I want to change it so that I don’t have to edit the trigger every time I add a new door sensor and instead have it trigger by all doors without specification. CommandSensor’>) with device_class None reports a temperature in °C which will be converted to °F. Perfect to run on a Raspberry Pi or a local server. Anyway - we don’t have Jun 6, 2019 · Is it still not possible to change the on/off text for a binary sensor? I have a washing machine and want the text “running/stopped” instead of on/off. e make it human readable, e. Check: sensor. This is easier (binary_sensor, in this example). It’s extremely useful if you have kids/baby sitter/grand parents who might still be in your house that aren’t represented by a trackable device in Home Assistant. No device class seems to fit this need. The on image in this example has state_color: true specified in the entities card configuration to receive the icon coloring. I’ve been experimenting with it to replace older sensors where I’ve been parsing the datetime to e. sensor: - platform: template sensors: util_meter: state_class: "measurement" friendly Jul 13, 2020 · Need help with 3 things: What device class to use to represent money? Is it a valid unit_of_measurement “$”? How can I make lovelace represent dollars on the left hand side? Apr 9, 2022 · Good Morning All, Long time lurker, first time poster! I appear to have an issue with my Bulb energy meter not pushing the Gas usage through to my HA platform. Another method would be to customize the entity. c4_65_16_69_73_c0', 'home') %}on{% else %}off{% endif %}" i Sep 8, 2022 · I want to set device_class: door in mqtt / binary_sensor but it doesn’t recognize device_class and I don’t have the door icon: My connfig: mqtt: binary_sensor: - unique_id: toilet_door friendly_name: &quot;Toilet do&hellip; Sep 2, 2021 · All, Previous release ( 2021. (I have used the MQTT auto discovery to include the sensor data into home assistant. 000915751 precision: 1 unit_of_measurement: V #customize. Custom integrations should be adjusted to use UnitOfArea. Dec 7, 2022 · Add an atmospheric_pressure sensor device_class to home assistant core and frontend (+ documentation). This sensor is using the rpi_gpio platform and so I cannot use device_class. For example, if device_class is door, its icon will be a door and the displayed text will be open or closed (instead of on/off). Jan 19, 2022 · So, I wondered what else I could modify with device_class. name: Water Sensor id: water_sensor device_class: moisture I had been looking for a way to integrate this moisture sensor into HA for awhile and didn't really turn up much. I have a sensor with a timestamp that I wanted to use as a condition. , m³, ft³, or CCF. Jun 7, 2023 · If I create a template sensor to represent a battery give it the device class of battery then it automatically gets the right icon to represent the charge level. What type of installation are you running? Home Assistant Container Apr 9, 2021 · Here is my nodered flow - the “external wind direction” is updated every second - if i take this sensor and add it to lovelace, the value changes from 0-359 every second, pending where the wind is. The /config/sensor. The automation is for a family member who doesn’t have admin so I want to use an input helper to allow the sensor value to be defined from Jan 10, 2019 · Ok Thanks a lot, so why is the HomeKit page talking about pm25 and co2. The SensorEntityDescription instance defines the device_class as SensorDeviceClass. May 13, 2023 · Hi, I want to output a date in a template but always get rendered invalid date. yaml: # Configure a default setup of Home Assistant (frontend, api, etc) default_config: # Text to speech tts: - platform: google_translate group: !include groups. When I first paired it the other day I did set up a mdi Sep 3, 2019 · Since a group’s state is a binary sensor type display it would be nice to add some type of group config options like device-class to be able to change the group state display. 3 days 12:20:12. yaml file is the main configuration file for Mar 22, 2022 · customize: binary_sensor. I want to show my solar panel production in the energy tab. Base Binary Sensor Configuration¶ All binary sensors have a platform and an optional device class. Because of these reasons, it is important to use device classes where possible. device_class: There are multiple possibilities for a device class. does anyone have an idea how I can get this done Apr 14, 2022 · Could a custom device class option be implemented that would be defined something like this: device_class: - binary_sensor: - <device_class_name>: state_off: <off state word> state_on: <on state word> icon_off: <mdi icon for off state> icon_on: <mdi icon for on state> All optio… May 21, 2023 · Hi dear community, I have implemented the AI-on-the-Edge-Project. I tried to build this string manually: Oct 13, 2021 · Add new device class DEVICE_CLASS_TAMPER to binary sensor platform, to indicate a device has been tampered with, is detecting tampering, or has detected tampering. In this case the value is a spot price not a totalization of some cost (like the total of my electric bill) I couldn’t find a discussion anywhere on why Monetary isn’t allowed as a measurement but I’m very curious Jul 4, 2019 · Agree. The KNX integration for Home Assistant allows you to connect to KNX/IP devices. Checking the docs, your sensor should have a device class of ‘power’ (unit is W) which if used for the integral helper will creat an entity with device class ‘energy’ (unit is kWh). oz. How must I output my date (in this moment as string like ‘13. I want to replace a entity I have created as a Template Sensor. It is now easy with the min/max helper to sum-up values (3 phases via Shelly 3EM for example) but this value can’t be used in the energy dashboard. Oct 6, 2024 · If a template sensor was previously declared with some state_class, then LTS is generated and stored in DB. May 18, 2018 · Whenever I add “device_class” as per my below example and the link above my config validation fails with a message that says. 12. This is to be used for representing a water meter, with the correct units of measurement. The are running with deep sleep mode, which is managed by an automation. Example implementation In the example below we have a temperature sensor that uses the device class temperature. Backward compatibility The AREA_SQUARE_METERS constant has been deprecated and will be removed in Home Assistant 2025. Need : With the minimum configuration, I’d like to trigger my automation smarter than listing all my entities in my automation or creating a manual group for them. ft/s; km/h; kn; mph; m/s; This sensor device class would be useful for most integrations providing weather data sensors. counter. What device class is listed for your helper? If you need to you can change it with Customize. Home Assistant Sensor. via MQTT. There is also a way to add more device_class? like add gate class with different icon. yaml # # This base class shows the common properties and methods for a sensor as used in this # example. Set to "" to remove the default device class of a sensor. yaml mqtt: sensor: - state_topic: "mower/status" name: "Mower status" state_class: measurement unique_id: "mower_status" device_class: enum This allows me to display status on dashboard, but when I open the entity there is no history. below is an example. tasmota_sm_1_8_0: device_class: energy state_class: total_increasing unit_of_measurement: Wh # Loads default set of integrations. There is a PR for adding force and mass that is closed - I would like to get distance (in meters) and I guess there are some other - frequency (Hz) and maybe sound pressure level (SPL), PM2. In this case, I’m using the sun2 integration to get the duration of daylight. Simple customization for entities. Jan 13, 2022 · I have an Everspring ST812 moisture sensor that doesn’t come in with a device type (so just on/off). I followed this guide. The visual icons in the front end would be the same as the problem device class. 8) I struggled a bit getting my energy meters on the new dashboard, but the new state_class: 'total_increasing' solved my issues without requiring any workarounds. I can make a sensor for this register but in sensor there is no device class Phase Angle. 12 removed the customization panel (why??? This UI update is really crappy IMHO), how can it be done to change a binary_sensor device_class ? I’ve used the customization panel to change e. You’re probably looking for volume_storage: Generic stored volume in L, mL, gal, fl. I tried to use the lock template but can’t get it to validate as there is May 12, 2023 · I am sending via mqtt topic different status of device in string form, e. The problem I have is that I’m Dec 18, 2021 · Rather than maintaining an ever growing list of binary type device classes to support things like people having windows that open horizontally or gates or mailboxes, etc… Could a custom device class option be implemented that would be defined something like this: device_class: - binary_sensor: - <device_class_name>: state_off: <off state word> state_on: <on state word> icon_off: <mdi icon Home Assistant is open source home automation that puts local control and privacy first. It generates a UNIX timestamp (number of seconds since the Unix epoch). What was the last working version of Home Assistant Core? core-2024. Does anyone know what I am doing wrong? The original sensor configuration looks as follows: - platform: mqtt name: Soladin Total_Power unit_of_measurement: "kWh" state_topic Dec 14, 2021 · @DrCoolzic "apparent power" and "reactive power" is not the same thing as "power", and we can't convert between them. Feb 8, 2021 · These sections tell Home Assistant what text the device will send to indicate its current state. When this template becomes without a state_class, a corresponding statistics issue appeared in Dev tools - Statistics. yaml automation: !include automations. Great! I notice battery sensors provided by integrations do the same thing but have different icons depending on whether they’re charging (and my phone even gets different icons when wireless charging!) which is very neat. # This base class shows the common properties and methods for a sensor as used in this # example. Proposal Add a device class DEVICE_CLASS_MONETARY, for measuring an amount of money/currency. This could be emulated via a binary available / unavailable sensor, however I then can’t distinguish a device restart from a MQTT Jan 22, 2018 · just upgraded to 0. What version of Home Assistant Core has the issue? core-2024. 06. I came across several solutions for instance: a blueprint https://community. 7. There is currently support for the following device types within Home Assistant: Binary sensor; Button; Climate; Cover May 10, 2023 · After trying a home waterproofed Miflora, then some Zigbee moisture sensors given the same treatment, I now use one of these: Soil Moisture Sensor - VH400 Good topic on reliable ESP32 boards: ESPHome sensor calibration: sensor: - platform: adc pin: GPIO36 name: "Lawn Moisture Raw Voltage" id: raw_v unit_of_measurement: "V" device_class: voltage attenuation: 11db update_interval: 10s - platform Jul 9, 2020 · dear people I recently added an anemometer to my hassio sensors. I think it would make sense to add this as many devices (like energy meters, water meters, etc. 01) | round(2) }}" unit_of_measurement: "m³" device_class: gas state_class: total_increasing Can I give it a display name? Regards, Jan Mar 10, 2022 · I have an automation that is triggered by doors opening/closing. For example, the entity ID here could be shortened to binary_sensor. Once I entered the below code in the my configuration yaml, I used “binary_sensor. 001x). Integration causing the issue. , running, stopped, stuck, etc. 5/10? What is the plan for this? Is there a plan for adding more sensor classes? I would not want to spend time doing a PR if Jul 4, 2022 · Hello there, I already post a similar message to create a feature about that on this post. However, one might be interested in also displaying an elapsed period of time. I use the Riemann integration to transform Power in Energy. Several months back, in an attempt to create a 24 hour rain tally, from a weather integration hourly rain sensor, I created a Utility Meter sensor as follows: sensor. energy_spent. Now it indicates the degrees of the direction the wind is coming from. The question is 'how to set the device_class: energy to the energy sensor provided by the Riemann integration a) device_class: energy in the Riemann Oct 11, 2021 · We can also have Volt Ampère Reactive as power unit. g for windows and doors. See each sensor for further details about properties and methods that Oct 19, 2021 · Since 2020. Another device class? 🤷. motion_group” as a trigger for my automation using the automation UI (Note, “Garage Group Motion” is the friendly name that pops up when searching the Entity for the trigger but once I click on it, the name defaults to “binary Nov 7, 2024 · im trying to set specific binary sensor device class for certain colours. integral Mar 29, 2021 · Hey guys, Iam trying to create a status page where I can see with one quick glance the status of my devices. What did you set the device class to? Should be: sensor. Added the integration with these settings: And I can view the kwH as I want to if I view the sensor Oct 6, 2022 · Proposal. Apr 30, 2023 · I know, but this worked for over 2 years… I use it as a sensor to show the last sent state variable. Gas usage tracking (statistics just like the tracking of your energy) Water usage tracking unit_of_measurement should be m³. 4 respectively. … Jan 7, 2023 · A warning might be more useful, it seems unnecessary for a RESTful sensor to fail when a mismatched device class and unit of measure are used. So there are “Signal Strength”, “Voltage”, “Current” - and many many others. Instead of just showing on or off if I have a group of window sensors it could say “Closed” or “Open” this video might help illustrate it better. iam struggling with the count of devices (per device_class, motion, temperature, window, door) which have a low battery. Feb 12, 2023 · Hi all, I created a sensor for my gas meter that shows up in the energy dashboard correctly. Aug 6, 2021 · Hello For the new energy integration available in 2021. See each sensor for further details about properties and methods that May 6, 2020 · Definitely see your points. Jun 29, 2020 · {% set windows %}{% for sensor in states. The device is documented to only update the value every 5 minutes so when HA will query the value it will likely corresp&hellip; Oct 13, 2021 · The visual icons in the front end would be the same as the problem device class. apparent_power: Apparent power in VA. Jul 23, 2021 · Today there is a quite uncomplete list of device classes available for sensors. What version of Home Assistant Core has the issue? 2023. Why? Binary_sensors support device_class and it influences their appearance (icon and text) in the Lovelace UI. command_line. I dont have to know which devices have a low battery level, just how many. display an HH:MM duration string. yaml file Aug 6, 2022 · What I was thinking/assuming changing device_class: duration will add units of time to the sensor, I. Sep 10, 2020 · I’ve converted a binary sensor to a lock using this binary sensor template back_door_lock: friendly_name: "Back Door" device_class: lock value_template: >- {{ is_state('binary_sensor. yaml scene: !include scenes. I used it and entered a third motion sensor. cpu_temperature (<class ‘homeassistant. A restart will update the sensor as soon as home assistant restarts. Correct icon and wet/dry. I can select a lot of typs inside the “show as” dropdown but not “none”. For Binary_Sensors, we do have device classes like “Smoke”, “Window”, “Door” - to tweak the behave of the binary sensors in different ways - depending on the specific device class. Is it implemented just for Jan 5, 2024 · I’ve added a sensor into my configuration. yaml. See the documentation, source code, and examples from the community discussion. - platform: template sensors: daylight_hm Apr 29, 2020 · I’ve created the two garage door sensors as shown below and they show Open/Closed in the UI, but On/Off in the states. g. Got some sensor readings from a couple of batteries and I defined them as follow: # sensor. Not LP. Oct 23, 2023 · In the documentation of the device_clases (Sensor - Home Assistant) find following: date: Date string (ISO 8601) timestamp: Datetime object or timestamp string (ISO 8601) If I understand it correctly, device_class date requires a ISO formattet string: 2023-07-30T20:03:49. BinarySensorDeviceClass. The integration requires a local KNX/IP interface or router. See full list on developers. If the float filter cant find anything it can convert to a number in this case it is replaced with 0, you can use other options. 5" id: daikinpm25 unit_of_measurement: "μg/m³" accuracy_decimals: 0 device Sep 30, 2022 · Rather than maintaining an ever growing list of binary sensor device classes to support things like people having windows that open horizontally or gates or mailboxes, etc… WTH not implement support for custom device classes that could possibly be defined like this: device_class: - <domain> - <class> state_on: <on state word> state_off: <off state word> icon_on: <mdi icon for on state> icon The KNX integration for Home Assistant allows you to connect to KNX/IP devices. Refer to the Home Assistant documentation for more information and a description of each type available. wago_dc1: friendly_name: Batteri 1 device_class: battery Shows up fine i UI, but since the battery is 12V is shows up with the “almost Aug 12, 2021 · There are device classes for energy, voltage, etc. 2 using the HassOS image running in a Proxmox VM on a stand-alone x86-64 based machine. py Jun 8, 2020 · Hi, the device classes of the sensor platform currently only support a timestamp (i. , a concrete time instant). binary_sensor %}{% if sensor. Add a sensor device_class wind_speed for wind speed to home assistant core and frontend (+ documentation) with supported units:. The project provides a MQTT-based sensor, which provides the current value of my water meter. tasmota_sm_16_7_0: device_class: measurement state_class: power unit_of_measurement: W sensor. They are “custom made sensors, battery powered”. game_sensor_window_ias_zone: device_class: window binary_sensor. I’m doing this because I believe that, as features become availaible through the UI, I should dispense with the hand-coded equivelents in my configuration. state == 'on' %}X{% endif %}{% endfor %}{% endset %}{{ windows | length }} I actually put it all on one line in the config, but spread it out here to make it easier to read - though I can’t put any space outside of template Sep 3, 2018 · Thank you for your suggestion. Please be informed that the state the device is showing like “open”, “closed”, etc. Example of various device class icons for sensors. Home Assistant Community Jun 29, 2020 · Many of us are monitoring battery-operated devices via sensors, so may I suggest adding the following two new sensor device classes: voltage, suggested units (default first): ‘V’, ‘mV’ current, suggested units (default first): ‘A’, ‘mA’, ‘µA’ (if need arises, this could also be named ‘amperage’) Hint: If you like this idea, please vote for it (top left). device_class == 'window' and sensor. Oct 30, 2023 · For some reason my battery sensor is setup with name “none” instead of “battery”, like “tablet_none” instead of “tablet_battery”. Jun 24, 2023 · A Binary Sensor device class that indicated Full or Empty would be great. The time condition only has the first 2 and can not make the use of sensors that have timestamp device class. In the top right corner, select the cog icon. but now HA does not offer my gas meter as an option in the dashboard, the sensor looks like this: - platform: mqtt name: "Gas consumed" state Quite by accident, I found a way to add a sensor to detect moisture. High speed “sent” Low speed “sent” Apr 19, 2023 · Pretty much what the title says. I wanted to know if there is some method to query the state in the context of the device class. living_room_motion_1. Mar 28, 2022 · Yes. 10 my battery level sensors have static icon. you can select a different device class. aqi: Air Quality Index (unitless). xxx. I have tried quite a few times. May 4, 2020 · Hello to everyone, i need some help if is possible… i want to change the icon of the device_class window with this icon window-closed-variant how can i do? i have many sensors so for me is more seimple to change the class instead of the icon (with on and off change) of all sensors. Apr 17, 2022 · I’ve been playing with the Binary Sensor Group Helper that became available in 2022. The Context Some integrations display monetary values, it would be nice to display those better. components. sensor &hellip; Jun 24, 2023 · A Binary Sensor device class that indicated Full or Empty would be great. Overall I think it wold be useful for many things. I’m using indeed sensor. mqtt]: value is not allowed for dictionary value @ data[‘device_class’]. A sensor whose device_class is timestamp requires the sensor’s state to be presented as a timestamp in ISO 8601 format. I can achieve what I want to do in node red, but getting everything working after that is too much trouble, and I already have an automation working perfectly, just Jun 9, 2023 · I’d like to have a defined device class in hue zigbee connectivity sensors: device_class: connectivity state_class: measurement This template would then list not connected devices: {{ states. 69. Earlier the icon depended on state, now it is always same: Code: sensor: - platform: template sensors: test_battery_level: unit_of_measure&hellip; Jan 7, 2023 · A warning might be more useful, it seems unnecessary for a RESTful sensor to fail when a mismatched device class and unit of measure are used. I can see there is a deprecated monetary sensor device class, but for templating I think it would still make sense to add a class for providing a cost or Feb 13, 2024 · I used the hp_ilo integration to get the current power reading of my server. E. The below may seem the The use of this device class should be avoided, please consider using the update entity instead. What type of installation are you running? Home Assistant Container Sep 25, 2021 · I am trying to add the “state_class” property to an existing MQTT sensor but got the message “Property state_class is not allowed”. state | float) / 100) }}" unit_of_measurement: "m³" device_class: "gas" but as soon as I add state_class: "total_increasing" beneath the device_class line, the sensor disappears from Home Assistant (doesn’t show up in Oct 19, 2021 · Since 2020. 1. daylight sensor as provided by sun2. I created a new sensor with the Riemann sum integral GUI under Settings > Devices & services > Helper Tab > + Create Helper > Integration - Riemann sum integral sensor. and specify and open closed value. 08, i need to define an energy sensor. Jan 2, 2024 · Hi, I have a problem to set a binary_sensor to device_class “none” via GUI (see screenshot). There is currently support for the following device types within Home Assistant: Binary sensor; Button; Climate; Cover While I freely admit I must be doing something wrong, this setup is working just dandy. daily_rain: device_class: precipitation Oct 21, 2021 · Add running device class to binary sensor core#58423; Add running device class to binary sensor frontend#10400; Add running device class to binary sensor developers. sensor. Jan 1, 2023 · I find it hard to find the helper configuration in the yaml files to check or modify the device class. Jul 12, 2024 · I am currently running Core 2024. I wanted this automation to only run after a timestamp that changes every day. Electricity Price in Texas which can change quickly). If I add the helper to my energy dashboard I get get following message: If I go to Dev Tools → States → sensor. After an unknown period of time or an unknown action it’s back to not having a device_class. io#19963 Dec 26, 2024 · A corresponding UnitOfArea unit enumerator, and AreaConverter converter class have been added to support the new device class. e. Look in Developer Tools → States. At the moment the state template is evaluated but the availability template replaces the state with unknown if the availability is false. 23’) to match the device_class date and the expected date object? Thanks, Steffen Mar 19, 2022 · Hey gang, Coding noob question that’s hopefully easy for someone not as inept with coding as me lol… Long story short - I’m using a blueprint in an automation, and for whatever reason the blueprint author defined it to trigger by timestamp sensor. Each clamp gives me a ‘Power’ information. 2. Well, five lists. Instructions on how to setup your sensors with Home Assistant. I know how to add/modify the class in yaml Jun 14, 2024 · Unexpected device class The following entities do not have the expected device class: sensor. Mar 7, 2019 · I have a few Xiaomi temperature/humidity sensors. When I first paired it the other day I did set up a mdi Nov 15, 2021 · Entity sensor. I read up on using Template States to change it, would anyone be able to walk me though on how to do this, I can see I can use the Template Helper but not sure what content to put in. Jun 14, 2019 · Learn how to find and use device classes for sensors in Home Assistant, such as timestamp, binary, cover, and more. yaml file - platform: modbus registers: - name: Wago_DC1 slave: 1 register: 0 scale: . I actually that he also indicates the direction. One of the registers is the phase angle. 5. VIBRATION On means vibration detected, Off means no vibration. By default, the binary will chose the appropriate device class itself, but you can always override it. 253717+00:00. At first I thought that this may be due to a Smart Things issue, but after investigation I get this error: Unexpected device class The following entities do not have the expected device class: sensor. Reason for setting a device_class for rain is the same for other weather conditions like temperature, moisture, etc. template]: [device_class] is an invalid option for [sensor. Supervisor and HAOS versions are 2024. Dec 16, 2024 · That device class ‘gas’ is for something in a gaseous state like natural gas in a pipe. yaml script: !include scripts. This is my old template sensor using the sensor. north, east etc. ljfbwal cvuq ubuis trwfji hqnui fnjjpe drt hur ptcmtkgc fxakgk