A Gyroscope Based Mouse Built Using the Esp32 C3 Super mini and the MPU6050. Since project uses a BLE library using a 500mah battery will make it last up to 5-6 hours on continuous use. I used a 500mah LIPO Battery along with a Tp4056 for this project
| Component |
|---|
| ESP32-C3 Super Mini |
| MPU6050 |
| 5x momentary push buttons |
| Signal | ESP32-C3 Pin |
|---|---|
| Left click | GPIO5 |
| Right click | GPIO6 |
| Middle click | GPIO20 |
| Scroll up | GPIO8 |
| Scroll down | GPIO9 |
| MPU6050 SDA | GPIO4 |
| MPU6050 SCL | GPIO3 |
| MPU6050 VCC | 3V3 |
| MPU6050 GND | GND |
Install via the Arduino IDE Library Manager:
- NimBLE-Arduino (by h2zero) — v2.3.x or newer
The MPU6050 is read directly over raw I2C registers, so no separate MPU6050 library is required.
- Install the ESP32 board package and select your ESP32-C3 board in the Arduino IDE.
- Install NimBLE-Arduino from the Library Manager.
- Wire everything per the table above.
- Open the
.inofile and flash it to the board. - Open Serial Monitor at
115200baud to watch calibration/connection status.
Once flashed, the board shows up as "ESP32 Air Mouse". Pair it from your computer or phone's Bluetooth settings like any other Bluetooth mouse.
- MPU6050 not found at boot: double-check wiring against the table above, particularly SDA/SCL.
- Choppy/jumpy cursor: check
smoothFactorandMOTION_SEND_INTERVAL_MSfirst. If it persists, check your OS's mouse settings (e.g. "Enhance pointer precision" on Windows).
.webp)


