More sensor device classes (meter, Hz, SPL)

Today there is a quite uncomplete list of device classes available for sensors. 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.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 there is no interest.

Some more suggestions …

Sensors:

  • Flow - m3/h, USGPM etc.
  • Level - %, m, mm, ft etc.
  • Speed - m/s, MPH etc.

Binary Sensors:

  • CO - CO detected/no CO detected
  • Low Flow - low flow detected/no low flow detected
  • High Flow - high flow detected/no high flow detected
  • Low Level - low level detected/no low level detected
  • High Level - high level detected/no high level detected
  • Low Pressure - low pressure detected/no low pressure detected
  • High Pressure - high pressure detected/no high pressure detected
1 Like

Direction or Bearing also (non-binary of course!)

Came here looking for just this. Another vote for particulate matter.

1 Like

Here are some more:

  • pulses
  • monetary
  • rain_amount
  • wind_speed
  • speed
  • time_delta / time_period
  • ppm
  • power_density
  • angle / rotation_angle
  • color_temperature
  • brightness
  • length
  • area
  • acceleration
  • capacitance
  • density
  • force
  • frequency
  • impedance
  • mass
  • resistance
  • volume / sound_intensity
  • temperature_difference (K)
  • volume (m³ / l)
  • work (J)

There is currently a discussion and PR about adding binary_sensor device classes:

And discussions about some of the mentioned:

1 Like

Ok, so there are at least some interest - I will look into reviving the PR that intended to add a few and add some more to that one then (and hope it gets in this time)!

Best regards,
/Joakim

The description of the last_reset properties of a sensor which is needed for longterm statistics talks about gas and water meter Sensor Entity | Home Assistant Developer Docs. However the device_class , which is also required for longterm statistics, for volume is not available.

In my opinion a volume device class is very common and should be suported, especially in the light of the new energy management development

There will be a gas device_class.

1 Like

Now I did a PR for some of the sensor classes: Additional sensors update by joakimeriksson · Pull Request #54605 · home-assistant/core · GitHub

Not sure that all features are there yet.

1 Like

I’ll add my suggestion here:

Add “level” device class for binary sensor.

For binary_sensors “level” would be “rising” if “on”, “lowering” if “off”

For sensors “level” would be in “in” or “cm”.

My use case is I track the temperature trend of my fish tank with a trend binary sensor. If I use a device_class of “heat” or “cold” it shows as “Hot” or “Cold”.

It would be nice to see “Rising” or “Falling”.

I’ll chime in as well with a request for weight (assuming it’s not covered by “mass” above)

2 Likes

Hello,
To follow wave tide, a device_class with meter will be usefull.
Can we add a generic class ?

Sorry I’ve created the topic https://community.home-assistant.io/t/long-term-statistic-for-not-listed-device-class-e-g-distance-with-meter-measurement/330533

Bandwidth (Mbps) hasn’t been mentioned jet.

There is not enough device class for the Geiger counter (µSv/h).

3 Likes

I’m confused. It’s 2022 and we still don’t have device classes for mass, force etc.? The set of documented device classes is woeful: Sensor Entity | Home Assistant Developer Docs

Is there a way users can extend the set of device classes themselves?

3 Likes

I would also like to see some more device classes, it shouldn’t be too hard to add them. Especially one for distance (m).

I need one for pH as well.

2 Likes