Skip to content

microrack/micron-fw

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

micron-fw

Instructions for flashing the device and using helper scripts.

Requirements

  • PlatformIO Core (pio)
  • ping (usually already available in the system)
  • nc / netcat for reading logs over TCP

Check:

pio --version
nc -h

PlatformIO Configurations

The following environments are configured in platformio.ini:

  • usb - flash over USB
  • ota - flash over OTA (upload_protocol = espota)

Flashing Over USB

  1. Connect the device over USB.
  2. Verify that PlatformIO can see the port:
pio device list
  1. Upload the firmware:
pio run -e usb -t upload

Flashing Over OTA

If the device is reachable on the network (known IP), you can flash without USB:

pio run -e ota -t upload --upload-port <ip-address>

Example:

pio run -e ota -t upload --upload-port 192.168.1.42

Scripts

start_log.sh

Connects to the device over TCP (via nc) and shows logs.

Usage:

./start_log.sh <ip-or-hostname> [port]
  • <ip-or-hostname> - device address
  • [port] - log port (default: 2323)

What the script does:

  1. Waits until the device starts replying to ping
  2. Then connects to the log port via nc

Examples:

./start_log.sh 192.168.1.42
./start_log.sh micron.local 2323

upload_ota_and_log.sh

Flashes the device over OTA and immediately opens logs.

Usage:

./upload_ota_and_log.sh <ip-address>

What the script does:

  1. Starts OTA flashing: pio run -e ota -t upload --upload-port "<ip-address>"
  2. If flashing succeeds, runs: ./start_log.sh "<ip-address>"

Example:

./upload_ota_and_log.sh 192.168.1.42

Quick Workflow

Typical Wi-Fi development loop:

./upload_ota_and_log.sh 192.168.1.42

If OTA is unavailable, flash over USB:

pio run -e usb -t upload

Common Issues

  • pio: command not found
    PlatformIO is not installed or not added to PATH.

  • nc: command not found
    Install netcat (nc).

  • OTA upload fails
    Check that the device and computer are on the same network and the IP is correct.

  • Log does not open on 2323
    Verify the port and pass it as the second argument to start_log.sh.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors