Hello everyone! I’m excited to share a project I’ve been working on: BeamNG Mobile Cockpit. This is a high-performance, bi-directional controller that turns any smartphone into a professional simulator
dashboard and steering wheel.
LINK: https://github.com/tasbaris/ADB-BeamNG-Mobile-Controller
Unlike basic mobile controllers, this system uses a dual-protocol approach (WebSocket + UDP) to ensure ultra-low latency (<10ms) and provides real-time telemetry data back to your phone.
Key Features:
* Precision Steering: Optimized gyroscope processing for smooth, high-precision steering.
* Advanced Control Hub: Dedicated buttons for Nitro (NOS), ESC Modes, 4WD/Differential Locks, Lights, Ignition, and Recovery.
* Cross-Platform: Works on any modern smartphone browser (Chrome recommended). No app installation required.
* Compatibility: Fully tested and verified on Windows and macOS (via CrossOver).
️ How It Works:
The system consists of a Python bridge server and a custom Lua Game Engine extension. It listens to BeamNG’s Outgauge port for telemetry and forwards your phone’s touch/sensor data to a Virtual Input Device
within the game.
Installation & Setup:
- Lua Extension: Copy mobileController.lua to your user folder: Documents/BeamNG.drive/lua/ge/extensions/.
- Run the Server: Run python server.py on your PC (requires websockets library).
- Launch Web UI: Open a terminal in the project folder and run python3 -m http.server 8000. Access http://localhost:8000 from your mobile browser.
- Bind Controls: In the game’s Controls menu, bind the new axes and buttons detected from the “BeamNG Pro Controller” virtual device.
Pro Tip (Lowest Latency):
For the best experience, I highly recommend using a USB cable with ADB Reverse to bypass Wi-Fi jitter:
1 adb reverse tcp:8000 tcp:8000
2 adb reverse tcp:8765 tcp:8765
Technical Stack: Python, Lua, JavaScript (WebSocket/UDP).
License: MIT
Feel free to ask questions or suggest new features. See you on the track! ️