Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

Forcing Raspbmc to turn on HDMI at boot

📅 2012-Oct-13 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ hdmi, raspberry pi, raspbmc ⬩ 📚 Archive

Problem

Raspberry Pi is running Raspbmc and is connected to a TV by HDMI. If the TV and Raspbmc are powered on at the same time, then everything works fine. However, if the Raspbmc is powered on first and the TV much later, then there is no video or audio on the TV!

Solution

During boot, if Raspbmc sees through HDMI that the TV is off then it switches its video-audio signals to the analog outputs. To force Raspbmc to always use HDMI even if no HDMI display is detected, add the line hdmi_force_hotplug=1 to /boot/config.txt and reboot Raspbmc.

Now, if you boot Raspbmc first and power on the TV later, you will find that video works. However, there is no audio! This is because when forced to use HDMI and no HDMI display is detected, Raspbmc only outputs video and no audio. To force Raspbmc to pick the full HDMI mode where both video and audio are sent, add hdmi_drive=2 to /boot/config.txt and reboot Raspbmc.

# For more info see: http://choorucode.com/2012/10/13/forcing-raspbmc-to-turn-on-hdmi-at-boot/
# Add to /boot/config.txt
hdmi_force_hotplug=1
hdmi_drive=2

By adding both of these lines, the problem should be solved. More information on these modes can be found here. Thanks to the fine folks who answered my query for this solution 😊

Tried with: Raspbmc RC4


© 2022 Ashwin Nanjappa • All writing under CC BY-SA license • 🐘 @codeyarns@hachyderm.io📧