Hi all. I have seen lots of posts for the old version of this motion detector, however not many posts regarding the newer E1745 Ikea sensor with the fixed 3-minute timeout.
The problem I had was trying to get the motion detector to retrigger when movement was detected, rather than ignoring it. To be blunt, if you were in the bathroom the light regularly went out.
Even if you extended the light to remain on for 10 minutes and you left the bathroom after 8 minutes and someone else entered the room at 9 minutes, it would not extend the bulb to remain on for a further 10 mins, it would actually turn off after 1 minute.
Anyway, with help from @BertrumUK he has managed to resolve my issue and to get it to work exactly how I wanted it to work.
I have an Ikea Bulb and the E1745 senor both connecting to a Zigbee2MQTT device.
The light is set to come on for 7 minutes and retrigger for a further 7 when movement is discovered.
I will share the Node-Red code below so you can import if you wish
=======================================================
[{"id":"fcb1e70c.208e88","type":"server-state-changed","z":"4622b911.dc6908","name":"Bathroom PIR","server":"69b349b6.863ad8","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.0x678ae2fffe3564f7_occupancy","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"on","halt_if_type":"str","halt_if_compare":"is","outputs":2,"output_only_on_state_change":true,"x":90,"y":120,"wires":[["13841e25.d89c82"],[]]},{"id":"69b349b6.863ad8","type":"server","z":"","name":"Home Assistant","addon":true}]