Raspberry Pi setup notes part 1: getting the display to work!

Posted on 20 June 2012 in Raspberry Pi

I received my Raspberry Pi yesterday, and today got it working well enough to display a text-based console on a DVI monitor using Arch Linux. There were a few hiccups along the way, so here are the complete notes so that anyone googling for the same errors as the ones I saw can benefit from my experience.

tl;dr: the file /boot/config.txt sets up various things before the OS is loaded, including HDMI settings. The one in the Arch Linux SD card image didn't work with my machine setup. The system default, which you can get just by removing that file completely, worked just fine.

Here are the details showing how I got to that...

hdmi_mode=19
#arm_freq=800
disable_overscan=1
# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1

# uncomment this if your display has a black border of unused pixels visible
# and your display can output without overscan
#disable_overscan=1
### Original OOB setting:
disable_overscan=1

# uncomment the following to adjust overscan. Use positive numbers if console
# goes off screen, and negative if there is too much border
#overscan_left=16
#overscan_right=16
#overscan_top=16
#overscan_bottom=16

# uncomment to force a console size. By default it will be display's size minus
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

# uncomment if hdmi display is not detected and composite is being output
#hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will force VGA)
#hdmi_group=1
#hdmi_mode=1
### Original OOB setting:
hdmi_mode=19

# uncomment to force a HDMI mode rather than DVI. This can make audio work in
# DMT (computer monitor) modes
#hdmi_drive=2

# uncomment to increase signal to HDMI, if you have interference, blanking, or
# no display
#config_hdmi_boost=4

# uncomment for composite PAL
#sdtv_mode=2

#uncomment to overclock the arm. 700 MHz is the default.
#arm_freq=800

# for more options see http://elinux.org/RPi_config.txt
[root@alarmpi ~]# /opt/vc/bin/tvservice
/opt/vc/bin/tvservice: error while loading shared libraries: libvcos.so: cannot open shared object file: No such file or directory
[root@alarmpi ~]# ldd /opt/vc/bin/tvservice
        libvcos.so => not found
        libpthread.so.0 => /lib/libpthread.so.0 (0x400f9000)
        libdl.so.2 => /lib/libdl.so.2 (0x40074000)
        librt.so.1 => /lib/librt.so.1 (0x4007f000)
        libc.so.6 => /lib/libc.so.6 (0x4013f000)
        /lib/ld-linux.so.3 (0x4004c000)
[root@alarmpi ~]# ls /opt/vc/lib/
libbcm_host.so    libEGL.so        libGLESv2_static.a  libkhrn_static.a  libmmal.so       libvcfiled_check.a  libvcos.so
libcontainers.so  libEGL_static.a  libilclient.a       libluammal.so     libopenmaxil.so  libvchiq_arm.a      libvmcs_rpc_client.a
libdebug_sym.so   libGLESv2.so     libkhrn_client.a    liblua.so         libOpenVG.so     libvchostif.a       libWFC.so
[root@alarmpi ~]# export LD_LIBRARY_PATH=/opt/vc/lib/:LD_LIBRARY_PATH
[root@alarmpi ~]# ldd /opt/vc/bin/tvservice
        libvcos.so => /opt/vc/lib/libvcos.so (0x400c2000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x4012d000)
        libdl.so.2 => /lib/libdl.so.2 (0x40038000)
        librt.so.1 => /lib/librt.so.1 (0x400ff000)
        libc.so.6 => /lib/libc.so.6 (0x4014d000)
        /lib/ld-linux.so.3 (0x40010000)
[root@alarmpi ~]# /opt/vc/bin/tvservice -s
state 0x40002, 720x480 @ 60Hz, interlaced
[root@alarmpi ~]# /opt/vc/bin/tvservice -m CEA
Group CEA has 0 modes:
[root@alarmpi ~]#
[root@alarmpi ~]# /opt/vc/bin/tvservice -m DMT
Group DMT has 13 modes:
           mode 4: 640x480 @ 60Hz, progressive
           mode 5: 640x480 @ 72Hz, progressive
           mode 6: 640x480 @ 75Hz, progressive
           mode 8: 800x600 @ 56Hz, progressive
           mode 9: 800x600 @ 60Hz, progressive
           mode 10: 800x600 @ 72Hz, progressive
           mode 11: 800x600 @ 75Hz, progressive
           mode 16: 1024x768 @ 60Hz, progressive
           mode 17: 1024x768 @ 70Hz, progressive
           mode 18: 1024x768 @ 75Hz, progressive
           mode 21: 1152x864 @ 75Hz, progressive
           mode 35: 1280x1024 @ 60Hz, progressive
           mode 36: 1280x1024 @ 75Hz, progressive
[root@alarmpi ~]# mv /boot/config.txt .
[root@alarmpi ~]# ls /boot
arm128_start.elf  bootcode.bin      kernel_emergency.img  start.elf
arm192_start.elf  cmdline.txt       kernel.img
arm224_start.elf  kernel_debug.img  loader.bin
[root@alarmpi ~]# ls .
config.txt