A Docker-based TCP multiplexer for MicroADSB (adsbPIC) USB receivers that allows sharing ADS-B data with multiple clients (like dump1090).
β Can also be used without Docker as a system service using Python environment only, instructions available here.
If you have a USB ADS-B receiver like this, you can easily contribute aircraft data to various flight tracking services like FlightRadar24, FlightAware, ADSBHub, OpenSky Network, ADS-B Exchange, ADSB.lol and many others. Despite its age and simplicity, MicroADSB / adsbPIC by Sprut often outperforms many cheap RTL-SDR dongles in ADS-B reception quality and stability.
The device works perfectly on Raspberry Pi and other Unix-based systems, making it an excellent choice for feeding data to popular aggregators.
- Supports MicroADSB USB receivers (microADSB / adsbPIC)
- Implements Beast Binary Format v2.0 for maximum compatibility
- Advanced message validation using pyModeS library:
- Reliable CRC computation and verification
- Robust error detection
- Dual-mode operation:
- TCP server for multiple client connections
- TCP client for forwarding data to remote servers
- High-performance message processing:
- Up to 500 messages/sec on 1 GHz CPU
- Optimized CRC calculation
- Efficient memory usage (~5 MB/1k connections)
- Real-time statistics and monitoring
- Configurable TCP ports and device settings
- Docker support with automatic builds
- Proper device initialization and error handling
- Automatic reconnection on device errors
- Full implementation of Beast Binary Format v2.0
- Supports all message types:
- Mode-S Short (DF17, 7 bytes)
- Mode-S Long (14 bytes)
- Mode-A/C with MLAT
- Features:
- 6-byte precision timestamps
- CRC-24 validation
- Proper escape sequence handling
- Compatible with dump1090 and other tools
- Original adsbPIC creator: Joerg Bredendiek β Sprut
- Device: MicroADSB USB receiver (β2010-20??)
- Manufacturer: Miroslav Ionov
- MicroADSB.com (website no longer available), last archived copy on WebArchive: September 18, 2024
- Anteni.net (active as of Feb 2025)
- Microcontroller: PIC18F2550
- Firmware: Joerg Bredendiek β Sprut
- Maximum theoretical frame rate: 200,000 fpm
- Practical maximum frame rate: β6,000 fpm
- Communication: USB CDC (115200 baud)
- Message format: ASCII, prefixed with '*', terminated with ';'
- Docker
- Docker Compose (optional)
- USB port for the MicroADSB device
- Linux system with udev support
β Set DIP switch 1 to ON position, while keeping others OFF:
1 2 3 4
βββ βββ βββ βββ
βββ β β β β β β
β β βββ βββ βββ
βββ βββ βββ βββ
ON OFF OFF OFF
- Create a
docker-compose.yml
:
services:
picadsb-multiplexer:
image: ghcr.io/smkrv/picadsb-multiplexer:latest
container_name: picadsb-multiplexer
restart: unless-stopped
devices:
- /dev/ttyACM0:/dev/ttyACM0
ports:
- "31002:31002"
environment:
- ADSB_TCP_PORT=31002
- ADSB_DEVICE=/dev/ttyACM0
- ADSB_LOG_LEVEL=INFO
- ADSB_REMOTE_HOST= # Indicate if required
- ADSB_REMOTE_PORT= # Indicate if required
volumes:
- ./logs:/app/logs
- Start the service:
docker-compose up -d
docker run -d \
--name picadsb-multiplexer \
--serial=/dev/ttyACM0:/dev/ttyACM0 \
-p 31002:31002 \
-e ADSB_TCP_PORT=31002 \
-e ADSB_DEVICE=/dev/ttyACM0 \
-e ADSB_LOG_LEVEL=INFO \
-e ADSB_REMOTE_HOST=localhost \ # Indicate if required
-e ADSB_REMOTE_PORT=30005 \ # Indicate if required
-v $(pwd)/logs:/app/logs \
ghcr.io/smkrv/picadsb-multiplexer:latest
Variable | Description | Default |
---|---|---|
ADSB_TCP_PORT | TCP port for client connections | 31002 |
ADSB_DEVICE | Path to USB device | /dev/ttyACM0 |
ADSB_LOG_LEVEL | Logging level (DEBUG, INFO, WARNING, ERROR) | INFO |
ADSB_REMOTE_HOST | Remote server host for forwarding (optional) | |
ADSB_REMOTE_PORT | Remote server port for forwarding (optional) |
- Accepts multiple client connections
- Ideal for feeding multiple services simultaneously
- Example services:
- dump1090
- FlightAware
- ADSBHub
- OpenSky Network
- ADS-B Exchange
- ADSB.lol
- Forwards data to a remote server
- Maintains persistent connection
- Automatic reconnection on failures
- Example usage:
services:
picadsb-multiplexer:
environment:
- ADSB_REMOTE_HOST=feed.adsbexchange.com
- ADSB_REMOTE_PORT=30005
- Base footprint: ~5 MB
- Per-client overhead: ~2 KB
- Maximum recommended clients: 1000
- Idle: <1% on Raspberry Pi 3
- Peak: ~5-10% at 500 msg/sec
- CRC calculation: Optimized with lookup table
The container needs access to the USB device. Make sure the device is properly mapped in the Docker configuration:
devices:
- /dev/ttyACM0:/dev/ttyACM0
You might need to add udev rules on the host system:
# Create a new udev rule
echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="04d8", ATTRS{idProduct}=="000a", MODE="0666"' | \
sudo tee /etc/udev/rules.d/99-microadsb.rules
# Reload udev rules
sudo udevadm control --reload-rules
sudo udevadm trigger
# Start dump1090 with network input from multiplexer
docker run -d \
--name dump1090 \
--network host \
antirez/dump1090 \
--net-only \
--net-ri-port 31002
dump1090 --net-only --net-ri-port 31002
- Clone the repository:
git clone https://github.com/smkrv/picadsb-multiplexer.git
cd picadsb-multiplexer
- Build the Docker image:
docker build -t picadsb-multiplexer .
.
βββ Dockerfile
βββ LICENSE
βββ README.md
βββ adsb_message_parser.py
βββ assets
βΒ Β βββ images
βΒ Β βββ IMG_8767.jpg
βΒ Β βββ IMG_8768.jpg
βΒ Β βββ IMG_8769.jpg
βΒ Β βββ IMG_8771.jpg
βΒ Β βββ IMG_8772.jpg
βββ docker-compose.yml
βββ entrypoint.sh
βββ picadsb-multiplexer.py
βββ requirements.txt
βββ .dockerignore
βββ .github
βββ workflows
βββ docker-publish.yml
# Run the multiplexer in debug mode
docker run -it --rm \
--serial=/dev/ttyACM0:/dev/ttyACM0 \
-e ADSB_LOG_LEVEL=DEBUG \
picadsb-multiplexer
Logs are stored in the logs
directory:
picadsb-multiplexer_YYYYMMDD_HHMMSS.log
: Detailed application log- Container logs can be viewed with
docker logs picadsb-multiplexer
The multiplexer maintains real-time statistics:
- Messages processed
- Messages per minute
- Client connections
- Error counts
- Device not found:
# Check device presence
ls -l /dev/ttyACM*
# Check USB device
lsusb | grep "04d8:000a"
- Permission denied:
# Add current user to dialout group
sudo usermod -a -G dialout $USER
- Connection refused:
# Check if port is open
netstat -tuln | grep 31002
Enable debug logging:
docker-compose up -d -e ADSB_LOG_LEVEL=DEBUG
Messages/sec: 500
Beast conversion: 99.9%
CRC validation: 99.9%
Buffer usage: 2%
Active clients: 5
Remote connection: Connected
ADS-B Message Monitor (adsb_message_parser.py)
A real-time monitoring tool for ADS-B messages that provides a formatted display of aircraft surveillance data.
- Real-time display of ADS-B messages in a structured table format
- Message type identification and description
- Statistical analysis of received messages
- Support for various ADS-B message formats (DF0, DF4, DF5, DF17, DF20)
- Filtering of keep-alive messages
- Session statistics with message type distribution
python3 adsb_message_parser.py [--host HOST] [--port PORT]
--host
: Server host address (default: localhost)--port
: Server port number (default: 31002)
ADS-B Message Monitor
Connected to localhost:31002
Timestamp | Type | Message | Description
------------------------------------------------------------------------------------------
2025-02-14 15:03:00.012 | 28 | *28000000000000; | Extended Squitter (DF5)
A real-time monitoring tool for ADS-B messages that provides a formatted display of aircraft surveillance data. Designed for quick testing and debugging of ADS-B receivers with human-readable output, message type identification, and live statistics tracking.
- Clone the repository:
git clone https://github.com/smkrv/picadsb-multiplexer/tree/main
cd picadsb-multiplexer
- Install required dependency:
pip3 install pyserial
Create persistent device name with udev rule:
sudo nano /etc/udev/rules.d/99-picadsb.rules
Add rule for automatic device recognition:
SUBSYSTEM=="tty", ATTRS{idVendor}=="04d8", ATTRS{idProduct}=="000a", SYMLINK+="ttyACM0"
Apply new rule:
sudo udevadm control --reload-rules
Start the multiplexer:
python3 picadsb-multiplexer.py --port 31002 --serial /dev/ttyACM0
Verify data flow using included test client:
python3 adsb_message_parser.py [--host localhost] [--port 31002]
Connect to multiplexer using dump1090:
dump1090 --net-only --net-ri-port 31002
- Create systemd service file:
sudo nano /etc/systemd/system/picadsbmultiplexer.service
- Configure service:
[Unit]
Description=picadsbmultiplexer TCP Bridge
After=network.target
[Service]
ExecStart=/usr/bin/python3 /path/to/picadsb-multiplexer.py --port 31002 --serial /dev/ttyACM0
WorkingDirectory=/path/to/script/directory
StandardOutput=append:/var/log/picadsbmultiplexer.log
StandardError=append:/var/log/picadsbmultiplexer.error.log
Restart=always
User=your_username
[Install]
WantedBy=multi-user.target
Enable and start:
sudo systemctl daemon-reload
sudo systemctl enable picadsbmultiplexer
sudo systemctl start picadsbmultiplexer
Check status:
sudo systemctl status picadsbmultiplexer
Service logs:
sudo journalctl -u picadsbmultiplexer -f
Application logs:
tail -f logs/adsb_muxer_*.log
- Fork the repository
- Create your feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
- Original adsbPIC creator & firmware by Joerg Bredendiek β Sprut
- Original MicroADSB device by Miroslav Ionov
- dump1090 project for ADS-B decoding
- pyModeS The Python ADS-B/Mode-S Decoder
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
Author: SMKRV CC BY-NC-SA 4.0 - see LICENSE for details.
The best support is:
- Sharing feedback
- Contributing ideas
- Recommending to friends
- Reporting issues
- Star the repository
If you want to say thanks financially, you can send a small token of appreciation in USDT:
USDT Wallet (TRC10/TRC20):
TXC9zYHYPfWUGi4Sv4R1ctTBGScXXQk5HZ
Open-source is built by community passion! π
Made with β€οΈ for the Aviation & Radio Enthusiasts Community