Barometer with rising or falling indication

Hi all,

I have searched for the answer everywhere so you are my last resort.

I have a sensor in my dashboard showing barometric pressure but I’d really like a indication of whether its rising or falling using historical data.

My coding skills are not well enough established to even contemplate this as a project.

Is this even possible and if so how?

Many thanks

Kev

Custom bar card? Search for indicator:

you could try a simple input_text with an automation.
Make the automation trigger on sensor state.
If the value goes up, set your input_text to “Up”, otherwise “Down”
something along the lines

- alias: Set Barometer Direction
  trigger:
    - platform: state
      entity_id: sensor.barometer
  action:
    - service: input_text.set_value
      data_template:
        entity_id: input_text.barometer_direction
        value: '{% if trigger.to_state.state > trigger.from_state.state %}Up{% else %}Down{% endif %}'

Thanks guys. I’ll take a look at both options.

Is it used for weather purpose?
If yes then you probably want a value of the rate it climbs/drops to?

Kevin did you ever figure out best way of doing this? I have same setup and it needs to be rising / falling / steady over small period of time.

This is an old thread so the problem might be solved already, but I wrote a trend sensor appdaemon app a few years ago for the same purpose. It sets the state of a sensor to “on” when a sensor trend is rising and “off” with a falling trend. You can then use up/down arrow icons to indicate the trend in a dashboard.

You can set the sensitivity of the trend sensor by increasing or decreasing the number of samples used. I am using 6 samples for temperature sensors and its completelty stabile.
See the code here: https://pastebin.com/PUHgG93s.

Thank you!