NMAP tracker detects devices, but they transition to away after 3 min

I’m using the nmap device tracker with this config:

  - platform: nmap_tracker                                      
    hosts: 192.168.1.0/24                   
    interval_seconds: 300
    home_interval: 900
    scan_options: " --privileged -sn --host-timeout 5s "        
    track_new_devices: yes

I’ve also run this command to enable privileged mode:

sudo setcap cap_net_raw,cap_net_admin,cap_net_bind_service+eip /usr/bin/nmap

When I start HA, every 5 minutes nmap runs and discovers online devices and sets them to home. But 3 minutes later all devices transition to away and are picked up again 2 minutes away.
There’s nothing relevant in the logs when this happens.
Any idea how to fix it (without more frequent polling)?
Thanks!

That’s because of the default consider home setting, which is 3 minutes. This means that three minutes after it was last detected, it will be marked as away.

You’ve set it to run every 5 minutes (300 seconds), and not rescan if seen within 15 minutes (900) seconds. Those settings are very high. I’d suggest dropping them to 30 seconds and 90 seconds respectively.

Thank you. I mistook it for home_interval.