A comprehensive suite of Python and Arduino tools for communicating with MakeBlock robots over Bluetooth Low Energy (BLE), without relying on the MakeBlock proprietary software.
Key Advantage: Now you can program your MakeBlock robot with Arduino IDE and control it entirely through custom Python scripts!
python_auriga_bluetooth/
├── arduino/ # Arduino sketches for MakeBlock robots
│ ├── auriga_ble_test/ # Main firmware for BLE communication
│ └── beep_when_found/ # Utility for identifying robots
├── cli_apps/ # Command-line tools
│ ├── scan_robots.py # Discover and catalog robots
│ ├── identify_bots.py # Identify specific robot by beeping
│ ├── ble_logger.py # Log device characteristics
│ ├── makeblock_bluetooth.py # Interactive terminal
│ ├── makeblock_ble_lite.py # Lightweight CLI
│ └── auriga_firmware.py # Firmware protocol interface
├── gui_apps/ # GUI applications
│ ├── gui_ble.py # Basic send/receive interface
│ ├── gui_ble_wasd.py # Keyboard-controlled robot
│ ├── gui_ble_pygame.py # Real-time Pygame interface
│ └── gui_ble_telemetry.py # Sensor data visualization
└── README.md # This file
# Clone the repository
git clone <repository-url>
cd python_auriga_bluetooth
# Install Python dependencies
pip install bleak pygame tkinter
# For Arduino sketches:
# - Install Arduino IDE
# - Install MakeBlock libraries
# - Upload auriga_ble_test.ino to your robot-
Upload firmware to your MakeBlock Auriga:
- Open
arduino/auriga_ble_test/auriga_ble_test.inoin Arduino IDE - Select correct board (MakeBlock Auriga)
- Upload to robot
- Open
-
Discover your robot:
python cli_apps/scan_robots.py
This creates
makeblock_robots.csvwith available devices. -
Identify your specific robot:
python cli_apps/identify_bots.py
Listen for beeping to identify which robot is which.
-
Start communicating:
python gui_apps/gui_ble.py # Basic communication python gui_apps/gui_ble_wasd.py # Keyboard control
- Arduino Sketches - Firmware for MakeBlock robots
- CLI Applications - Command-line tools for scanning, logging, and communication
- GUI Applications - Full-featured interfaces for control and monitoring
| Application | Framework | Purpose | Use Case |
|---|---|---|---|
| gui_ble.py | Tkinter | Basic send/receive | General communication |
| gui_ble_wasd.py | Tkinter | WASD keyboard control | Robot movement |
| gui_ble_pygame.py | Pygame | Real-time streaming | High-performance control |
| gui_ble_telemetry.py | Pygame | Sensor visualization | Data monitoring |
See GUI Applications for detailed documentation.
| Tool | Purpose | Typical Usage |
|---|---|---|
| scan_robots.py | Discover and catalog robots | Initial setup |
| identify_bots.py | Identify specific robot by beeping | Find which robot is which |
| ble_logger.py | Log device services/characteristics | Debugging/discovery |
| makeblock_bluetooth.py | Interactive terminal interface | Manual testing |
| makeblock_ble_lite.py | Lightweight CLI alternative | Resource-constrained use |
| auriga_firmware.py | Firmware protocol interface | Sensor/motor control |
See CLI Applications for detailed documentation.
| Sketch | Purpose | Features |
|---|---|---|
| auriga_ble_test | Main firmware | BLE communication, LED/buzzer control |
| beep_when_found | Robot identification | Beeps on command for identification |
See Arduino Sketches for detailed documentation.
python gui_apps/gui_ble.py
# 1. Click "Scan Devices"
# 2. Select your robot
# 3. Type "F" (forward) and click Sendpython gui_apps/gui_ble_wasd.py
# 1. Connect to robot
# 2. Hold W/A/S/D to drive
# 3. Adjust frequency with +/- keyspython cli_apps/identify_bots.py
# Listen for beeping - each beep indicates which robot is being identifiedpython cli_apps/ble_logger.py
# Creates device_log.json with all services and characteristics- Edit
arduino/auriga_ble_test/auriga_ble_test.ino - Upload to robot via Arduino IDE
- Test with any Python CLI or GUI app
Defines custom commands and directions for WASD apps:
{
"header": [255, 85],
"directions": {
"w": "F",
"a": "L",
"s": "B",
"d": "R",
"e": "E",
"stop": "STOP"
},
"actions": [
{
"key": "q",
"data": "LIGHT_TOGGLE",
"label": "Light"
}
]
}Automatically created - stores last connected device for quick reconnection:
{
"name": "Makeblock_LE10a5622dd32e"
}Default MakeBlock UUIDs:
- Write:
0000ffe3-0000-1000-8000-00805f9b34fb - Notify:
0000ffe2-0000-1000-8000-00805f9b34fb
[HEADER] [DATA] [LINE_ENDING]
- Header: Optional 0xFF 0x55 (configurable)
- Data: Command payload (string, bytes, or mixed)
- Line Ending: \n, \r, \r\n, or none (configurable)
All sketches use 115200 baud for serial communication.
- Python 3.7 or higher
- pip package manager
pip install bleak pygameOptional:
pip install tkinter # Usually pre-installed on most systems- Arduino IDE 1.8.0+
- MakeBlock Auriga board support
- MeAuriga library
- MakeBlock Auriga robot
- Bluetooth 4.0+ compatible device (PC, laptop, Raspberry Pi)
- USB cable for uploading firmware
"No Bluetooth adapter found"
- Check Bluetooth is enabled on your system
- On Linux:
sudo systemctl start bluetooth - On Mac/Windows: Enable Bluetooth in system settings
"Device not found"
- Run
scan_robots.pyto verify robot is discoverable - Ensure robot is powered on
- Check if Bluetooth is not already connected to another app
"Cannot connect to device"
- Verify correct device name
- Try scanning again with
scan_robots.py - Check if device is in range (usually ~10 meters)
"Garbled messages received"
- Check line ending setting matches device
- Verify baud rate is 115200 (for serial sketches)
- Try different line ending options
For more detailed troubleshooting, see:
Contributions welcome! Areas for improvement:
- Additional GUI applications
- More robot sketches
- Performance optimizations
- Documentation improvements
- Bug fixes and testing
[Specify your license here]
- Bleak BLE Library
- MakeBlock Auriga
- Pygame Documentation
- Arduino Reference
- Bluetooth Low Energy Overview
✅ Alpha Stage - Core functionality working, documentation improving
- ✅ BLE device scanning and connection
- ✅ Basic send/receive communication
- ✅ Keyboard-based robot control
- ✅ Sensor data logging
- ✅ Multiple GUI frameworks
- ⏳ Comprehensive test suite (in progress)
- ⏳ Mobile app support (planned)
- ⏳ Advanced telemetry visualization (in progress)
- Added CLI tools for device discovery
- Added multiple GUI applications
- Improved documentation with separate README files for each component
- Support for custom action configurations
- Initial Python BLE communication tools
- Basic GUI application
For detailed information about each component, see the respective README files: