Node Red AND condition with device state?

Hello together,

i started playing around with Home Assistent node red. I want now to migrate a view automations to node red but i get stuck.

I want to do something like that:

Motion triggerd --> Are shutter_1 > 10 and shutter_2 > 10 and shutter_3 > 10 than light on.

I found that i can use the node red and node, but i get totally stuck with that because i have no idea how to configure it.

I dont´t know how to use the data attributes to compare.

i am grateful for every hind :slight_smile:

Regards Stefan

The AND node looks at msg.topic and compares the values you specify. So you feed each get state node or get entities (it’s cleaner looking this way) into the AND node. Once all the nodes are fed into the node, you tell it which topics you want to match. This is typically the devices full name. Like binary_sensor.front_window. Just feed the values and comparison you want.

used in this flow:

And this is an older version of that same flow:

Hello,

thank you very much vor the help. Now i could fix it. My problem was, that i only saw the cloesed state at the AND Gate. Now i added it like this and it works.