summaryrefslogtreecommitdiff
path: root/openpicc/at91flash
diff options
context:
space:
mode:
authorhenryk <henryk@6dc7ffe9-61d6-0310-9af1-9938baff3ed1>2007-11-06 20:26:48 +0000
committerhenryk <henryk@6dc7ffe9-61d6-0310-9af1-9938baff3ed1>2007-11-06 20:26:48 +0000
commit633c646ab36368caf6eaeedd326d9f1835196afd (patch)
treefdd0f60747745d3e528c0f5d8f8895b26fb79633 /openpicc/at91flash
parent3b41196cb6b64cf6ba8ba41d6995428f73d4764a (diff)
Initial import of FreeRTOS code for OpenPICC
git-svn-id: https://svn.openpcd.org:2342/trunk@311 6dc7ffe9-61d6-0310-9af1-9938baff3ed1
Diffstat (limited to 'openpicc/at91flash')
-rwxr-xr-xopenpicc/at91flash27
1 files changed, 27 insertions, 0 deletions
diff --git a/openpicc/at91flash b/openpicc/at91flash
new file mode 100755
index 0000000..9733ddb
--- /dev/null
+++ b/openpicc/at91flash
@@ -0,0 +1,27 @@
+#!/bin/bash
+# (C) Milosch Meriac <meriac@bitmanufaktur.de> 2006
+
+UART='/dev/ttyUSB1'
+SAM7='/usr/local/bin/sam7'
+
+if [[ -a $1 ]]; then
+
+ echo "1. please unplug the USB cable and insert the SAM-BA jumper (Pin 1+2)"
+ echo "2. attach the USB cable"
+ echo "3. wait ten seconds"
+ echo "4. unplug the USB cable"
+ echo "5. remove the SAM-BA jumper"
+ echo "6. attach the USB cable"
+ echo "7. wait several seconds to allow the device to be detected by Linux"
+ echo "8. press [ENTER] to start flashing"
+ read
+ echo -e "9. flashing '$1'...\n"
+ $SAM7 -l $UART << ENDOFMYTEXT
+set_clock
+unlock_regions
+flash $1
+ENDOFMYTEXT
+ echo '10. done!'
+else
+ echo "can't open flash image file '$1'"
+fi \ No newline at end of file
personal git repositories of Harald Welte. Your mileage may vary