summaryrefslogtreecommitdiffstats
path: root/scripts/canon-a1100-image
blob: 17fd47373e88ab0ea382f2840e9cd5e7b42a1ba1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/usr/bin/env bash

set -e

IFILE=$1
OFILE=$2

dd if=/dev/zero bs=4M count=1 of=$OFILE 2>/dev/null
dd if=$IFILE of=$OFILE conv=notrunc 2>/dev/null

# 0xffff0000:  fe 3f f0 ea     b       0xffc00000
echo -n -e "\xfe\x3f\xf0\xea" | dd of=$OFILE bs=64K seek=63 conv=notrunc 2>/dev/null