The Luckfox Pico Mini is a compact and power efficient (~0.25w) Linux capable board, ideal for running TC2 Meshtastic BBS (or anything else).
Advantages:
- Tiny size (~28x21mm)
- Power efficiency (~0.25w)
- Full Linux CLI (Ubuntu, Buildroot, Alpine)
- USB host support
- Cheap - $7-8 on Waveshare (also available on Amazon)! Get the A model - the B just has added flash storage that’s too small for our purposes.
Disadvantages:
- By default, no simple way to get online (no built in wifi/BLE/ethernet). Ethernet can be easily added - wifi still work in progress - see Networking below)
- Annoying SDK for building firmware images
- No simple way to compile drivers (no available Linux headers - if anyone manages to compile the headers, please let me know)
- If the power draw of a USB peripheral exceeds what the Luckfox is able to provide, it will reboot, bootloop or even hard crash. This appears to be avoidable by simply using a sufficient power supply, though this requires more testing
Accomplished:
- Ethernet over USB (see supported hardware below)
- Ethernet over pins (see Networking below and wiring diagram at bottom of page)
- UART communications with Meshtastic nodes (2 pin pairs)
- USB serial communications with Meshtastic nodes (see supported hardware below)
- Meshtastic native client controlling a LoRa radio (see supported hardware below)
- USB mass storage
- Real time clock (RTC) support (see supported hardware below)
- Activity LED disabled. User LED will blink for 5 seconds when boot is complete
- Pressing the “BOOT” button triggers reboot
- Ability to reconfigure wifi via USB flash drive
- WIFI over USB or UART (stable, optimizing)
- Meshtasticd to run LoRa radio over SPI (accomplished, updated image and instructions coming soon)
- Allow editing of config files by plugging in thumb drive
Issues / to do / in progress:
- Custom carrier PCB with LoRa radio (in progress)
- Ability to activate or deactivate WIFI via Meshtastic admin (accomplished, refining)
- Prevent hanging on boot when no network ("[ ***] A start job is running for Raise network interfaces (2min 10s / 5min 6s"). Also, on reboot
- Test power consumption with LoRa radio attached / figure out what size solar panel will be required - preliminarily, 0.36-0.45w average
- Work out i2c sharing between OS and Meshtasticd - allow mesh to access sensors while RTC is accessible to OS
- Test lowering CPU frequency - see if reduces total power consumption. Presumption is that it will not make a difference
Project goals:
- A solar-deployable Meshtastic node running Linux, without needing a giant solar panel / battery
- Wifi capabilities (with ability to disable/enable wifi via mesh for power savings)
- A ‘fresh’ image with no changes but with the added drivers for usb ethernet, wifi, serial, RTC and mass storage.
- An image preconfigured with the TC2-BBS for comms over UART4.
- An image preconfigured with the TC2-BBS for comms over USB. This assumes the USB device is recognized as /dev/ttyACM0.
Login for the “fresh” image is root:root
or pico:luckfox
. Login for the configured BBS images is root:root
, bbs:mesh
or femto:fox
.
The preconfigured images will reboot every 24 hours, and restart the BBS every other hour. In theory, this should happen at 7am UTC (because both the US and Europe are generally inactive at that time). Time is set on boot with the following logic:
- If the system recognizes an RTC module connected via i2c, it will use that.
- If no RTC module is recognized, time will be set to midnight 2024-1-1 midnight.
- If network is available, time will be retrieved from google and system time (and RTC time if present) will be set from that.
Reboot timing is set in crontab
. Time logic is in /etc/rc.local
.
There are four methods to get online:
- Ethernet over USB - most adapters should be supported, but I’ve only tested the RTL8152 chipset.
- Preconfigured Ubuntu images: ethernet via the castellated pins at the bottom of the board. See pinout at the bottom of this readme. Note that the MAC address for onboard ethernet is hardcoded to 1a:cf:50:33:5f:92 - if you need to change this,
sudo nano /etc/network/interfaces
. - USB wifi - still a work in progress, but working with a couple different chipsets so far. Note we’re using wpa_supplicant, as networkmanager (nmcli) caused hard crashes.
- RDNIS via usb - see this guide. Note that in the preconfigured images USB is set to host mode, so you’ll have to switch back to peripheral with
sudo luckfox-config
. This is not really recommended, but can be used in a pinch.
Choosing a MicroSD card: Any reasonably fast MicroSD card of 32gb or higher should work, but ideally use a card that supports UHS-1 or higher, and is rated for high endurance.
- Uncompress the 7z file - will require ~29gb of space. In Windows, use 7-zip.
- Flash the image your MicroSD card using Balena Etcher or your favorite flashing program. You will likely get a warning that the image appears to be invalid or has no partition table. This is normal.
- Insert the microSD card into the Pico Mini.
- Connect Pico Mini to Meshtastic radio via pins or USB, depending on image flashed. If using pins - use pins 10 and 11 on the Luckfox board.
- For the rak19007 or rak19003 (with the rak4631/rak4630 daughter board):
- In Position settings, set
GPS: NOT_PRESENT
. The Rak does not support GPS and UART simultaneously at this time. - If using UART comms, Serial Module settings:
Serial: Enabled
Echo: off
RX: 15
(rak19007 and rak19003 with TX1/RX1),19
(rak19003 with TX0/RX0)TX: 16
(rak19007 and rak19003 with TX1/RX1),20
(rak19003 with TX0/RX0)Serial baud rate: 115200
Timeout: 0
Serial mode: PROTO
Override console serial port: off
- In Position settings, set
- Remember - connect TX on the Luckfox to RX on the Meshtastic board, and vice-versa.
- Power can be supplied to the RAK board via the 3.3v out pin on the Luckfox.
- If communications is via UART, you must bridge the grounds of the two boards.
- Supply power to the Luckfox via pins or USB.
- It should Just Work.
- You can connect to the Luckfox via ethernet or UART serial as described here.
Pin # | Pin ID | Function | Luckfox | Pin # | Pin ID | Function |
---|---|---|---|---|---|---|
1 | VBus | 5V in/out | 22 | 1V8 | 1.8V out | |
2 | GND | 21 | GND | |||
3 | 3V3 | 3.3V out | 20 | 4C1 | 1v8 IO, SARADC | |
4/42 | 1B2 | Debug UART2-TX | 19 | 4C0 | 1v8 IO, SARADC | |
5/43 | 1B3 | Debug UART2-RX | 18/4 | 0A4 | 3v3 IO | |
6/48 | 1C0 | CS0, IO | 17/55 | 1C7 | IRQ, IO | |
7/49 | 1C1 | CLK, IO | 16/54 | 1C6 | BUSY, IO | |
8/50 | 1C2 | MOSI, IO | 15/59 | 1D3 | i2c SCL | |
9/51 | 1C3 | MISO, IO | 14/58 | 1D2 | i2c SDA | |
10/52 | 1C4 | UART4-TX | 13/57 | 1D1 | UART3-RX, NRST | |
11/53 | 1C5 | UART4-RX | 12/56 | 1D0 | UART3-TX, RXEN |
Pin ID explanation: 1C6 = GPIO bank 1, group C, pin 6.
In Meshtasticd’s config.yaml we use GPIO bank 1, and subtract 32 from the pin number.
Note
The information on this page is given without warranty or guarantee. Links to vendors of products are for informational purposes only.
Meshtastic® is a registered trademark of Meshtastic LLC. Meshtastic software components are released under various licenses, see GitHub for details. No warranty is provided - use at your own risk.