Difference between revisions of "Actions"
Line 156: | Line 156: | ||
[[Action: Get Light Level|Get Light Level]] | [[Action: Get Light Level|Get Light Level]] | ||
+ | |||
+ | [[Action: Get Text From View ID|Get Text From View ID]] | ||
[[Action: GPS Enable/Disable|GPS Enable/Disable]] | [[Action: GPS Enable/Disable|GPS Enable/Disable]] | ||
Line 236: | Line 238: | ||
[[Action: Read Screen Contents|Read Screen Contents]] | [[Action: Read Screen Contents|Read Screen Contents]] | ||
+ | |||
+ | [[Action: Read Screenshoot Contents|Read Screenshoot Contents]] | ||
[[Action: Reboot/Power Off|Reboot/Power Off]] | [[Action: Reboot/Power Off|Reboot/Power Off]] |
Revision as of 16:01, 19 March 2024
An action is something your device can do when a macro runs. A macro must have at least one action to be valid.
Synchronous vs asynchronous
MacroDroid actions typically execute quickly, but certain actions like HTTP requests or shell scripts may take longer. To ensure that subsequent actions wait for these longer actions to complete before continuing, enable the 'Block next action until complete' option in the action's configuration GUI. Otherwise, the action will run asynchronously while other actions continue. In traditional programming languages, you could pass a callback function to execute after the asynchronous action is complete. This allows you to perform additional actions or work with the data returned by the asynchronous action. However, MacroDroid's inner workings are arbitrary, so there is no systematic option for this. Instead, you must rely on different workarounds.
Control flow
List of Actions
Notification LED Enable/Disable
Priority Mode / Do Not Disturb