Adding support for the BeagleBone White DVI-D with audio cape

340 views
Skip to first unread message

cde

unread,
Feb 9, 2014, 7:44:35 AM2/9/14
to beagl...@googlegroups.com
Hello,

The current 3.8 rcn linux-dev is missing the devicetree spec for this cape (http://elinux.org/Beagleboard:BeagleBone_DVI-D_with_Audio). This cape is based on the DVI-D rev A2 cape (http://elinux.org/CircuitCo/BeagleBone_DVI-D) combined with the audio rev A cape (http://elinux.org/CircuitCo:Audio_Cape_RevA). Typically, capemgr says at boot:

bone-capemgr bone_capemgr.8: slot #0: Requesting firmware 'BB-BONE-DVID-02-00A1.dtbo' for board-name 'BeagleBone DVI-D WITH AUDIO CAPE', version '00A1'
bone-capemgr bone_capemgr.8: failed to load firmware 'BB-BONE-DVID-02-00A1.dtbo'

The attached patch creates a new dts for this particular cape. It was tested as working for both DVI and audio out (ffmpeg -i file.mp3  -f alsa "default:EVM" -re -vol 50). However the HDMI cable has to be plugged in before the kernel boots, otherwise it says it defaults to 1024x768 (instead of the max resolution 1680x1050) and nothing is displayed. Does anyone have this problem with the DVI cape (with or without audio) has well? Also, is there a proper way to select the resolution? Typically, I'm looking to set 1280x720@60 at boot. TILCDC_DEFAULT_MAX_BANDWIDTH in drivers/gpu/drm/tilcdc/tilcdc_drv.h seems to be the only way to force the resolution (also see https://github.com/beagleboard/meta-beagleboard/blob/master/common-bsp/recipes-kernel/linux/linux-mainline-3.8/hdmi/0009-tilcdc-1280x1024x60-bw-1920x1080x24-bw.patch)

0xyz-beaglebone-create-dvi-audio-cape-dts.patch

cde

unread,
Feb 11, 2014, 5:37:15 AM2/11/14
to beagl...@googlegroups.com

For the record, the DVI not turning on problem was caused by the excessive pruning of the video modes in tilcdc_crtc.c (see below); in addition when plugging the cable after the beagle had booted, drm_fb_helper.c would ignore any EDID and try to force 1024x768 or any lower resolution. The pruning is unnecessary, I'm not sure why it is done since any mode within the BB bandwidth works fine (the "reduced blanking mode" is not an issue at all). The attached patch fixes both problems and ensures a 1280x720@60 resolution at all times.

Another issue was with omaplfb_linux.c provided in SDK 5.01.00.01. Compiling with PM_SUPPORT=1 FBDEV=yes is required however compilation fails as functions register_vsync_cb() and unregister_vsync_cb() are unknown. I commented the two if blocks and everything works fine after running /opt/gfxsdkdemos/335x-demo (testing with the raw demos provided in the SDK). It's likely those two callbacks are not stricly needed, and will only allow synchronizing frame switching with the monitor's vertical sync.

---
1st issue (all monitor modes being rejected by tilcdc_crtc.c when hotplugging DVI)
---
Feb  9 14:36:13 beagle kernel: [   33.557776] mode 720x576@50 pixel-clock 27000 audio false cea true can_output false
Feb  9 14:36:13 beagle kernel: [   33.565925] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.572013] mode 640x480@60 pixel-clock 25175 audio false cea true can_output false
Feb  9 14:36:13 beagle kernel: [   33.580085] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.586167] mode 720x480@60 pixel-clock 27000 audio false cea true can_output false
Feb  9 14:36:13 beagle kernel: [   33.594238] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.600338] mode 1024x768@60 pixel-clock 65000 audio false cea false can_output false
Feb  9 14:36:13 beagle kernel: [   33.608610] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.614705] mode 640x480@60 pixel-clock 25200 audio false cea false can_output false
Feb  9 14:36:13 beagle kernel: [   33.622880] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.628969] mode 640x480@67 pixel-clock 30240 audio false cea false can_output false
Feb  9 14:36:13 beagle kernel: [   33.637141] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.643260] mode 800x600@56 pixel-clock 36000 audio false cea false can_output false
Feb  9 14:36:13 beagle kernel: [   33.651423] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.657512] mode 800x600@60 pixel-clock 40000 audio false cea false can_output false
Feb  9 14:36:13 beagle kernel: [   33.665684] Pruning mode, only support reduced blanking modes
Feb  9 14:36:13 beagle kernel: [   33.672616] mode 1024x768@60 pixel-clock 65000 audio false cea false can_output false
Feb  9 14:36:13 beagle kernel: [   33.680995] 1024x768, hbp=160, hfp=24, hsw=136, vbp=29, vfp=3, vsw=6
---
2nd issue (failed compilation of module omaplfb.ko from SGX 5.01.00.01)
---
  CC [M]  /root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_displayclass.o
  CC [M]  /root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.o
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c: In function 'OMAPLFBWaitForVSync':
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c:710:7: error: implicit declaration of function 'register_vsync_cb' [-Werror=implicit-function-declaration]
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c:710:30: error: 'vsync_callback_t' undeclared (first use in this function)
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c:710:30: note: each undeclared identifier is reported only once for each function it appears in
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c:710:47: error: expected ')' before 'grpx_irq_wait_handler'
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c:716:7: error: implicit declaration of function 'unregister_vsync_cb' [-Werror=implicit-function-declaration]
/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.c:716:49: error: expected ')' before 'grpx_irq_wait_handler'
cc1: some warnings being treated as errors
make[4]: *** [/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux/omaplfb_linux.o] Error 1
make[3]: *** [/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM/services4/3rdparty/dc_ti335x_linux] Error 2
make[2]: *** [_module_/root/Graphics_SDK_5_01_00_01/GFX_Linux_KM] Error 2
tilcdc-1280x720.patch

brown...@gmail.com

unread,
Jul 6, 2014, 8:37:51 AM7/6/14
to beagl...@googlegroups.com, devinech...@gmail.com
Please excuse me for this question, but I am new to this.  This looks like the answer to my problem, but, new problem, what do I do with the patch?  I haven't found the bit of info that tells me how to deal with patches.

Thanks,
Reply all
Reply to author
Forward
0 new messages