init
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| init [2011/12/21 20:01] – sec | init [2013/07/31 21:28] (current) – Change according to Sven Neuhaus sec | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== | + | ====== |
| - | This procedure brings your r0ket back into shape in case it is not working. | ||
| - | Use this procedure also if you are installing the 28c3 firmware | + | |
| + | ====== How to flash your r0ket? ====== | ||
| + | |||
| + | <note tip> | ||
| + | |||
| + | This procedure also brings your r0ket back into shape in case you " | ||
| + | |||
| + | ^Revision^Change^ | ||
| + | | 1 | Initial | | ||
| + | | 2 | Improved Mesh | | ||
| + | | 3 | Improved r_player l0dable | | ||
| + | | 4 | Improved fahrplan, mesh, fonts | | ||
| + | | 5 | Fixed mesh | | ||
| + | | 6 | Actually pushed | ||
| + | | 15 | numerous small bugfixes | | ||
| ===== Linux ===== | ===== Linux ===== | ||
| - | - Turn r0ket off (switch position | + | |
| - | - Plug micro-USB cable into r0ket and Computer | + | - Unpack the archive with your favourite tool. |
| - | - Hold joystick to the left | + | |
| - | - Turn r0ket on (switch position | + | - Plug micro-USB cable into r0ket and Computer. |
| - | - Release joystick | + | - Hold joystick to the left. |
| + | - Turn r0ket on (switch position | ||
| + | - Release joystick. | ||
| - Wait about 30 seconds. | - Wait about 30 seconds. | ||
| - | - Write firmware.bin to r0ket | + | - The r0ket will pose as a thumb drive. Check that you have a new volume with a 'firmware.bin' file on it. Mount the r0ket if you don' |
| - | * If any automounter is running | + | - As a normal user run the following command in a command window: |
| - | * dd if=firmware.bin of="/ | + | - cd r0ket-firmware-28c3-r6 && |
| - | * If you don' | + | - The script should tell you, that everything went fine. |
| - | * dd if=firmware.bin bs=512 seek=4 of=/dev/sdX | + | |
| - Turn r0ket off. | - Turn r0ket off. | ||
| - | - Hold joystick down | + | - Hold joystick down towards the battery connector. |
| - Turn r0ket on. | - Turn r0ket on. | ||
| - | - Write new dataflash image | + | - As above look for a new volume on your system. Mount the r0ket if you don't get one. |
| - | | + | - <note important> |
| - | | + | - Make a copy of the following files to your computer: R0KET.CFG, NICK.CFG, L0NICK.CFG, FONT.CFG, pubx.key, puby.key and priv.key |
| - | - Write the new image by running | + | - Don't worry if some of these files are missing. Your r0ket will still work. |
| - | | + | - Now unmount |
| - | - run "sync", wait until all data is written | + | - < |
| - | - turn off r0ket | + | |
| + | - In this case "/ | ||
| + | - < | ||
| + | - Example: < | ||
| + | - Write the new image by running: | ||
| + | - < | ||
| + | - make absolutely sure that you enter the correct | ||
| + | | ||
| + | - < | ||
| + | - This command may take a minute or two. | ||
| + | - Turn off r0ket and back on, while pressing the joystick towards the battery connector. | ||
| + | - Copy the files from step 16 back to the r0ket. | ||
| You're done. Yay! | You're done. Yay! | ||
| Line 33: | Line 58: | ||
| ===== Windows ===== | ===== Windows ===== | ||
| - | - Turn r0ket off (switch position | + | |
| + | | ||
| - Plug micro-USB cable into r0ket and Computer | - Plug micro-USB cable into r0ket and Computer | ||
| - Hold joystick to the left | - Hold joystick to the left | ||
| - | - Turn r0ket on (switch position | + | - Turn r0ket on (switch position |
| - Release joystick | - Release joystick | ||
| - Wait about 30 seconds. | - Wait about 30 seconds. | ||
| Line 48: | Line 74: | ||
| * select dataflash.img as source and the USB r0ket as target | * select dataflash.img as source and the USB r0ket as target | ||
| * or write with [[http:// | * or write with [[http:// | ||
| - | dd if=dataflash.img of=\\.\g: # (check drive-letter first) | + | * dd if=dataflash.img of=\\.\g: # (check drive-letter first) |
| - wait until all data is written | - wait until all data is written | ||
| - turn off r0ket | - turn off r0ket | ||
| Line 54: | Line 80: | ||
| **You' | **You' | ||
| + | ===== Mac ===== | ||
| + | |||
| + | - Download the firmware pack here: {{: | ||
| + | - Download and compile keys.c from https:// | ||
| + | - Write the following script to a file. Extract the firmware. Execute the script with the directory containing the new firmware as parameter. The script will guide you through the process. | ||
| + | - Example | ||
| + | - < | ||
| + | FlashScript UNSAFE (user errors might cause loss of data and corruption) | ||
| + | |||
| + | < | ||
| + | #!/bin/bash | ||
| + | |||
| + | myTmpdir=/ | ||
| + | myCalled=" | ||
| + | |||
| + | function ERROR { | ||
| + | echo ERROR $@ | ||
| + | } | ||
| + | |||
| + | function DEBUG { | ||
| + | echo DEBUG $@ | ||
| + | } | ||
| + | |||
| + | function PRINT { | ||
| + | echo $@ | ||
| + | } | ||
| + | |||
| + | function DIE { | ||
| + | echo DIED $@ | ||
| + | exit 1 | ||
| + | } | ||
| + | |||
| + | function flashFirmware { | ||
| + | myMount=" | ||
| + | if [ -z " | ||
| + | DIE "Could not flash firmware. Could not find mountpoint $myMount" | ||
| + | fi | ||
| + | cp -v " | ||
| + | sleep 2 | ||
| + | sync | ||
| + | sleep 2 | ||
| + | myroket="/ | ||
| + | PRINT Unmounting the rocket $myroket. Please enter your password: | ||
| + | sudo umount " | ||
| + | return | ||
| + | |||
| + | } | ||
| + | |||
| + | |||
| + | function flashDataflash { | ||
| + | myMount=" | ||
| + | if [ -z " | ||
| + | DIE "Could not flash dataflash. Could not find mount $myMount" | ||
| + | fi | ||
| + | cd " | ||
| + | pwd | ||
| + | cp -v R0KET.CFG NICK.CFG L0NICK.CFG FONT.CFG pubx.key puby.key priv.key $myTmpdir/ | ||
| + | cd $myTmpdir | ||
| + | sleep 5 | ||
| + | #PRINT " | ||
| + | #read | ||
| + | myroket="/ | ||
| + | PRINT Unmounting the rocket $myroket. Please enter your password: | ||
| + | sudo umount $myroket | ||
| + | PRINT Flashing the rocket. Please enter your password: | ||
| + | cd " | ||
| + | echo sudo dd if=$FIRMWARE/ | ||
| + | sudo dd if=$FIRMWARE/ | ||
| + | sync | ||
| + | sleep 3 | ||
| + | sudo mount -t msdos $myroket $myTmpdir/ | ||
| + | cd $myTmpdir/ | ||
| + | cp -v * $myTmpdir/ | ||
| + | ls pubx.key puby.key priv.key || ( echo " | ||
| + | cd /tmp | ||
| + | PRINT Unmounting the rocket $myroket. Please enter your password: | ||
| + | sudo umount $myroket | ||
| + | |||
| + | } | ||
| + | |||
| + | function cleanUp { | ||
| + | sudo rm -rf /tmp/r0ket/ | ||
| + | } | ||
| + | |||
| + | |||
| + | function init { | ||
| + | mkdir -p $myTmpdir/ | ||
| + | mkdir -p $myTmpdir/ | ||
| + | mkdir -p $myTmpdir/ | ||
| + | |||
| + | } | ||
| + | |||
| + | function main { | ||
| + | init | ||
| + | if [ -n " | ||
| + | if [ -e " | ||
| + | FIRMWARE=$@ | ||
| + | FIRMWAREBIN=$@/ | ||
| + | else | ||
| + | DIE $@/ | ||
| + | fi | ||
| + | else | ||
| + | DIE expected the path to the directory with the new firmware as parameter | ||
| + | fi | ||
| + | PRINT " | ||
| + | PRINT " | ||
| + | read | ||
| + | sleep 10 | ||
| + | flashFirmware | ||
| + | #PRINT " | ||
| + | #read | ||
| + | PRINT " | ||
| + | PRINT " | ||
| + | read | ||
| + | flashDataflash | ||
| + | |||
| + | cleanUp | ||
| + | |||
| + | |||
| + | } | ||
| + | |||
| + | main $@ | ||
| + | </ | ||
| + | |||
| + | ===== Updating ===== | ||
| - | The needed | + | If completed the steps above once, you can update your dataflash by copying the files from the ' |
| - | firmware.bin | ||
| - | dataflash.img | ||
init.1324494068.txt.gz · Last modified: by sec
