mirror of
https://github.com/tjhorner/upsy-desky.git
synced 2026-01-09 15:37:54 -05:00
13 lines
406 B
Bash
Executable File
13 lines
406 B
Bash
Executable File
#!/bin/bash
|
|
|
|
MAC_ADDR=$(esptool.py --chip esp32 read_mac | sed -En "s/MAC: (.*)/\1/p" | uniq | sed 's/://g')
|
|
esphome upload --device /dev/cu.usbserial* ../firmware/stock.yaml
|
|
|
|
if ! command -v cp210x-cfg &> /dev/null
|
|
then
|
|
# Get cp210x-cfg from https://github.com/DiUS/cp210x-cfg
|
|
echo "cp210x-cfg was not found; CP2102 will not be serialized or renamed"
|
|
else
|
|
cp210x-cfg -N "Upsy Desky" -S $MAC_ADDR
|
|
fi
|