diff --git a/docs/development/firmware/module-api.mdx b/docs/development/firmware/module-api.mdx index 9a90f744..67fba7a0 100644 --- a/docs/development/firmware/module-api.mdx +++ b/docs/development/firmware/module-api.mdx @@ -41,7 +41,7 @@ A number of [key services](http://github.com/meshtastic/firmware/tree/master/src - [TextMessageModule](http://github.com/meshtastic/firmware/tree/master/src/modules/TextMessageModule.h) - receives text messages and displays them on the LCD screen/stores them in the local DB - [NodeInfoModule](http://github.com/meshtastic/firmware/tree/master/src/modules/NodeInfoModule.h) - receives/sends User information to other nodes so that usernames are available in the databases -- [RemoteHardwareModule](http://github.com/meshtastic/firmware/tree/master/src/modules/RemoteHardwareModule.h) - a module that provides easy remote access to device hardware (for things like turning GPIOs on or off). Intended to be a more extensive example and provide a useful feature of its own. See [remote-hardware](/docs/software/device/remote-hardware-service) for details. +- [RemoteHardwareModule](http://github.com/meshtastic/firmware/tree/master/src/modules/RemoteHardwareModule.h) - a module that provides easy remote access to device hardware (for things like turning GPIOs on or off). Intended to be a more extensive example and provide a useful feature of its own. See [remote-hardware](/docs/hardware/peripheral/#remote-hardware) for details. - [ReplyModule](http://github.com/meshtastic/firmware/tree/master/src/modules/ReplyModule.h) - a simple module that just replies to any packet it receives (provides a 'ping' service). ## Getting started diff --git a/docs/hardware/peripheral/_category_.yml b/docs/hardware/peripheral/_category_.yml deleted file mode 100644 index 7098d00f..00000000 --- a/docs/hardware/peripheral/_category_.yml +++ /dev/null @@ -1,7 +0,0 @@ -label: Peripherals -collapsible: true -position: 2 -link: - type: generated-index - title: Peripherals - slug: peripherals \ No newline at end of file diff --git a/docs/hardware/peripheral/buttons/index.mdx b/docs/hardware/peripheral/buttons/index.mdx new file mode 100644 index 00000000..993aa195 --- /dev/null +++ b/docs/hardware/peripheral/buttons/index.mdx @@ -0,0 +1,16 @@ +--- +id: buttons +title: Buttons +sidebar_label: Buttons +sidebar_position: 3 +--- + +A number of devices have buttons that can be used to interact with the firmware. These buttons have a number of different functions: + +- Reset button - This is present on most devices. +- Power button - This is present on some devices. A long press powers the device off or turns it back on again. +- Program button - This is present of some devices and has a number of functions: + - Single press - This changes the page of information displayed on the screen. + - Double press - This sets the Bluetooth pairing code to `123456` (useful if you do not have a screen on the device). + - Long press - This adjusts the contrast of the screen. + - Long press during reboot - This turns on the software WiFi access point on devices that support WiFi. \ No newline at end of file diff --git a/docs/software/device/remote-hardware-service.mdx b/docs/hardware/peripheral/index.mdx similarity index 76% rename from docs/software/device/remote-hardware-service.mdx rename to docs/hardware/peripheral/index.mdx index 5578696d..ad484228 100644 --- a/docs/software/device/remote-hardware-service.mdx +++ b/docs/hardware/peripheral/index.mdx @@ -1,9 +1,26 @@ --- -id: remote-hardware-service -title: Remote Hardware Service -sidebar_label: Remote Hardware +id: peripherals +title: Peripherals +sidebar_label: Peripherals +sidebar_position: 2 --- +## Firmware Versions + +The device firmware runs on the nodes to build the mesh for communication. Each different make and model of device requires a different build of the Meshtastic firmware in order to run properly. Thankfully, due to the design of Meshtastic, it is possible to port the firmware to new devices as they become available. The firmware currently runs on a range of ESP32 based devices, but there is also increasing support for the nRF52 microprocessor with some more recent devices coming to market. + +The current firmware has support for a screen to display received messages, along with information about nodes on the mesh, and more detailed information about the device on which it is running. + +The latest firmware can be downloaded from the [Downloads](/downloads) page. If you wish to view the code or contribute to development of the firmware, please visit the device code GitHub page. + +:::info +Please be aware that there are significant changes between version branches 1.2.x and 1.3.x which mean that devices need to be running the same branch of firmware to be able to talk to each other. Python, Android, and other software applications will also need to be running the same branch to be able to talk to the device. +::: + + +## Remote Hardware + + :::warning GPIO access is fundamentally dangerous because invalid options can physically damage or destroy your hardware. Ensure that you fully understand the schematic for your particular device before trying this as we do not offer a warranty. Use at your own risk. ::: @@ -14,13 +31,13 @@ This feature uses a preinstalled module in the device code and associated comman You can get the latest python tool/library with `pip3 install --upgrade meshtastic` on Windows/Linux/OS-X. See the [python section](/docs/software/python/cli/installation) for more details. -## Supported operations in the initial release +### Supported operations in the initial release - Set any GPIO - Read any GPIO - Receive notification of changes in any GPIO -## Setup +### Setup To prevent access from untrusted users, you must first make a `gpio` channel that is used for authenticated access to this feature. You'll need to install this channel on both the local and remote node. @@ -43,7 +60,7 @@ If doing local testing, may want to change the speed of the channel at this time meshtastic --info ``` -4. Connect the remote device via USB (or use the [remote admin](device-remote-admin) feature to reach it through the mesh) +4. Connect the remote device via USB (or use the [remote admin](/docs/mesh/device-remote-admin) feature to reach it through the mesh) 5. Set it to join the gpio channel you created ```shell @@ -52,7 +69,7 @@ If doing local testing, may want to change the speed of the channel at this time Now both devices should be able to talk over the `gpio` channel. Send a text message from one the other other verify. Also run "--nodes" to verify the second node shows up. -## A little bit of information about masks +### A little bit of information about masks To determine the appropriate mask for the pin(s) that you want to know. The python program (and output) below might help: @@ -106,7 +123,7 @@ GPIO:43 mask:0x80000000000 GPIO:44 mask:0x100000000000 ``` -## How to easily test GPIO operations? +### How to easily test GPIO operations? You can add a simple LED and resistor to validate that the GPIO operations work as expected. Used the tutorial at https://www.instructables.com/Slide-Switch-With-Arduino-Uno-R3/ as a guide. @@ -131,11 +148,11 @@ By default, the pin may be "off" or "on". (It will most likely "off".) See the s [T-Lora v1 with LED on GPIO 21](/img/LED_on_TLoraV1.jpg) -## Doing GPIO operations +### Doing GPIO operations You can programmatically do operations from your own python code by using the Meshtastic `RemoteHardwareClient` class. See the [python API](/docs/software/python/cli/installation) documentation for more details. -## Using GPIOs from the python CLI +### Using GPIOs from the python CLI Writing a GPIO (ex: turn "on" GPIO4): diff --git a/docs/hardware/peripheral/screens/index.mdx b/docs/hardware/peripheral/screens/index.mdx new file mode 100644 index 00000000..44c4b668 --- /dev/null +++ b/docs/hardware/peripheral/screens/index.mdx @@ -0,0 +1,32 @@ +--- +id: screens +title: Screens +sidebar_label: Screens +sidebar_position: 2 +--- + +A number of devices have screens capable of displaying the messages received, information about the mesh, and other details. On powering the device it will display the Meshtastic splash screen with the version number for a couple of seconds: + +![Splash screen](/img/screen/mesh-splash.jpg) + +The screen is split up into pages, through which you can navigate using the program button as described above. The first page to be displayed will be the message screen where received messages are displayed along with the name of the node it came from. The devices will automatically switch to this page when a new message is received. + +![Message page](/img/screen/mesh-message.jpg) + +The next pages display information about the nodes that are currently on the mesh. This includes the distance and direction to that node, the signal strength, and the time last seen. + +![Node page](/img/screen/mesh-node1.jpg) ![Node page](/img/screen/mesh-node2.jpg) + +The next page shows information about the device, battery power, current / total nodes, number of GPS satellites seen, channel name, last digits of the MAC address, and a brief log including the names of the last nodes to join the mesh. + +![Channel page](/img/screen/mesh-channel.jpg) + +The final page shows current battery voltage and percent charge, as well as noting how long the device has been online and the current GPS time, and GPS location. + +![GPS page](/img/screen/mesh-gps.jpg) + +If the device WiFi has been enabled (only possible on ESP32 devices), another page appears displaying information about the WiFi settings, IP address, and number of devices connected to the WiFi. + +![WiFi page](/img/screen/mesh-wifi.jpg) + +With a further press of the program button, the screen will cycle round to the message page. \ No newline at end of file diff --git a/docs/software/device/critical-faults.mdx b/docs/mesh/device/critical-faults.mdx similarity index 97% rename from docs/software/device/critical-faults.mdx rename to docs/mesh/device/critical-faults.mdx index 054e9a67..4ee89f5b 100644 --- a/docs/software/device/critical-faults.mdx +++ b/docs/mesh/device/critical-faults.mdx @@ -1,7 +1,7 @@ --- id: critical-error-codes -title: Critical error codes -sidebar_label: Critical error codes +title: Critical Error Codes +sidebar_label: Error Codes --- The device might report these fault codes on the screen, but it will also be outputted on the device serial output. If you encounter a fault code, please post on the forum and we'll try to help. diff --git a/docs/software/device/remote-admin.mdx b/docs/mesh/remote-admin.mdx similarity index 99% rename from docs/software/device/remote-admin.mdx rename to docs/mesh/remote-admin.mdx index d0054713..53dc22ac 100644 --- a/docs/software/device/remote-admin.mdx +++ b/docs/mesh/remote-admin.mdx @@ -1,7 +1,7 @@ --- id: device-remote-admin -title: Remote node administration -sidebar_label: Remote node administration +title: Remote Node Administration +sidebar_label: Remote Nodes --- This feature will allow you to use the multiple channels feature to enable remote administration of Meshtastic nodes. This will let you talk through the mesh to some far away node and change that node's settings. This is an advanced feature that (currently) few users would need. Also, keep in mind it is possible (if you are not careful) to assign settings to that remote node that cause it to completely drop off of your mesh. We advise network admins have a test node to test settings with before applying changes to a remote node to prevent this. diff --git a/docs/software/device/Index.mdx b/docs/software/device/Index.mdx deleted file mode 100644 index 2bba1f02..00000000 --- a/docs/software/device/Index.mdx +++ /dev/null @@ -1,56 +0,0 @@ ---- -id: device-firmware -title: Device firmware -sidebar_label: Device firmware -sidebar_position: 3 ---- - -The device firmware runs on the nodes to build the mesh for communication. Each different make and model of device requires a different build of the Meshtastic firmware in order to run properly. Thankfully, due to the design of Meshtastic, it is possible to port the firmware to new devices as they become available. The firmware currently runs on a range of ESP32 based devices, but there is also increasing support for the nRF52 microprocessor with some more recent devices coming to market. - -The current firmware has support for a screen to display received messages, along with information about nodes on the mesh, and more detailed information about the device on which it is running. - -The latest firmware can be downloaded from the [Downloads](/downloads) page. If you wish to view the code or contribute to development of the firmware, please visit the device code GitHub page. - -:::info -Please be aware that there are significant changes between version branches 1.2.x and 1.3.x which mean that devices need to be running the same branch of firmware to be able to talk to each other. Python, Android, and other software applications will also need to be running the same branch to be able to talk to the device. -::: - -### Buttons - -A number of devices have buttons that can be used to interact with the firmware. These buttons have a number of different functions: - -- Reset button - This is present on most devices. -- Power button - This is present on some devices. A long press powers the device off or turns it back on again. -- Program button - This is present of some devices and has a number of functions: - - Single press - This changes the page of information displayed on the screen. - - Double press - This sets the Bluetooth pairing code to `123456` (useful if you do not have a screen on the device). - - Long press - This adjusts the contrast of the screen. - - Long press during reboot - This turns on the software WiFi access point on devices that support WiFi. - -### Screens - -A number of devices have screens capable of displaying the messages received, information about the mesh, and other details. On powering the device it will display the Meshtastic splash screen with the version number for a couple of seconds: - -![Splash screen](/img/screen/mesh-splash.jpg) - -The screen is split up into pages, through which you can navigate using the program button as described above. The first page to be displayed will be the message screen where received messages are displayed along with the name of the node it came from. The devices will automatically switch to this page when a new message is received. - -![Message page](/img/screen/mesh-message.jpg) - -The next pages display information about the nodes that are currently on the mesh. This includes the distance and direction to that node, the signal strength, and the time last seen. - -![Node page](/img/screen/mesh-node1.jpg) ![Node page](/img/screen/mesh-node2.jpg) - -The next page shows information about the device, battery power, current / total nodes, number of GPS satellites seen, channel name, last digits of the MAC address, and a brief log including the names of the last nodes to join the mesh. - -![Channel page](/img/screen/mesh-channel.jpg) - -The final page shows current battery voltage and percent charge, as well as noting how long the device has been online and the current GPS time, and GPS location. - -![GPS page](/img/screen/mesh-gps.jpg) - -If the device WiFi has been enabled (only possible on ESP32 devices), another page appears displaying information about the WiFi settings, IP address, and number of devices connected to the WiFi. - -![WiFi page](/img/screen/mesh-wifi.jpg) - -With a further press of the program button, the screen will cycle round to the message page. diff --git a/docusaurus.config.js b/docusaurus.config.js index d8c8f4da..3a9427e5 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -38,10 +38,6 @@ const config = { label: 'Docs', to: 'docs/introduction', }, - { - label: 'Config', - to: 'docs/device', - }, { label: 'Downloads', to: 'downloads', @@ -50,6 +46,10 @@ const config = { label: 'About', position: 'right', items: [ + { + label: 'Introduction', + to: 'docs/introduction', + }, { label: 'Getting Started', to: 'docs/getting-started',