Difference between revisions of "RPI safe mode"

From eLinux.org
Jump to: navigation, search
m (Added rev 1 and 2 board info)
(5 intermediate revisions by the same user not shown)
Line 12: Line 12:
 
(You can also mount /dev/mmcblk0p2 and fix up the rootfs if you have problems there that stop you booting).
 
(You can also mount /dev/mmcblk0p2 and fix up the rootfs if you have problems there that stop you booting).
  
Short Jumpers 5&6.
+
Connect pins 5 & 6 with a jumper or piece of wire. These pins are the 3rd row from the end of the P1 header closest to the edge of the board.
Be very careful with where you insert the jumper. Some pins carry power, so shorting those would not be a good idea. Third row from the end.
+
  
 +
Be very careful with where you insert the jumper. Some pins carry power, so shorting those would not be a good idea. Wire insulation stripped off of 20 AWG wire can be used to cover the power pins and help prevent accidents.
 +
 +
[[File:Jump-pins-5-6.jpg|left|thumb|500px|20 AWG wire used to connect P1 pins 5 and 6 to boot RPi into safe mode. Also, 20 AWG wire insulation used to protect the power pins on the P1 header from accidentally being shorted to another pin or each other. ]]
 +
 +
<br />
  
 
More info:
 
More info:
 
http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=12007
 
http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=12007
 +
 +
P1 Pin diagram: [[RPi Low-level peripherals]]
 +
 +
 +
<br clear=all />
 +
 +
== Wake from Halt<ref>http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=24682</ref> ==
 +
 +
When using bootcode.bin dated 12/04/2012 or later, the same two pins (5 & 6) can be momentarily shorted to wake the Raspberry Pi from the halted state.
 +
 +
The command:
 +
 +
<code>sudo halt</code>
 +
 +
puts the cpu/gpu into a very low power state making the system safe to power off. Previously the only simple way to restart the Raspberry Pi from this state was to cycle the power. Recent changes to the bootcode.bin file will now allow the Raspberry Pi to be started by momentarily connecting pins 5 & 6.
 +
 +
Just about anything made of conductive metal can be used to short these two pins for the moment require to start the boot up process, including a button or switch being wired to the pins.
 +
 +
This method works on both Rev. 1 and Rev. 2 Model B boards.
 +
 +
Be careful as power pins are located right next to these pins and you could permanently damage your Raspberry Pi if you accidentally short a pin to the 5v power pin.
 +
 +
== References ==
 +
<references/>

Revision as of 06:16, 4 January 2013

This results in config.txt being ignored (except for avoid_safe_mode). A default cmdline.txt is applied, and kernel_emergency.img is loaded (if not available, then just kernel.img).

It provides a means of recovering from, e.g.

  • too high an overclock
  • a typo in cmdline.txt
  • an incorrect kernel=<filename> parameter
  • an invalid display mode

without requiring a PC. (Obviously it won't help if you've deleted start.elf...)

The busybox based kernel_emergency.img has /boot mounted, and vi installed so you can fix up config.txt or cmdline.txt. (You can also mount /dev/mmcblk0p2 and fix up the rootfs if you have problems there that stop you booting).

Connect pins 5 & 6 with a jumper or piece of wire. These pins are the 3rd row from the end of the P1 header closest to the edge of the board.

Be very careful with where you insert the jumper. Some pins carry power, so shorting those would not be a good idea. Wire insulation stripped off of 20 AWG wire can be used to cover the power pins and help prevent accidents.

20 AWG wire used to connect P1 pins 5 and 6 to boot RPi into safe mode. Also, 20 AWG wire insulation used to protect the power pins on the P1 header from accidentally being shorted to another pin or each other.


More info: http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=12007

P1 Pin diagram: RPi Low-level peripherals



Wake from Halt[1]

When using bootcode.bin dated 12/04/2012 or later, the same two pins (5 & 6) can be momentarily shorted to wake the Raspberry Pi from the halted state.

The command:

sudo halt

puts the cpu/gpu into a very low power state making the system safe to power off. Previously the only simple way to restart the Raspberry Pi from this state was to cycle the power. Recent changes to the bootcode.bin file will now allow the Raspberry Pi to be started by momentarily connecting pins 5 & 6.

Just about anything made of conductive metal can be used to short these two pins for the moment require to start the boot up process, including a button or switch being wired to the pins.

This method works on both Rev. 1 and Rev. 2 Model B boards.

Be careful as power pins are located right next to these pins and you could permanently damage your Raspberry Pi if you accidentally short a pin to the 5v power pin.

References

  1. http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=24682