33 lines
665 B
Bash
Executable File
33 lines
665 B
Bash
Executable File
#!/bin/bash
|
|
# Need to be in root dir of jebbatime git archive.
|
|
# Get config
|
|
. ~/.config/jebbatime.conf
|
|
|
|
cd $JEBBATIMEGITROOT
|
|
|
|
# Reboot thang into bootloader
|
|
echo "Rebooting development PineTime watch into bootloader..."
|
|
./tools/wasptool \
|
|
--verbose \
|
|
--bootloader \
|
|
--device $JEBBATIMEDEVMAC
|
|
|
|
echo "Waiting..."
|
|
sleep 4
|
|
|
|
# Flash
|
|
echo "Flashing, will take ~5 minutes..."
|
|
# Use image in build dir
|
|
./tools/ota-dfu/dfu.py \
|
|
--legacy \
|
|
--verbose \
|
|
--address=$JEBBATIMEDEVDFUMAC \
|
|
--zip=build-pinetime/micropython.zip
|
|
|
|
sleep 1
|
|
echo "Setting time on watch"
|
|
./tools/wasptool \
|
|
--rtc \
|
|
--device $JEBBATIMEDEVMAC
|
|
|