by Nick B
Control if and when the phone locks or unlocks when connected to or disconnected from a charger. Set the two options variables to customize.
1) On my phone Automate takes a few seconds to recognize a change in lock state, so this may not behave correctly when changing charge state immediately after changing lock state.
2) Android's default behaviour currently wakes the phone in all cases. Since automate doesn't currently let us wake the device, this flow relies on that default behaviour.