You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Start on boot: an opt-in setting for boxes without a firmware autorun #255
A box that only shows cameras (a wall display, a demo stand) should open Decoder by itself after power-on or a reboot. Today someone has to start it with the remote every time.
Some TV-box firmwares already have this: their app list has a per-app menu (Menu key on a tile) with AUTORUN / CLEAN AUTORUN, and a boot receiver of the firmware starts the chosen app. It works with Decoder as it is (checked on the Aceline box: Decoder comes up ~60 s after boot). Many firmwares and phones have nothing like it, and Decoder itself has no way to start on boot.
Proposal
An opt-in Start on boot setting in Decoder, off by default:
A BOOT_COMPLETED receiver (RECEIVE_BOOT_COMPLETED permission). When the setting is on, it opens Decoder with the saved slots and view (grid, U cell, slides) as on a normal start.
Android 10+ blocks activity starts from the background. The documented exception is an app allowed to draw over other apps (SYSTEM_ALERT_WINDOW). When the user turns the setting on and the app lacks it, Decoder opens the system "Display over other apps" screen; where the firmware has no such screen (many TV boxes), it shows the one-line adb command instead: adb shell appops set com.openipc.decoder SYSTEM_ALERT_WINDOW allow
/stats.json reports the setting and whether the permission is granted, so a box can be checked remotely.
README (all three languages): a short "Start on boot" section — use the firmware's own autorun where there is one, otherwise this setting.
Out of scope
Making Decoder the home screen (a HOME category). It is a stronger lock-in and needs the user to pick the default launcher; a separate issue if needed.
Waking the box from standby: that is up to the firmware and its boot loader.
Test
A box without a firmware autorun and a phone: setting on → reboot → Decoder opens by itself with the saved view; setting off → it does not.
Android 10+ without the overlay permission: the hint appears, nothing crashes on boot.
A box with a firmware autorun: no double start when both are on.
Activity
fix: Start on boot keeps the app op over a reboot, a second start doe…
2.19.0: Start on boot (#255)
fix: Start on boot leaves the app alone when a firmware autorun opene…
2.19.0: Start on boot (#255)
2.19.0: Start on boot (#255)
2.19.0: Start on boot (#255)
2.19.0: Start on boot (#255)
2.19.0: Start on boot (#255)
Merge pull request #256 from OpenIPC/feat/start-on-boot-255
Merge pull request #258 from OpenIPC/docs/start-on-boot-delay