Meshtastic

Devices

Wio tracker
Raspberry Pi PICO
Raspberry Pi

Wareshare Hat for RPi.

NB The Wareshare Hat is no longer supported by Meshtastic for transmitting messages.

CLI

Setup
sudo apt install python3-full
Install
mkdir -p ~/.venvs
python3 -m venv ~/.venvs/meshtastic
source ~/.venvs/meshtastic/bin/activate.csh
python -m pip install pytap2
python -m pip install meshtastic
Update
python -m pip install --upgrade meshtastic

Information

meshtastic --port /dev/ttyACMx --info

Region

meshtastic --port /dev/ttyACMx --set lora.region EU_868

Debug

meshtastic --port /dev/ttyACMx --noproto

Channel

meshtastic --port /dev/ttyACMx --ch-set name "XXX" --ch-index 1
Connected to radio
Set name to HOME
Writing modified channels to device
meshtastic --port /dev/ttyACMx --ch-set psk base64:xxx --ch-index 1 
Connected to radio
Writing modified channels to device

Messages

This setup sends and receives messages on the CLI on a Pi Pico attached to /dev/ttyACM2

Receive

Install

git clone https://github.com/brad28b/meshtastic-cli-receive-text
cd meshtastic-cli-receive-text
python -m pip install -r requirements.txt

Edit the IP address and/or serial port in each script.

Listen

python read_messages_serial.py
Using serial port: /dev/ttyACM2
Initializing SerialInterface to get node info...
Node info retrieved.
Parsing node info...
Node info parsed.
Node List:
{'num': '!0342a02e', 'user': {'shortName': 'Pico'}}
{'num': '!014fdb61', 'user': {'shortName': 'RPi'}}
Subscribed to meshtastic.receive
SerialInterface setup for listening.
RPi: Hello World!
Send

Direct message

meshtastic --port /dev/ttyACM2 --dest \!014fdb61 --sendtext "Hi!"

Channel message

meshtastic --port /dev/ttyACM2 --ch-index 1 --sendtext "Hello!"

Info

These are some parameters which can be used to sniff the LoRa radio with RTL-SDR.

region=EU_868, name=LongFast

freqEnd: 869.4000.250000 MHz

numChannels: 1 x 250.000kHz

Radio frequency: 869.525024

Resources

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies