User Tools

Site Tools


init

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
init [2012/04/18 15:26]
sec add r15
init [2013/07/31 21:28] (current)
sec Change according to Sven Neuhaus
Line 83: Line 83:
  
   - Download the firmware pack here: {{:​r0ket-firmware-r15.tar.gz}}   - Download the firmware pack here: {{:​r0ket-firmware-r15.tar.gz}}
-  - Download and compile keys.c from https://​github.com/​r0ket/​r0ket.git (r0ket/​tools/​generate-keys.c) and put in in the same directory as the script+  - Download and compile keys.c from https://​github.com/​r0ket/​r0ket.git (r0ket/​tools/crypto/​generate-keys.c) and put in in the same directory as the script
   - 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.   - 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   - Example
Line 113: Line 113:
  
 function flashFirmware { function flashFirmware {
- myMount="​$(diskutil info $(system_profiler SPUSBDataType | grep -A10 "NXP LPC13XX IFLASH"​ | grep "BSD Name" | awk -F:  '​{print $2}') | grep "Mount Point" | sed 's/[ ]*.*[ ][ ]//​g'​)/"​+ myMount="​$(diskutil info $(system_profiler SPUSBDataType | grep -A15 "NXP LPC13XX IFLASH"​ | grep "BSD Name" | awk -F:  '​{print $2}') | grep "Mount Point" | sed 's/[ ]*.*[ ][ ]//​g'​)/"​
  if [ -z "​$myMount"​ ] || [ ! -d "​$myMount"​ ]; then  if [ -z "​$myMount"​ ] || [ ! -d "​$myMount"​ ]; then
                 DIE "Could not flash firmware. Could not find mountpoint $myMount"​                 DIE "Could not flash firmware. Could not find mountpoint $myMount"​
Line 121: Line 121:
  sync  sync
  sleep 2  sleep 2
- myroket="/​dev/​$(system_profiler SPUSBDataType | grep -A10 "NXP LPC13XX IFLASH"​ | grep "BSD Name" | awk -F: '​{print $2}' | sed 's/ //'​)"​+ myroket="/​dev/​$(system_profiler SPUSBDataType | grep -A15 "NXP LPC13XX IFLASH"​ | grep "BSD Name" | awk -F: '​{print $2}' | sed 's/ //'​)"​
  PRINT Unmounting the rocket $myroket. Please enter your password:  PRINT Unmounting the rocket $myroket. Please enter your password:
  sudo umount "​$myroket"​  sudo umount "​$myroket"​
Line 153: Line 153:
  cd $myTmpdir/​backup  cd $myTmpdir/​backup
  cp -v *  $myTmpdir/​mountpoint/​  cp -v *  $myTmpdir/​mountpoint/​
- ls pubx.key puby.key priv.key || ( echo "​Generating new keys" && cd .. && ​~/keys && cp -v files/* $myTmpdir/​mountpoint/​ )+ ls pubx.key puby.key priv.key || ( echo "​Generating new keys" && cd .. && ​./generate-keys && cp -v files/* $myTmpdir/​mountpoint/​ )
  cd /tmp  cd /tmp
  PRINT Unmounting the rocket $myroket. Please enter your password:  PRINT Unmounting the rocket $myroket. Please enter your password:
init.1334755602.txt.gz ยท Last modified: 2012/04/18 15:26 by sec