Compare commits

..

8 commits
v1.0.1 ... main

Author SHA1 Message Date
Your Name
6b9ef5969c Clean SVG icon for transparent background 2025-12-20 11:20:55 -06:00
Your Name
36c61df6a6 Use centered SVG icon 2025-12-20 11:12:27 -06:00
Your Name
9a8db41d31 Update icon 2025-12-20 11:04:59 -06:00
Your Name
672dca33e6 Remove SVG icon 2025-12-20 11:02:35 -06:00
Your Name
7cbdb16e83 Use PNG icon in README 2025-12-20 10:58:38 -06:00
Your Name
6988e55a46 Feature icon in README 2025-12-20 10:22:16 -06:00
Your Name
a5a0ae7039 Add module icon 2025-12-20 10:16:26 -06:00
Your Name
eafb2fc5af Expand README 2025-12-20 10:09:30 -06:00
2 changed files with 73 additions and 2 deletions

View file

@ -1,5 +1,61 @@
# scrcpyd
Magisk module for scrcpy keep-unlock with optional screen-awake when using `--stay-awake`.
<p align="center">
<img src="icon.svg" alt="scrcpyd icon" width="256">
</p>
Latest release contains the installable ZIP.
![scrcpyd icon](icon.png)
A Magisk module that keeps your device unlocked **only while scrcpy is running and ADB is connected**. It does **not** remove your PIN/pattern and restores your original lock timeout as soon as scrcpy exits.
Built for long XR sessions where repeated unlocks are disruptive, without weakening security when scrcpy is not in use.
## Features
- **Scoped to scrcpy**: active only when the scrcpy server process exists.
- **ADBgated**: requires ADB connection (USB or wireless).
- **Restores settings**: original lock timeout is restored immediately on exit.
- **Optional screenawake**: only when scrcpy is started with `--stay-awake`.
## Install
1) Download the latest ZIP from Releases.
2) Magisk → Modules → Install from storage → select the ZIP.
3) Reboot.
## Usage
- Normal (keep unlocked, screen may still dim):
```bash
scrcpy
```
- Keep the screen awake too:
```bash
scrcpy --stay-awake
```
## How It Works
While scrcpy is running **and** ADB is connected, the module:
- Sets `lock_screen_lock_after_timeout` to a very large value.
- If `--stay-awake` is detected in the scrcpy process args, it also sets `screen_off_timeout` to a very large value and issues a wake event.
When scrcpy stops or ADB disconnects, it restores your original values.
## Safety & Security
- Your PIN/pattern remains intact.
- No changes persist after scrcpy exits.
- The module is inert when ADB is off or scrcpy is not running.
## Compatibility
- Tested on Android 16 (LineageOS) + Magisk.
- Should work on most modern Android builds with Magisk and root.
## Files
- `service.sh`: background watcher/keepalive loop
- `module.prop`: Magisk metadata
- `icon.png`: module icon
## Uninstall
- Magisk → Modules → Remove
- Reboot
## Release
Latest release: https://github.com/sudoxreboot/scrcpyd/releases

15
icon.svg Normal file
View file

@ -0,0 +1,15 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="512" height="512" fill="none" stroke="url(#iconStroke)" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" role="img" aria-label="scrcpyd icon">
<defs>
<linearGradient id="iconStroke" x1="0" y1="0" x2="1" y2="0">
<stop offset="0%" stop-color="#00FFD5"/>
<stop offset="33.3333%" stop-color="#B79CFF"/>
<stop offset="66.6667%" stop-color="#7FFFD4"/>
<stop offset="100%" stop-color="#FF4FD8"/>
</linearGradient>
</defs>
<path d="M13 3H4a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-3" />
<path d="M8 21h8" />
<path d="M12 17v4" />
<path d="m22 3-5 5" />
<path d="m17 3 5 5" />
</svg>

After

Width:  |  Height:  |  Size: 713 B