**MeshCore -- Part 2**
**[[mpdf>|Download as PDF]]**
This is the second part of the MeshCore Guide. See the [[part1|first part]] to get started.
----
====== Repeaters ======
As mentioned in the [[#part1 |first part]], repeaters are used to extend the range of companions. With radios, the range roughly depends on three factors:
{{ :meshcore:meshcore1.svg|}}
* The antenna characteristics of **both** radios, their heights above the ground, and the line of sight between them.
* The transmitting power of **both** radios.
* The frequency used.
Let's highlight here that it doesn't make sense to talk about the range of //one// radio. For example, I might be able to reach Bob at a maximum distance of 1 km, while reaching Alice 2 km away. That's because Alice might have a better antenna or be higher up than Bob. If one person improves their antenna, height, or line of sight, it helps everyone communicating with them.
That's not so with power. If Bob increases his power, everyone will hear him better, but that won't help him hear anyone else better. It's like if two people on opposite sides of a football field tried to talk to each other: one with a megaphone, and one without.
As a rule of thumb, everyone should use roughly the same power, and focus on improving their antenna, line of sight, and height.
With that in mind, to be effective, a repeater should have a good antenna, be as high as possible, and have a clear line of sight to other repeaters and companions.
====== Equipment ======
* A repeater like the //SenseCAP Solar Node P1-Pro// can be purchased from [[https://www.seeedstudio.com/SenseCAP-Solar-Node-P1-Pro-for-Meshtastic-LoRa-p-6412.html|Seeed Studio]] or [[https://ca.robotshop.com/products/sensecap-solar-node-p1-pro-for-meshtastic-w-gps-battery |RobotShop]]
* The antenna can be upgraded with one like:
* [[https://www.amazon.ca/dp/B08H8J6ZV6 |ALFA Network AOA-915-5ACM 5 dBi]]
* [[https://www.amazon.ca/Waterproof-Fiberglass-SenseCAP-EasyLinkIn-SyncroB/dp/B09N2H166D/|5.8dBi Meshtastic Lora 915MHz Fiberglass Antenna]]
* [[https://mappingnetwork.ca/products/rakwireless-8dbi-fiberglass-antenna?|RAKwireless 8dBi Fiberglass]]
* [[https://www.aliexpress.com/item/1005005132142342.html |One of these from AliExpress]].
* Use the shortest cable possible, like:
* [[https://www.amazon.ca/Bingfu-Bulkhead-Compatible-Wireless-Amplifier/dp/B084VB68H4|Bingfu SMA Male to N Female Bulkhead Mount RG58 Coaxial Cable 1 ft]]
* [[https://www.amazon.ca/dp/B0FDB2BN1R/ |Superbat N Type Female to SMA Male RG316 Coaxial Cable 15cm]]
====== Flashing the Firmware ======
===== Installing a Bootloader =====
This step is optional, but it allows future updates to be performed over-the-air (OTA) via Bluetooth instead of wired via USB. It is **not** required for (or compatible with) ESP32 devices like the Heltec V or T beam.
If you already have MeshCore installed (but not the bootloader), download your current settings:
* Go to https://config.meshcore.io/
* Connect your device to your computer with a USB cable.
* Click on "''Connect''"
* Click on "''Export''"
* Click on "''Disconnect''"
* Locate the "''.json''" file (probably in your Downloads folder).
Download the bootloader:
* Go to https://meshcore.io/flasher
* Select your device
* Select "''Repeater''" (or "''Room Server''")
* Click on "''Download''"
* Select the "''*bootloader-x.x.x-OTAFIXx.x.uf2''" file
* Locate the "''.uf2''" file (probably in your Downloads folder).
Copy the bootloader over to your device:
* Connect your device to your computer with a USB cable.
* Double-click on the reset button.
* Open the drive that just mounted on your computer
* Copy the "''.uf2''" file to the drive.
* The drive may close on its own right away. This is normal.
===== Flashing the Firmware =====
Flash the MeshCore Firmware:
* Go to https://meshcore.io/flasher
* Select your device
* Select "''Repeater''" (or "''Room Server''")
* Select "''Enter DFU Mode''"
* Select "''Erase Flash''"
* Select "''Flash''"
Re-upload your settings:
* Select "''Configure via USB''" from the previous page, or navigate to https://config.meshcore.io/
* Select "''Connect''"
* Select "''Import''"
* Select your "''.json''" file
* Scroll down to the "''Access''" section and retype your "''New Admin password''" (it doesn't remember it)
* Scroll down and select "''Save settings''"
* Select "''Disconnect''"
===== Updating the Firmware OTA =====
Set up the Over-the-Air (OTA) update app (first time only):
* Download the "nRF Device Firmware Update" app by "Nordic Semiconductor ASA" ([[https://play.google.com/store/apps/details?id=no.nordicsemi.android.dfu |Android]], [[https://apps.apple.com/sa/app/nrf-device-firmware-update/id1624454660 |Apple]])
* Open the "''DFU''" app
* In the settings, check "''Packet receipt notification''"
Perform an OTA update:
* Using your phone's browser, navigate to https://meshcore.io/flasher
* Select your device
* Select "''Repeater''" (or "''Room Server''")
* Select "''Download''"
* Select the firmware "''zip''" file (**not** the bootloader file)
* Using the MeshCore app, log in to your repeater (or room server) using the admin password.
* For Room Servers: go to "''Remote Management''"
* Go to the "''Command Line''"
* Type "''start ota''"; you should get a message that says: "''OK - mac: xx:xx:xx:xx:xx:xx''"
* Open the "''DFU''" app
* Under "''File''", click "''Select''" to choose the firmware "''.zip''" file
* Under "''Device''", click "''Select''" and choose the device that has "''DFU''" in the name. If there are no devices with "''DFU''" in the name, select the device with "''OTA''" in the name.
* Under "''Progress''", click "''Start''"
* If you selected a device with "''OTA''" in the name, the process will fail at "''DFU initialization''". Choose "''Abort''" the process and go back to the previous step, and now you should be able to select a device with "''DFU''" in the name.
See [[https://scottbaker.ca/meshcore/repeater-setup |Scott Baker's article]] for more information.
====== More Advanced: Sensors ======
* Install [[https://www.localmesh.nl/en/meshcore-telemetry-functions/|sensors]].
====== Appendix ======
===== About Power =====
The transmit power of radios is often measured in watts (W). For example, in Canada, FRS radios are limited to 0.5W for channels 8--14, and 2W for the channels 1--7 and 15--22.(([[https://www.fleetwooddp.com/pages/frs-gmrs-frequencies]])). Handheld ham radios can typically transmit up to 5W, mobile VHF/UHF radio up to 50W, and HF radios can go up to 100W without an amplifier, and 1000W with an amplifier.
The MeshCore uses dBm instead of W as a unit of power.
Very briefly, a decibel (dB) is a logarithmic scale used to compare two quantities:
| A is 10 dB over B | <=> | A is 10 times bigger than B |
| A is 20 dB over B | <=> | A is 100 times bigger than B |
| A is 30 dB over B | <=> | A is 1000 times bigger than B |
Do you see the pattern? If not, you can read more about the dB scale [[hambasics/sections/mathbasics |here]].
A dB**m** is "dB over 1 mW (milliwatt)". In other words, it tells you how many times more powerful than 1 mW your power is.
Here are a few values:
|<15em>|
| 1 dBm| ≈ | 1.3 mW|
| 2 dBm| ≈ | 1.6 mW|
| 3 dBm| ≈ | 2 mW|
| 4 dBm| ≈ | 2.5 mW|
| 5 dBm| ≈ | 3.2 mW|
| 6 dBm| ≈ | 4 mW|
| ... |||
| 10 dBm| = | 10 mW|
| 20 dBm| = | 100 mW|
| 30 dBm| = | 1 W|
Here's how to convert from dBm to mW. Let's use 22 dBm as an example (which is the maximum power of the //Wio Tracker L1 Pro// device):
* Divide 22 dBm by 10 = 2.2
* Take 10 to the power of 2.2 = 102.2 ≈ 158 mW
Converting from mW to dBm is a little harder because we need to use the log function. Let's convert 2.5 W to dBm.
* First, we need to convert 2.5 W into mW = 2500 mW
* Then we take the log of that: log2500 ≈ 3.4
* Finally, we multiply that by 10 = 34 dBm
===== Sunshine Coast Repeater Project =====
{{ :meshcore:meshcore_repeaters.jpg?500 }}
The MeshCore app has a very handy Antenna Coverage tool to model line-of-sight coverage. You can use it without having a device:
* Navigate to the [[https://app.meshcore.nz/ |web version of the MeshCore App]]
* You don't need to connect to an actual MeshCore device.
* Click on **⋮** in the top right corner and then select "''Tools''"
* Enter the "''Antenna Coverage''" tool
To import the locations that we've modelled:
* Where it says "''0 Coverage Layers''", click on **⋮** and select "''Import JSON''"
* Import this {{:meshcore:coverage_layers_2026-03-27-221828.json |json file}}
====== Copyright ======
This document is licensed under [[https://creativecommons.org/licenses/by-sa/4.0/ |CC BY-SA 4.0 International]]. The original can be found at https://scarcs/meshcore/home
====== Footnotes ======