How jojogaming93/phonecontrol works
PhoneControl is a native Windows app for mirroring an Android phone over USB and translating PC keyboard/mouse input into editable touch mappings. The main workflow is selecting and connecting a phone, opening its mirrored view, then applying foreground-only controls through a persistent touch channel. Profiles, mapping edits, and optional driving-HUD recognition support that workflow. The graph reflects the sampled implementation and README; some connection details and unsampled subsystems are represented only where documented.
Main entry points: MainWindow.cs Dashboard UI · InputEngine.cs Input engine · DrivingModeMonitor.cs Driving mode monitor · DeviceSession.cs Device session
Components 20
App and connection
- App startup
src/PhoneControl/Program.cs - Dashboard UI
src/PhoneControl/MainWindow.cs - Connection policy
src/PhoneControl/ConnectionPolicy.cs - Device session
src/PhoneControl/DeviceSession.cs - About and license
src/PhoneControl/AppInfo.cs
Controls and profiles
- Input engine
src/PhoneControl/InputEngine.cs - Raw input
src/PhoneControl/RawInputReader.cs - Aim gestures
src/PhoneControl/AimGesture.cs - Wheel input
src/PhoneControl/MouseWheelInput.cs - Mapping overlay
src/PhoneControl/MappingOverlay.cs - Profiles and settings
src/PhoneControl/Profile.cs
Driving recognition
- Driving mode monitor
src/PhoneControl/DrivingModeMonitor.cs - Mirror frame capture
src/PhoneControl/MirrorFrameCapture.cs - HUD detector
src/PhoneControl/DrivingHudDetector.cs - Detection regression tool
src/PhoneControl/DrivingDetectionTest.cs
Phone and Windows
- Android phone
- ADB and scrcpy
- Windows interop
src/PhoneControl/Native.cs - Samsung driver repair
src/PhoneControl/SamsungDriver.cs
Other components
- PC user
Connections 27
- PC user → App startup: starts
README.md - App startup → Dashboard UI: opens
src/PhoneControl/Program.cs - Dashboard UI → Connection policy: checks connection
src/PhoneControl/MainWindow.cs - Dashboard UI → Device session: connects device
src/PhoneControl/MainWindow.cs - Dashboard UI → Samsung driver repair: repairs driver
src/PhoneControl/MainWindow.cs - Dashboard UI → About and license: shows details
src/PhoneControl/MainWindow.cs - Device session → Android phone: connects USB
README.md - Device session → ADB and scrcpy: starts mirroring
README.md - Device session → Android phone: opens control channel
src/PhoneControl/DeviceSession.cs - Dashboard UI → Input engine: configures controls
src/PhoneControl/MainWindow.cs - Dashboard UI → Raw input: registers input
src/PhoneControl/MainWindow.cs - Raw input → Input engine: forwards events
src/PhoneControl/RawInputReader.cs - Input engine → Device session: sends touches
src/PhoneControl/InputEngine.cs - Input engine → Profiles and settings: reads mappings
src/PhoneControl/InputEngine.cs - Input engine → Aim gestures: updates aiming
src/PhoneControl/InputEngine.cs - Input engine → Wheel input: reads wheel actions
src/PhoneControl/InputEngine.cs - Dashboard UI → Mapping overlay: edits mappings
src/PhoneControl/MainWindow.cs - Dashboard UI → Profiles and settings: imports and saves
src/PhoneControl/MainWindow.cs - Input engine → Windows interop: checks foreground
src/PhoneControl/InputEngine.cs - Raw input → Windows interop: reads device events
src/PhoneControl/RawInputReader.cs - Dashboard UI → Driving mode monitor: starts recognition
src/PhoneControl/MainWindow.cs - Driving mode monitor → Mirror frame capture: captures mirror
src/PhoneControl/DrivingModeMonitor.cs - Driving mode monitor → Device session: captures fallback frame
src/PhoneControl/DrivingModeMonitor.cs - Driving mode monitor → HUD detector: classifies HUD
src/PhoneControl/DrivingModeMonitor.cs - Driving mode monitor → Input engine: sets driving mode
src/PhoneControl/DrivingModeMonitor.cs - Mirror frame capture → Windows interop: captures desktop
src/PhoneControl/MirrorFrameCapture.cs - Detection regression tool → Driving mode monitor: checks recognition
src/PhoneControl/DrivingDetectionTest.cs