Document OTG mode in README

PR #2974 <https://github.com/Genymobile/scrcpy/pull/2974>
This commit is contained in:
Romain Vimont 2022-01-26 22:30:57 +01:00
parent 91418c79ab
commit c5be0d6438

View file

@ -35,6 +35,7 @@ Its features include:
(Linux-only) (Linux-only)
- [physical mouse simulation (HID)](#physical-mouse-simulation-hid) - [physical mouse simulation (HID)](#physical-mouse-simulation-hid)
(Linux-only) (Linux-only)
- [OTG mode](#otg) (Linux-only)
- and more… - and more…
## Requirements ## Requirements
@ -849,6 +850,26 @@ Special capture keys, either <kbd>Alt</kbd> or <kbd>Super</kbd>, toggle
the mouse back to the computer. the mouse back to the computer.
#### OTG
It is possible to run _scrcpy_ with only physical keyboard and mouse simulation
(HID), as if the computer keyboard and mouse were plugged directly to the device
via an OTG cable.
In this mode, _adb_ (USB debugging) is not necessary, and mirroring is disabled.
To enable OTG mode:
```bash
scrcpy --otg
# Pass the serial if several USB devices are available
scrcpy --otg -s 0123456789abcdef
```
Like `--hid-keyboard` and `--hid-mouse`, it only works if the device is
connected by USB, and is currently only supported on Linux.
#### Text injection preference #### Text injection preference
There are two kinds of [events][textevents] generated when typing text: There are two kinds of [events][textevents] generated when typing text: