Difference between revisions of "R-Pi Troubleshooting"

From eLinux.org
Jump to: navigation, search
(Keyboard randomly repeats key presses: change 1500mA to 150mA, must be a typo; no USB keyboard draws 1.5 A)
(Keyboard / Mouse / Input Devices)
Line 31: Line 31:
 
===Wireless Keyboard trouble===
 
===Wireless Keyboard trouble===
 
Some wireless keyboards, for example the Microsoft Wireless Keyboard 800 are reported to fail<ref>http://www.raspberrypi.org/forum/troubleshooting/display-and-keyboard-issues-on-a-real-pi#p74816</ref> even though the current drawn by the wireless adaptor is within the R-Pi USB spec limit of 100 mA. This may be a software driver problem.
 
Some wireless keyboards, for example the Microsoft Wireless Keyboard 800 are reported to fail<ref>http://www.raspberrypi.org/forum/troubleshooting/display-and-keyboard-issues-on-a-real-pi#p74816</ref> even though the current drawn by the wireless adaptor is within the R-Pi USB spec limit of 100 mA. This may be a software driver problem.
 +
 +
===Re-mapping the keyboard with Debian Squeeze===
 +
If different letters appear on-screen from that which you typed, you need to reconfigure you keyboard settings. In Debian, from a command line type: <blockquote>"sudo dpkg-reconfigure keyboard-configuration"</blockquote>without the quotes. Then restart the pi.
  
 
==Memory Cards==
 
==Memory Cards==

Revision as of 16:34, 11 May 2012

Back to the Hub. This page lists the most common problems and suggests some solutions.

Power / Start-up

A good power supply that will supply 5V is vital. There is more information about power supplies and troubleshooting.

Red power LED does not light, nothing on display

The power is not properly connected.

Red power LED is on, green LED does not flash, nothing on display

The Raspberry Pi cannot find a valid image on the SD card. Check that you have correctly written a Raspberry Pi image to the card. See also, Known SD Cards.

Raspberry Pi shuts down soon after booting up

This is caused by a power supply with too low voltage or too high voltage. Or it could be the cable. See: On_the_RPi_usb_power_cable

Pi boots sometimes but not always

With a known good power supply and known good SD card, the R-Pi boots occasionally, but other times shows only a tiny green flicker from the "OK" LED and it fails to start, even with no USB devices and no Ethernet. This has been reported several times[1] [2] [3] and remains an open issue. Low voltage or an improper SD card can cause it. At least one "intermittent boot" case was a SD card problem, and a different card worked consistently. The wiki has a list of working SD cards. Buy from a reliable vendor as it has been claimed that 1/3 of all "Sandisk" labelled memory cards are counterfeit.

Keyboard / Mouse / Input Devices

Keyboard randomly repeats key presses

This is caused by inadequate power. Use a good power supply and a good power cable. Some cheap cables that work with a cell phone, cannot fully power the R-Pi. Some USB devices require a lot of power: most will have a label showing the voltage and mA requirements. They should be 5v 100mA each max, any more than this they must be used with a powered USB hub. Try unplugging every USB device except the keyboard (you should also note that some keyboards have built in hubs and can try to draw 150mA (Pi can only handle 100mA per USB slot without a hub)). Also, use the latest software. Forum user MrEngman reported some keyboard repeats and wireless hangs until upgrading to the debian6-19-04-2012 kernel, which he reports stable with no problems even with a low TP1-TP2 voltage of 4.65 - 4.68 volts.

Keyboard / Mouse interferes with USB WiFi device

Connecting a keyboard and/or mouse while a USB WiFi device is connected, may cause one or both devices to malfunction. On April 30 2012, there was a bugfix[4] relating to USB sharing between high-speed (eg. WiFi) and full/low-speed devices (eg. keyboard/mouse). User spennig[5][6] reports this patch did not fix the Mouse/WiFi conflict.

Wireless Keyboard trouble

Some wireless keyboards, for example the Microsoft Wireless Keyboard 800 are reported to fail[7] even though the current drawn by the wireless adaptor is within the R-Pi USB spec limit of 100 mA. This may be a software driver problem.

Re-mapping the keyboard with Debian Squeeze

If different letters appear on-screen from that which you typed, you need to reconfigure you keyboard settings. In Debian, from a command line type:

"sudo dpkg-reconfigure keyboard-configuration"

without the quotes. Then restart the pi.

Memory Cards

General / Formatting

If you are having problems setting up your memory card you might want to try erasing it completely - especially if it has been used elsewhere and still contains data / partitions.

  • If you are preparing your SD card on a Linux-based system using the dd command, this operation will completely erase any existing data and partitions. Make sure you put the source image on the whole card, e.g. /dev/sdd, NOT /dev/sdd1.

Networking

Ethernet connection is lost when a USB device is plugged in

This is caused by inadequate power. Use a good power supply and a good power cable. Some cheap cables that work with a cell phone, cannot fully power the R-Pi. Some USB devices require a lot of power, so they must be used with a powered USB hub. Some cheap USB hubs suck power from the Raspberry Pi even if a USB power supply is connected.

Ethernet connects at 10M instead of 100M

The LED in the corner of the board labelled "10M" is mislabeled. When that LED is on, the R-Pi is actually connected at 100 Mbps. You can confirm the true transfer rate using a network benchmark such as iperf. You can also read the current network speed with

 cat /sys/class/net/eth0/speed

Passwords

I do not know the password to login

Please check the page http://www.raspberrypi.org/downloads for the correct username and password for each image.


Debian from later dates - pi/raspberry Debian Feb 17 - pi/suse Arch - root/root

Some programs refuse to accept my password

While using Debian, some programs may ask for your password but refuse to accept a valid password.

This is a fault in some Debian images and will be fixed soon. If you are using an image with this fault, enter the following command on the command line.

gconftool-2  -\-type bool  -\-set  /apps/gksu/sudo-mode  true

Please enter this command carefully, the spaces are important. The command should be accepted without any response or errors.

Sound

Sound does not work with a HDMI monitor

This is caused by some computer monitors which select DVI mode even if a HDMI cable is connected.

Enter the command

sudo nano /boot/config.txt

If this file is empty or does not contain the config_hdmi_boost parameter, add the following line

hdmi_drive=2

If this file already contains the hdmi_drive parameter, use the editor to change the value.

Save the edited file

Press Control-X
Press y
Press [enter]

After exiting the editor, restart using the command

sudo reboot

Note that you must use the correct reboot command to force a write of the edited file to the SD card.

Sound does not work at all, or in some applications

The ALSA sound driver is "alpha" and has issues, but some applications do work. If you are running Debian, try

 cd /opt/vc/src/hello_pi/hello_audio
 make
 ./hello_audio.bin

to test analogue output. And

 ./hello_audio.bin 1

to test HDMI.

To test other applications, before "startx" type

 sudo modprobe snd_bcm2835
 sudo aplay <name of wav file>

By default output will be automatic (hdmi if hdmi supports audio, otherwise analogue). You can force it with:

 sudo amixer cset numid=3 <n>

where n is 0=auto, 1=headphones, 2=hdmi.

Display

Startx fails to start

If you just get errors instead of a desktop when typing

 startx

you may be out of storage space on the SD card. By default there are only a few hundred MB free in the 2 GB main partition, which can quickly fill up if you download files. Make sure there is some space free (gparted can expand a partition, if the SD card is > 2GB). Also, installing some software may incorrectly create or modify a .Xauthority file in your home directory, causing startx to fail, according to this thread. Temporarily renaming, moving, or deleting that file may fix the problem.

Video does not play or plays very slowly

The only hardware-accelerated video player is the XMBC distribution and its command line variant omxplayer. H264 is the only hardware-accelerated codec, for playback. No hardware encoding is supported. Additional codecs were not purchased as licensing fees would have increased the R-Pi's price.

Can only get 800x480 resolution in LXDE (Arch linux)

Known issue with distro package as of 17-Apri-2012 - there's some missing boot config info. Creating a suitable cmdline.txt fixes it - type the following at the Raspberry Pi command line:

  sudo echo "dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 root=/dev/mmcblk0p2 rootfstype=ext3 rootwait" >/boot/cmdline.txt

Big black borders around small image on HD monitors

Out of the box, R-Pi graphics don't necessarily fill the 1080p (ie Full HD) screen. This is due to something called "Underscan", and it can be fixed easily by creating a simple text file on the R-Pi SD card by using Notepad on your PC. Here is what you do.

1. Shut down your R-Pi, remove the power and remove the SD card.

2. Put the card in your PC's card reader and browse the contents. There should be some text files plus other files that the PC doesn't recognise. That"s fine.

3. Look to see if there is a file called config (or possibly config.txt). If there is, open it with Notepad. If not, create the file with Notepad. (One way to do this, in XP, is to right-click where you see the other files, select New and then Text document. Then change "New Text Document" to "config").

4. Open config.txt using Notepad, then type the following (ie add the following lines or, if similar entries are already present, edit the values to the ones shown):

If your display has no overscan:


disable_overscan=1

or if your display has some overscan:


overscan_left=-20

overscan_right=-20

overscan_top=-20

overscan_bottom=-20

Then save the file.

5. Take the SD card out of the PC, put it in the R-Pi, and power up the R-Pi. You should see that the graphics area has increased, but probably won"t fill the whole screen.

6. Making the R-Pi graphics fill the screen is a matter of adjusting the numbers you put in the config.txt file. To do this, shut down the R-Pi, take the SD card to the PC and edit the config.txt file as described above. Change the numbers – try jumps of 5 or 10 at a time. Bigger negative numbers reduce the black borders (so -48, which is what I use on my system, means less black border than -20). The numbers do not have to be the same; you can use this feature to centre the display on the screen.

Interference visible on a HDMI or DVI monitor

This may be caused by loss of signal on long video cables. The signal level may be increased by changing a configuration parameter. RPi HDMI interference.jpg

Enter the command

sudo nano /boot/config.txt

If this file is empty or does not contain the config_hdmi_boost parameter, add the following line

config_hdmi_boost=4

If this file already contains the config_hdmi_boost parameter, use the editor to change the value.

Save the edited file

Press Control-X
Press y
Press [enter]

After exiting the editor, restart using the command

sudo reboot

You may experiment with different values of config_hdmi_boost. Value 1 is used for very short cables, value 7 is used for very long cables. Note that you must use the correct reboot command to force a write of the edited file to the SD card.

GPIO

Remember that the GPIO pins are 3.3V logic level only, and are NOT 5V tolerant.

If you momentarily shorted the two end GPIO pins together (+3.3V and +5V), or a supply pin to ground, and the Pi appears to be dead, don't panic. The input polyfuse may have tripped. It is self-resetting after it cools down. Disconnect power and wait for 30 minutes, then try to restart.

Troubleshooting power problems

If you think you have a problem with your power supply, it is a good idea to check the actual voltage on the Raspberry Pi circuit board. Two test points labelled TP1 and TP2 are provided on the circuit board to facilitate voltage measurements.

Use a multimeter which is set to the range 20 volts DC (or 20v =). You should see a voltage between 4.75 and 5.25 volts. Anything outside this range indicates that you have a problem with your power supply or your power cable.

If you have not used a multimeter before, see these [basic instructions]

Note: Even if the multimeter shows the correct voltage, you may have some power supply problems. A multimeter only displays the average voltage. If there are very short-lived dips or spikes in the voltage, these will not be shown by the multimeter.

RPI Test Points.JPG Voltmeter.JPG

References