Get binary sensor attribute?

Hi there,

Is there way to pull a binary sensors attribute?

Specifically, I want to grab the “upper” attribute from my binary_sensor.yaml then put that value into a Markdown card in Lovelace.

- platform: threshold 
  entity_id: sensor.days_in_water_veg_patch 
  upper: 3
  name: Threshold water_veg_patch

Cheers,

Steve

Thanks, Tom.

Not getting anything out with either of the following - am I close? :upside_down_face:

{{states.sensor.days_in_water_veg_patch.attributes.upper }}
{{ state_attr('sensor.days_in_water_veg_patch', 'upper') }}
{{ state_attr('binary_sensor.threshold_water_veg_patch', 'upper') }}
1 Like

balls - I should have seen that binary_sensor part!

Thanks lads.