Blame

52c0db David Marsh 2026-04-17 00:11:57
1
# Linux
2
a0d7da David Marsh 2026-04-23 00:27:24
3
This is written for debian, raspian or ubuntu. You'll have to make the usual adjustments if you're using something else.
4
b33fbf David Marsh 2026-04-17 01:05:03
5
## Update your OS
6
a0d7da David Marsh 2026-04-23 00:27:24
7
First, update and upgrade your OS
e921be David Marsh 2026-04-17 00:24:16
8
52c0db David Marsh 2026-04-17 00:11:57
9
```
10
sudo apt update
a0d7da David Marsh 2026-04-23 00:27:24
11
sudo apt upgrade -y
52c0db David Marsh 2026-04-17 00:11:57
12
```
e921be David Marsh 2026-04-17 00:24:16
13
b33fbf David Marsh 2026-04-17 01:05:03
14
## Access to USB Serial
15
72069a David Marsh 2026-04-17 01:00:29
16
Add your user to the dialout group, change `$USER` to your user name. This allows your user to access the USB serial device.
e921be David Marsh 2026-04-17 00:24:16
17
18
```
19
sudo usermod -a -G dialout $USER
20
```
686c59 David Marsh 2026-04-17 01:05:45
21
a367b3 David Marsh 2026-04-22 12:24:24
22
You'll need to logout and back in again.
ee4d9c David Marsh 2026-04-20 03:28:56
23
24
## Flash the companion
25
243f38 David Marsh 2026-04-22 12:26:02
26
> [!NOTE]
27
> If you've already flashed your companion with the MeshCore firmware you can skip this step.
15c48d David Marsh 2026-04-22 11:55:42
28
a367b3 David Marsh 2026-04-22 12:24:24
29
> [!IMPORTANT]
30
> Make sure you flash with "Companion USB" not "Companion Bluetooth"
31
6cba14 David Marsh 2026-04-23 00:28:21
32
> [!NOTE]
782639 David Marsh 2026-04-23 00:28:13
33
> TODO find out how to do this on the CLI
15c48d David Marsh 2026-04-22 11:55:42
34
35
## Install needed software
36
4f8f05 David Marsh 2026-04-30 23:20:44
37
Install pipx, make sure the bin dir is in the path, then install [[Meshcore-Cli|Meshcore/Meshcore-Cli]]
15c48d David Marsh 2026-04-22 11:55:42
38
39
```
40
sudo apt install pipx
7ff893 David Marsh 2026-04-23 00:45:43
41
pipx ensurepath
15c48d David Marsh 2026-04-22 11:55:42
42
pipx install meshcore-cli
5b6839 David Marsh 2026-04-23 13:18:39
43
44
or
45
46
sudo pipx install meshcore-cli --global
15c48d David Marsh 2026-04-22 11:55:42
47
```
a367b3 David Marsh 2026-04-22 12:24:24
48
49
Logout and back in again.
50
51
## Find the USB device
52
53
```
54
meshcli -l
55
```
56
57
Output probably looks like this, you'll want to use the USB one:
58
59
```
60
BLE devices:
61
No BLE HW
62
63
Serial ports:
64
/dev/ttyS0 n/a [n/a]
65
/dev/ttyUSB0 CP2102 USB to UART Bridge Controller - CP2102 USB to UART Bridge Controller [USB VID:PID=10C4:EA60 SER=0001 LOCATION=1-1]
66
```
e188ea David Marsh 2026-04-22 13:26:30
67
1c4a8e David Marsh 2026-04-27 13:31:27
68
## Create serial based symlink
69
70
This creates `/dev/meshcore0` using your devices serial number, which is much more reliable than `ttyUSB0` or `ttyACM0` which can change.
71
72
If you want to change to a different board, you'll have to create `meshcore1` or update these values.
73
74
```
75
sudo udevadm info -a -n /dev/ttyUSB0 | vi -
76
```
77
78
Look for ATTRS{serial} and ATTRS{idVendor}:
79
80
```
81
ATTRS{idVendor}=="303a"
82
ATTRS{serial}=="332AC33C8CDC"
83
```
84
67208d David Marsh 2026-04-27 13:34:20
85
Then open this file:
86
1c4a8e David Marsh 2026-04-27 13:31:27
87
```
88
sudo vi /etc/udev/rules.d/99-meshcore.rules
89
```
90
91
put a line in similar to this:
92
93
```
94
SUBSYSTEM=="tty", ATTRS{idVendor}=="303a", ATTRS{serial}=="332AC33C8CDC", SYMLINK+="meshcore0"
95
```
96
97
run the following:
98
99
```
100
sudo udevadm control --reload-rules
101
sudo udevadm trigger
102
```
103
5f4a9c David Marsh 2026-04-23 02:14:52
104
## Start MeshCLI
105
106
```
1c4a8e David Marsh 2026-04-27 13:31:27
107
meshcli -s /dev/meshcore0
5f4a9c David Marsh 2026-04-23 02:14:52
108
```
109
110
### Configure node
111
112
Do basic companion configuration. You should only need to do this once, unless you want to change these settings:
7ff893 David Marsh 2026-04-23 00:45:43
113
e188ea David Marsh 2026-04-22 13:26:30
114
```
51a7f4 David Marsh 2026-04-27 13:33:30
115
meshcore-cli -s /dev/meshcore0 set radio 915.800,250,11,5
a8a6cf David Marsh 2026-04-30 23:19:36
116
or
117
meshcore-cli -s /dev/meshcore0 set radio 915.075,125,9,5
118
51a7f4 David Marsh 2026-04-27 13:33:30
119
meshcore-cli -s /dev/meshcore0 set name "🦷 rdm cli 0"
120
meshcore-cli -s /dev/meshcore0 advert
e188ea David Marsh 2026-04-22 13:26:30
121
```