No description
- C++ 80.9%
- C 19.1%
- Replace high-level UWBHelper calls with direct AT command sequence - Add hardware reset on every startup for reliable operation - Implement proper timing delays between AT commands - Add configuration verification with AT+GETCFG - Complete rewrite of parseRangeData to handle multiple devices correctly - Fix anchor/tag behavior: anchors only show tags, tags show all anchors - Add isAnchor parameter to parseRangeData for device-specific logic - Maintain backward compatibility with default parameter values |
||
|---|---|---|
| docs | ||
| lib/UWBHelper | ||
| src | ||
| .gitignore | ||
| CLAUDE.md | ||
| platformio.ini | ||
| README.md | ||
MaUWB ESP32-S3 Positioning System
Ultra-wideband (UWB) positioning system using ESP32-S3 and Makerfabs UWB modules for indoor positioning and warehouse mapping applications.
Features
- ESP32-S3 based anchor and tag devices
- Real-time distance measurement with <10cm accuracy
- OLED display for status and measurements
- Multiple tag support (up to 64 tags)
- 6.8Mbps communication rate
- Complete AT command implementation
- Position calculation with trilateration
- Anchor auto-positioning system
- Real-time positioning with USB data logging
Hardware: Makerfabs MaUWB ESP32-S3 UWB Module with SSD1306 OLED displays
Unified Architecture
Single Firmware - All devices use the same main.cpp with config-driven behavior:
anchor: Base station with distributed positioning framework (default: ID=0, Network=1234)tag: Mobile tracker with coordinate collection (default: ID=1, Network=1234)debug: Development build with debug output enabled
Build & Upload
# Build with default settings
pio run -e anchor # Anchor ID=0, Network=1234
pio run -e tag # Tag ID=1, Network=1234
# Build with custom device ID and network
set PLATFORMIO_BUILD_FLAGS=-DUWB_INDEX=5 -DNETWORK_ID=2000
pio run -e anchor # Anchor ID=5, Network=2000
# Upload to device
pio run -e tag -t upload
# Monitor serial output
pio device monitor
Project Structure
Modular Configuration System
src/main.cpp- Single unified firmware for all device typessrc/config/- Device behavior configurationconfig.h- Hardware pins and system settingsdevice_config.h- Device role detection and unified behavioranchor_config.h- Anchor-specific settings (positioning, inter-anchor communication)tag_config.h- Tag-specific settings (USB streaming, coordinate collection)positioning_config.h- Distributed positioning algorithm parameters
lib/UWBHelper/- Complete UWB AT command library with positioning supportplatformio.ini- Simplified build environments (3 instead of 8+)
AT Command Support
Complete implementation of all AT commands from the official manual:
Basic Commands
AT?- Test connectionAT+GETVER?- Get firmware versionAT+RESTART- Restart moduleAT+RESTORE- Factory resetAT+SAVE- Save configuration
Configuration
AT+SETCFG/AT+GETCFG?- Device configurationAT+SETANT/AT+GETANT?- Antenna delay calibrationAT+SETCAP/AT+GETCAP?- System capacity settingsAT+SETRPT/AT+GETRPT?- Auto-reporting control
Network & Power
AT+SETPAN/AT+GETPAN?- Network ID configurationAT+SETPOW/AT+GETPOW?- Transmission power controlAT+SLEEP- Sleep mode for battery conservation
Data Communication
AT+DATA/AT+RDATA- Custom data transmission- Real-time range reporting via
AT+RANGEparsing
Library Features
The enhanced UWBHelper library provides:
- Complete AT command coverage
- Advanced range data parsing for multiple anchors
- Position calculation algorithms (trilateration, multilateration)
- Anchor position management for auto-positioning
- Distance filtering for improved accuracy
- Backward compatibility with existing code
Configuration
- Network ID: 1234 (configurable via AT+SETPAN)
- Baud Rate: 115200
- Communication: 6.8Mbps (AT+SETCFG parameter)
- Range filtering: Enabled for accuracy
- Refresh Rate: 10Hz (configurable via AT+SETCAP)
- Max Anchors: Unlimited (tags connect to 8 closest)
- Max Tags: 64 per network
Documentation
- AT Command Manual - Complete AT command reference
- Hardware Product Page - Official hardware documentation
- Project Roadmap - Development plan for indoor positioning system
Applications
This system is designed for:
- Indoor positioning in warehouses and large buildings
- Asset tracking and inventory management
- Navigation assistance in GPS-denied environments
- WiFi signal mapping and coverage analysis
- Research and development in UWB positioning

