SHM automatically arms when I'm home a put my phone on charger

Hi. I use my Motorola phone as a presence detector to arm and disarm SHM and it works great except I have noticed when I plug my phone in the charger at home sometimes SHM automatically arms. This must be a glitch. Is there any way to fix this?

I’d say your phone disables location services when plugged in. Check the settings?