Trigger: Battery Level
Revision as of 20:45, 5 January 2026 by MacroDroidDev (talk | contribs)
This trigger fires when the device's Airplane mode setting is changed. You can configure it to trigger when Airplane mode is enabled, or when it is disabled.
Options
When configuring this trigger, select one of the following:
- Airplane Mode Enabled - Fires when Airplane mode is turned ON
- Airplane Mode Disabled - Fires when Airplane mode is turned OFF
How It Works
The trigger listens for the system broadcast that Android sends whenever the Airplane mode state changes. This means the trigger fires immediately when the setting is toggled, regardless of how it was changed (Quick Settings tile, Settings app, or another automation).
Example 1: Mute media when going to sleep
When Airplane mode is enabled at night, automatically mute media volume.
Triggers Airplane Mode Enabled
Actions Volume Change - Media Volume = 0
Constraints Time of Day (10:00 PM - 7:00 AM)
Example 2: Restore connectivity settings after flight
When Airplane mode is disabled, automatically enable Wi-Fi and Bluetooth.
Triggers Airplane Mode Disabled
Actions Set Wi-Fi State (Enable Wi-Fi) Set Bluetooth State (Enable Bluetooth)
Example 3: Log flight times
Track when you enable Airplane mode (boarding a flight) by logging to a file.
Triggers Airplane Mode Enabled
Actions
Write To File - Append "{hour}:{minute}:{second} - Flight mode started" to flight_log.txt
Notes
- This trigger detects changes to Airplane mode. It does not fire based on the current state when a macro is enabled. To check the current Airplane mode state, use the Airplane Mode Constraint.
- On some devices, enabling Airplane mode automatically disables Wi-Fi, Bluetooth, and mobile data. However, some devices allow Wi-Fi and Bluetooth to be re-enabled while Airplane mode remains active.
- No special permissions are required for this trigger.
See Also
- Airplane Mode Constraint - Check if Airplane mode is currently enabled/disabled
- Airplane Mode On/Off Action - Enable or disable Airplane mode