From 2a2683b3515b07053a86488cb796dd02478c28d5 Mon Sep 17 00:00:00 2001 From: Foster Irwin Date: Mon, 12 Apr 2021 15:42:07 -0600 Subject: [PATCH] split methods of firmware installation --- .../docs/getting_started/flashing_firmware.md | 6 -- .../flashing_firmware_cli.md | 72 +++++++++++++++++++ .../flashing_firmware_gui.md | 19 +++++ .../flashing_firmware_ota.md | 6 ++ .../flashing_firmware_overview.md | 27 +++++++ website/sidebars.js | 13 +++- 6 files changed, 135 insertions(+), 8 deletions(-) delete mode 100644 website/docs/getting_started/flashing_firmware.md create mode 100644 website/docs/getting_started/flashing_firmware/flashing_firmware_cli.md create mode 100644 website/docs/getting_started/flashing_firmware/flashing_firmware_gui.md create mode 100644 website/docs/getting_started/flashing_firmware/flashing_firmware_ota.md create mode 100644 website/docs/getting_started/flashing_firmware/flashing_firmware_overview.md diff --git a/website/docs/getting_started/flashing_firmware.md b/website/docs/getting_started/flashing_firmware.md deleted file mode 100644 index ea2ccf4d..00000000 --- a/website/docs/getting_started/flashing_firmware.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -id: flashing_firmware -title: Flashing Firmware -sidebar_label: Flashing -slug: /getting_started/flashing_firmware ---- diff --git a/website/docs/getting_started/flashing_firmware/flashing_firmware_cli.md b/website/docs/getting_started/flashing_firmware/flashing_firmware_cli.md new file mode 100644 index 00000000..cc34c55f --- /dev/null +++ b/website/docs/getting_started/flashing_firmware/flashing_firmware_cli.md @@ -0,0 +1,72 @@ +--- +id: flashing_firmware_cli +title: Flashing Firmware – CLI +sidebar_label: Command Line Interface +slug: /flashing_firmware_cli +--- +## Linux + +Requires `Python` and `pip` + +1. Download and unzip the latest Meshtastic firmware [release](https://github.com/meshtastic/Meshtastic-esp32/releases). +2. `pip install --upgrade esptool` - Installs esptool on your machine +3. Connect your radio to your USB port +4. `esptool.py chip_id` - Confirm that your device is talking to your PC by running +You should see something like: +``` +mydir$ esptool.py chip_id +esptool.py v2.6 +Found 2 serial ports +Serial port /dev/ttyUSB0 +Connecting.... +Detecting chip type... ESP32 +Chip is ESP32D0WDQ6 (revision 1) +Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None +MAC: 24:6f:28:b5:36:71 +Uploading stub... +Running stub... +Stub running... +Warning: ESP32 has no Chip ID. Reading MAC instead. +MAC: 24:6f:28:b5:36:71 +Hard resetting via RTS pin... +``` +5. `cd` into the directory where you unzipped the latest release. +6. Install the correct firmware for your board with `device-install.sh -f firmware-BOARD-VERSION.bin` +``` +./device-install.sh -f firmware-heltec-1.2.x.bin +``` +7. To update a the firmware on an existing Meshtastic device, run `device-update.sh -f firmware-BOARD-VERSION.bin` +``` +./device-update.sh -f firmware-heltec-1.2.x.bin +``` + + + +## MacOS + +Installing on OS X through the commandline uses the same method as linux, but requires a slightly different method to install Python, pip and esptool. + +OS X (10.15.3/Catalina) comes with Python 2.7 installed, but not pip. + +:::note +If you don't know if Homebrew is installed on your Mac, open terminal and enter the command `brew -v` if it doesn't work [install Homebrew](https://brew.sh) before continuing. +::: + +1. `brew install pyenv` - Installs PyEnv +2. `pyenv install 3.7.7` - To install and select Python 3.7.7 +3. `pyenv global 3.7.7` - Selects the new version of Python +4. `brew install pip` - Installs pip3 +5. `pip3 install --upgrade esptool` - Installs esptool + +You may need to install a driver from Silicon Labs for the [CP210X USB to UART bridge](https://www.silabs.com/products/development-tools/software/usb-to-uart-bridge-vcp-drivers) + +6. Now install as per installing on the Linux commandline. Replace `pip` with `pip3` in your commands. + +## Windows + +Requires `Python`, `pip`, `Gitbash` + +1. Download and install [Python](https://www.python.org/) +2. If you have a recent version of Python, pip should be installed by default. Check using the command `py -m pip --version`. This will display the installed version of pip. If it returns an error, you will need to [install pip](https://pip.pypa.io/en/stable/installing/). +3. Download and install [Gitbash](https://gitforwindows.org/) (or other appropriate shell) +4. Run `gitbash` and complete the installation as per the instructions for linux commandline. diff --git a/website/docs/getting_started/flashing_firmware/flashing_firmware_gui.md b/website/docs/getting_started/flashing_firmware/flashing_firmware_gui.md new file mode 100644 index 00000000..91697263 --- /dev/null +++ b/website/docs/getting_started/flashing_firmware/flashing_firmware_gui.md @@ -0,0 +1,19 @@ +--- +id: flashing_firmware_gui +title: Flashing Firmware – GUI +sidebar_label: Graphic User Interface +slug: /flashing_firmware_gui +--- +### Windows & MacOS + +1. Download and unzip the latest Meshtastic firmware [release](https://github.com/meshtastic/meshtastic-device/releases/latest). +2. Download [ESPHome Flasher](https://github.com/esphome/esphome-flasher) following their installation instructions. +3. Connect your radio to your USB port and open ESPHome Flasher. +4. If your board is not showing under Serial Port then you likely need to install the drivers for the CP210X serial chip. In Windows you can check by searching “Device Manager” and ensuring the device is shown under “Ports”. +5. If there is an error, download the [drivers](https://www.silabs.com/products/development-tools/software/usb-to-uart-bridge-vcp-drivers), then unzip and run the Installer application. +6. In ESPHome Flasher, refresh the serial ports and select the port to which your board is connected. +7. Browse to the previously downloaded firmware and select the correct firmware based on the board type. +8. Select Flash ESP. +9. Once complete, “Done! Flashing is complete!” will be shown. +10. The board will boot and show the Meshtastic logo. +11. Debug messages sent from the Meshtastic device can be viewed with a terminal program such as PuTTY. Within PuTTY, click “Serial”, enter the “Serial line” com port (can be found at step 4), enter “Speed” as `921600`, then click “Open”. diff --git a/website/docs/getting_started/flashing_firmware/flashing_firmware_ota.md b/website/docs/getting_started/flashing_firmware/flashing_firmware_ota.md new file mode 100644 index 00000000..c85ed00c --- /dev/null +++ b/website/docs/getting_started/flashing_firmware/flashing_firmware_ota.md @@ -0,0 +1,6 @@ +--- +id: flashing_firmware_ota +title: Flashing Firmware – OTA +sidebar_label: Over The Air +slug: /flashing_firmware_ota +--- diff --git a/website/docs/getting_started/flashing_firmware/flashing_firmware_overview.md b/website/docs/getting_started/flashing_firmware/flashing_firmware_overview.md new file mode 100644 index 00000000..53b3b697 --- /dev/null +++ b/website/docs/getting_started/flashing_firmware/flashing_firmware_overview.md @@ -0,0 +1,27 @@ +--- +id: flashing_firmware_overview +title: Overview +sidebar_label: Overview +slug: /flashing_firmware_overview +--- +## Download Firmware + +Prebuilt binaries for the supported radios are available in our releases. Your initial installation has to happen over USB from your Mac, Windows or Linux PC. Once our software is installed, all future software updates happen over bluetooth from your phone. + +:::caution +Be very careful to install the correct load for your board. In particular the popular 'T-BEAM' radio from TTGO is not called 'TTGO-Lora' (that is a different board). So don't install the 'TTGO-Lora' build on a TBEAM, it won't work correctly. +::: + + + +| [Current Firmware](https://github.com/meshtastic/meshtastic-device/releases/latest) | [List of Firmware Versions](https://github.com/meshtastic/meshtastic-device/releases/) | +| :--------------: | :-----------------------: | + +Firmware Flashing Methods +- [Command line interface](flashing_firmware_cli) +- [Graphic user interface](flashing_firmware_gui) +- [Over the air](flashing_firmware_ota) + +## Troubleshooting + +For any issues during setup, search [our forum](https://meshtastic.discourse.group) to find a solution. If you can't find one, please post your problem, providing as much detail as possible. diff --git a/website/sidebars.js b/website/sidebars.js index a621f929..1813b0b8 100644 --- a/website/sidebars.js +++ b/website/sidebars.js @@ -3,9 +3,13 @@ module.exports = { "Getting Started": [ "getting_started/about", "getting_started/overview", - "getting_started/flashing_firmware", - "getting_started/concepts", { + "Flashing Firmware": [ + "getting_started/flashing_firmware/flashing_firmware_overview", + "getting_started/flashing_firmware/flashing_firmware_cli", + "getting_started/flashing_firmware/flashing_firmware_gui", + "getting_started/flashing_firmware/flashing_firmware_ota", + ], "Howto's": [], }, "getting_started/concepts", @@ -80,4 +84,9 @@ module.exports = { }, ], }, + Showcase: { + "Jungle Project": [ + "software/other/mesh-alg", + ] + }, };