by KareeM Mohamed
Version 1 (April 22, 2026)
Download (18 downloads)
Automate version: 1.51.1 (Alpha)
Android version: 12
Device brand: POCO (Xiaomi)
Description: this is a simple flow to toggle the state of the torch/flashlight.
Expected behavior: when the torch/flashlight is off, then turn it on and the flow should stay running (and as a result the torch should stay on) until the user changes the state of the torch, and when the torch is on, turn it off.
Current behavior: when the torch is off, it turns it on and off immediately and the flow exits.
as a workaround the "flashlight enabled" block needs to run in a different fiber, like running it in a subroutine block. (fork block works as well but will need extra blocks to mimic what the subroutine block does in this case).
in this exmple flow, to achieve the expected behaviour, connect the "Yes" of block#9 to the "In" of block#18
| 5 stars | 1 | |
| 4 stars | 0 | |
| 3 stars | 0 | |
| 2 stars | 0 | |
| 1 star | 0 | |
| Reports | 0 |
Rate and review within the app in the Community section.