Skip to content

Instantly share code, notes, and snippets.

@gregorg
Created March 14, 2016 10:36
Show Gist options
  • Save gregorg/8fb0904e7d7db9dbdd40 to your computer and use it in GitHub Desktop.
Save gregorg/8fb0904e7d7db9dbdd40 to your computer and use it in GitHub Desktop.
Upload KISS Firmware via dfu-util
#!/bin/bash
[ -z "$1" ] && { echo "Usage: $0 firmware.dfu"; exit 1; }
set -e
echo "==== UNLOCK EEPROM ===="
dfu-util --alt 0 -s 0x08000000:force:unprotect -D "$1"
sleep 10
echo
echo "==== UPLOAD NEW FIRMWARE ===="
dfu-util -R -a 0 -D "$1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment