usb_config.md updated from https://stackedit.io/

This commit is contained in:
noon92 2025-01-25 02:10:47 +02:00
parent eb94549de2
commit 63a7b9d3ea

View file

@ -1,15 +1,16 @@
## USB Configuration Tool
To configure some Femtofox settings such as wifi, you can insert a USB flash drive containing a configuration file. On boot, the system will automatically recognize, mount and implement the settings you specify. The tool can also be run from the `femto-config` tool, in the `Utilities` menu.
Configurable settings are:
- Wifi SSID
- Wifi PSK (password)
- Wifi country
- Timezone
- Activity LED (blinky light - disable for minor power savings)
- Meshtastic:
- LoRa radio model
- Wifi PSK (password)
- Wifi country
- Timezone
- Activity LED (blinky light - disable for minor power savings)
- Meshtastic:
- LoRa radio model
- [URL](https://meshtastic.org/docs/software/python/cli/#--seturl-seturl) (used to configure LoRa settings and channels)
- Security: public key
- Security: private key
@ -20,7 +21,7 @@ Configurable settings are:
### Instructions
The USB drive must be formatted with a single FAT32, exFAT, NTFS (read only - log will not be saved to drive) or ext4 partition. Add a file named `femtofox-config.txt` and whichever settings you would like to change (CaSe sEnSiTiVe).
&emsp;&emsp;&emsp;&emsp;     **<a href download="assets/femtofox-config.txt">[Get an example USB configuration file here](assets/femtofox-config.txt)
     <a href download="assets/femtofox-config.txt">[Get an example USB configuration file here](assets/femtofox-config.txt)
```
wifi_ssid="Your SSID name"
wifi_psk="wifipassword"
@ -37,15 +38,15 @@ dont_run_if_log_exists="true"
```
> [!NOTE]
> Enter as many or as few settings as you like.
>
>
> For `wifi_country`, insert your country's [ISO/IEC alpha2 two letter country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements) (such as US, GB, DE, IN, etc.) in capital letters.
>
>
> Use a timezone as it appears in [the tz database](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
>
> &emsp;&emsp;  **Meshtastic**
>   **Meshtastic**
> For `meshtastic_lora_radio`, choose your radio from the supported hardware list.
> Options are:
> `ebyte-e22-900m30s`
> `ebyte-e22-900m30s`
> `ebyte-e22-900m22s`
> `ebyte-e80-900m22s` (experimental)
> - `heltec-ht-ra62`
@ -68,18 +69,15 @@ A log (`femtofox-config.log`) is saved to `/home/femto` and the USB drive (excep
### Boot codes
When the Femtofox is finished booting, it will blink its User LED (see below) in a pattern which can be used to gather info on its status or help diagnose issues.
![LEDs](assets/images/leds.png)
| LED blink pattern li>Invalid filesystem<li>Corrupted partition table<li>Defective USB drive<li>Defective USB OTG adapter | Failed to mount USB drive. Ignoring.| <li>Invalid filesystem<li>Corrupted partition table<li>Defective USB drive<li>Defective USB OTG adaptercenter>⚠️center>⚠️<br><br><br>1 very long blink, lasting 5 seconds | <li>Use a supported partition (FAT32, exFAT, NTFS, ext4)<li>Repair partition table<li>Try another USB drive<li>Try another USB OTG adapter |
| <p align="|
|<center">⚠️<br>**───&nbsp;\_\_\_\_\_&nbsp;&nbsp;───**\_\_\_\_\_<br>2 long blinks, each lasting .5 seconds | femtofox-config.txt is configured to skip if log exists. | USB drive mounted successfully but femtofox-config.txt contains `dont_run_if_log_exists="true"` and a log is present on the USB drive. Ignoring. | Remove log from USB driver><li>Remove `dont_run_if_log_exists` line from femtofox-config.txt |
| <p align="|
|<center">⚠️<br>**───\_\_\_\_\_&nbsp;&nbsp;&nbsp;───&nbsp;\_\_\_\_\_&nbsp;&nbsp;───**\_\_\_\_\_<br>3 long blinks, each lasting 1.5 seconds | USB drive mounted successfully but femtofox-config.txt was not found. Ignoring. | Config file missing. | Create configuration file as described above. |
| <p align="| Config file missing. | Create configuration file as described above. |
|<center">⚠️<br>**───\_\_\_\_\_&nbsp;&nbsp;\_\_\_\_\_&nbsp;───&nbsp;\_\_\_\_\_&nbsp;&nbsp;───\_\_\_\_\_&nbsp;&nbsp;&nbsp;───&nbsp;&nbsp;&nbsp;───**\_\_\_\_\_<br>5 long blinks, each lasting 1.5 seconds | USB drive mounted successfully and femtofox-config.txt was found but did not contain readable configuration data. Ignoring. | Configuration file improperly formatted or contains no data. | | Check configuration file contents as described above. |
| <p align="| Configuration file improperly formatted or contains no data. | Check configuration file contents as described above.|
|center">⚠️<br>**──\_\_\_&nbsp;&nbsp;\_\_\_&nbsp;&nbsp;\_n&nbsp;&nbsp;\_&nbsp;──&nbsp;\_\_\_&nbsp;&nbsp;-\_\_\_&nbsp;&nbsp;\_&nbsp;-**&nbsp;\_<br>2 longcenter>⚠️<br>nbspnbsnbspnspnbspnbspnbspnbsp<br> long blinks, each lasting 1 second, then 2 short blinks, each lasting 1/4 of a second. Repeats twice | Error while trying to implement a Meshtastic setting after 3 attempts. Some settings may have been implemented successfully. | <li>The error may be transient.<>Configuration file may contain improper data. | <li>Try again.<>Check configuration file contents as described above.<>Check the log.<br>This pattern may flash before other patterns. The pattern will repeat once for each failed setting. |
| <p align="<center">✅<br>**. . . . . . . . . .**<br>10 very fast blinks, each lasting 1/8th of a second</br> | USB drive mounted successfully, and femtofox-config.txt was found and contained configuration data which was sent for deployment. Any affected services will now restart. You can disconnect the USB drive. | This does not mean that the information in the config file is correct - only that it was readable.<br>Note that the "success" boot code will flash if at least one setting is successfully read - even if the setting was not implemented successfully. | |
| <p align="|
|<center">✅<br>**─\_\_&nbsp;&nbsp;\_\_&nbsp;─&nbsp;\_\_&nbsp;&nbsp;─&nbsp;&nbsp;&nbsp;─&nbsp;&nbsp;&nbsp;─**<br>5 medium blinks, each lasting 0.5 seconds | Boot complete. Appears on every successful boot and always appears last. | | |
| LED blink pattern ai ilessoution | Failed to mount USB drive. Ignoring.| Invalid filesystem<>Corrupted partition table<>Defective USB drive<>Defective USB OTG adapter | Use a supported partition (FAT32, exFAT, NTFS, ext4)<>Repair partition table<>Try another USB drive<>Try another USB OTG adapter |
| <center>⚠️<br>**_\_\__**\_<br>2 long blinks, each lasting .5 seconds | femtofox-config.txt is configured to skip if log exists. | USB drive mounted successfully but femtofox-config.txt contains `dont_run_if_log_exists="true"` and a log is present on the USB drive. Ignoring. | Remove log from USB driveremove `dont_run_if_log_exists` line from femtofox-config.txt |
|<center>⚠️<br>**_\_\__**\_\___\_<br>3 long blinks, each lasting 1.5 seconds | USB drive mounted successfully but femtofox-config.txt was not found. Ignoring. | Config file missing. | Create configuration file as described above. || <center>⚠️<br>\__\_\__\_\__\_\__**\_\___\_<br>5 long blinks, each lasting 1.5 seconds | USB drive mounted successfully and femtofox-config.txt was found but did not contain readable configuration data. Ignoring. | Configuration file improperly formatted or contains no data. | Check configuration file contents as described above. |
| <center>⚠️<br>\__\_\__\_\_\_\__\_\__\_\_\_<br>2 long blinks, each lasting 1 second, then 2 short blinks, each lasting 1/4 of a second. Repeats twice | Error while trying to implement a Meshtastic setting after 3 attempts. Some settings may have been implemented successfully. | The error may be transient.<>Configuration file may contain improper data. | Try again.<>Check configuration file contents as described above.<>Check the log.<br>This pattern may flash before other patterns. The pattern will repeat once for each failed setting. |
| <center>✅<br>. . . . . . . . . .<br>10 very fast blinks, each lasting 1/8th of a second</r> | USB drive mounted successfully, and femtofox-config.txt was found and contained configuration data which was sent for deployment. Any affected services will now restart. You can disconnect the USB drive. | This does not mean that the information in the config file is correct - only that it was readable.<br>Note that the "success" boot code will flash if at least one setting is successfully read - even if the setting was not implemented successfully. | |
|<center>✅<br>\_\_\_\_\_\_<br>5 medium blinks, each lasting 0.5 seconds | Boot complete. Appears on every successful boot and always appears last. | | \_\_&nbsp;&nbsp;\_\_<br>5 medium blinks, each lasting 0.5 seconds | Boot complete. Appears on every successful boot and always appears last.| | |
> \[!NOTE\]
> Boot codes can appear in sequence - for example: one long (4 second) blink, followed by 5 medium (half second) blinks means the USB drive failed to mount, and that the boot sequence is complete.
<!--stackedit_data:
eyJoaXN0b3J5IjpbLTE2NDk0Mjc0NzhdfQ==
-->