how ambient mode works