This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[OMAP3530] OpenGL demo stops quickly with TV out

Other Parts Discussed in Thread: OMAP3530

Hi:

Our platform is OMAP3530 + Linux 2.6.28.  The OpenGL SDK is OMAP35x_Graphics_SDK_3_00_00_08.

All demos runs well when the output is configured as "lcd".


By modifying the bootargs to [omap-dss.def_disp="tv"] from [omap-dss.def_disp="lcd"], we changed the default display from lcd to TV. The output was good and the program which accessed frame buffer (/dev/fb0) is working well until now.

However,  the OpenGL demos only showed a few frames and then stopped. We tried a few demos (OGLESEvilSkull, OGLESParticles, OGLESLighting and so on), the symptom was the same, we got the same warning before the program stopped:

 

PVR_K:(Warning): SGXPostPowerState : SGX Power Transition from 0 to 3 OK [308, /home/kevin/dk8k/GFX_Linux_KM/services4/srvkm/devices/sgx/sgxinit.c]

 

We tested Linux 2.6.29 as well, same problem.

 

Has anyone met this problem? Any advice or clue will be appreciated.

 

Thanks in advance.

Kevin


 

 

 

  • The warning message means SGX went to suspend for some reason.

    I will try TV-out tomorrow to see if I can reproduce the problem. I have gfx SDK 3.0.0.9 and kernel 2.6.29.

  • The OMAP35x_Graphics_SDK_3_00_00_08 version is quite old and had a number of problems.  I recommend that you update to at least the 3.00.00.9 version or newer.  You will need to update your Linux baseport as well.

    http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/dvsdk/DVSDK_3_00/latest/index_FDS.html

    Regards, Clay

  • I have reproduced the issue with sdk 3.0.0.9 & kernel 2.6.29, only when set WindowSystem=libpvrPVR2D_FLIPWSEGL.so in /etc/powervr.ini. The issue does not exist in FRONT or BLIT WSEGL mode.

    Does FRONT WSEGL work for you?

    BTY, the fb color depth has to be 16 in sdk 3.0.0.9.

  • We are currently using libpvrPVR2D_FRONTWSEGL.so. It does not work.

     

    The environments we have tested are: sdk 3.0.0.8 & kernel 2.6.29; sdk 3.0.0.8 & kernel 2.6.28. They have the same problem.

     

    We are testing sdk 3.0.0.9 & kernel 2.6.29 now.

     

    Thanks.

     

     

  • Please don't forget to '/etc/init.d/rc.pvr restart' after 'fbset -depth 16'.

  • Bin Liu said:

    Please don't forget to '/etc/init.d/rc.pvr restart' after 'fbset -depth 16'.

     

     

    Here is the fb setting in my rc.pvr file:

     

        #Set to 640x480 16-bit
        fbset -xres 640 -yres 480 -depth 16

        #Increase the buffer size for flip support
        fbset -vxres 640 -vyres 1920

    #     #Set to ARGB mode
    #     fbset -rgba  8/16,8/8,8/0,8/24

        #Set to RGB565 mode
        fbset -rgba 5/11,6/5,5/0,0/0

     

     

    Please verify.

    Please note that in my case, it works if the default display is set to "lcd".

     

  • I did not know you added those setup in rc.pvr. But please make sure all the fbset commands should be executed before loading omaplfb module. (Since it works for lcd, there should have no problem here.)

    Please go ahead test with 3.0.0.9 sdk. Since I dont have 3.0.0.8 sdk, I cannot verify with it.

  •  

    I updated to 3.00.00.9 and used it on PSP linux-02.01.01.08.

    It is the same problem :(

     

  • I just tested 3.0.0.9 sdk on Linux 2.6.29 (PSP: linux-02.01.01.08)

     

    Under the release version , the demo stops  after showing one frame or two. It might be running, but showing no image on screen and there was no output message.

    Under the debug version , it show only oen frame or two on screen, but the image is blured. We can only see the profile of the objects.

    However, the debug message keeps being output. Here is output:

     

    PVR:(Error): PVRSRVMetricsTimeNow: not implemented [174, /home1/karthik/gfxsdkcr
    eate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/services4/
    srvclient/env/linux/common/pvr_metrics.c]
    PVR:
    PVR: Memory Stats
    PVR: ------------
    PVR:
    PVR: High Water Mark = 3880 bytes
    PVR:
    PVR: 3880 bytes still allocated in 1 allocations
    PVR:
    PVR: 1   -  3880 bytes at 0xAA160 - tls.c:49
    PVR:
    PVR:
    PVR: Memory Stats
    PVR: ------------
    PVR:
    PVR: High Water Mark = 3880 bytes
    PVR:
    PVR: 3880 bytes still allocated in 1 allocations
    PVR:
    PVR: 1   -  3880 bytes at 0xAA160 - tls.c:49
    PVR:
    PVR:(Error): *** PVR2D Blt via 3D Core *** [425, devices/sgx/pvr2dinit.c]
    PVRShell: EGL 1.4 initialized
    PVR: SysDevicePostPowerState: SGX Leaving state D3
    PVR: EnableSGXClocks: Enabling SGX Clocks
    PVR: CPU Clock is 1000Mhz
    PVR: SGX Functional Clock rate is 110Mhz
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR_K:(Warning): SGXPostPowerState : SGX Power Transition from 3 to 0 OK [308, /
    home1/karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/
    src/eurasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10028 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10008 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10004 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10008 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10004 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR:(Error): PVRSRVEventObjectWait: Error 13 returned [304, /home1/karthik/gfxsd
    kcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/service
    s4/srvclient/env/linux/common/osfunc_um.c]
    PVR:(Error): PVRSRVPollForValue: PVRSRVEventObjectWait failed [88, /home1/karthi
    k/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/
    services4/srvclient/common/resources.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10008 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR:(Error): PVRSRVEventObjectWait: Error 13 returned [304, /home1/karthik/gfxsd
    kcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/service
    s4/srvclient/env/linux/common/osfunc_um.c]
    PVR:(Error): PVRSRVPollForValue: PVRSRVEventObjectWait failed [88, /home1/karthi
    k/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/
    services4/srvclient/common/resources.c]
    PVR:(Error): PVRSRVEventObjectWait: Error 13 returned [304, /home1/karthik/gfxsd
    kcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/service
    s4/srvclient/env/linux/common/osfunc_um.c]
    PVR:(Error): PVRSRVPollForValue: PVRSRVEventObjectWait failed [88, /home1/karthi
    k/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/
    services4/srvclient/common/resources.c]
    PVR_K:(Error): SGXOSTimer() detected SGX lockup (0x10004 tasks) [1062, /home1/ka
    rthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eura
    sia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Error): HWRecoveryResetSGX: SGX Hardware Recovery triggered [992, /home1/
    karthik/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eu
    rasia_psp_km/services4/srvkm/devices/sgx/sgxinit.c]
    PVR_K:(Warning): Soft Reset of SGX [355, /home1/karthik/gfxsdkcreate/builder/ddk
    build/ti_references/sources/GFX_Linux_DDK/src/eurasia_psp_km/services4/srvkm/dev
    ices/sgx/sgxreset.c]
    PVR:(Error): PVRSRVEventObjectWait: Error 13 returned [304, /home1/karthik/gfxsd
    kcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/service
    s4/srvclient/env/linux/common/osfunc_um.c]
    PVR:(Error): PVRSRVPollForValue: PVRSRVEventObjectWait failed [88, /home1/karthi
    k/gfxsdkcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/
    services4/srvclient/common/resources.c]

    PVR:(Error): PVRSRVEventObjectWait: Error 13 returned [304, /home1/karthik/gfxsd
    kcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/service
    s4/srvclient/env/linux/common/osfunc_um.c]
    PVR:(Error): PVRSRVEventObjectWait: Error 13 returned [304, /home1/karthik/gfxsd
    kcreate/builder/ddkbuild/ti_references/sources/GFX_Linux_DDK/src/eurasia/service
    s4/srvclient/env/linux/common/osfunc_um.c]

    ......

    We notice the "Error 13 returned" is repeated forever.

    Thanks.

    Kevin

  • The OMAP3 EVM S/W page http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/dvsdk/DVSDK_3_00/latest/index_FDS.html shows the latest PSP is v2.1.3.11 for gfx sdk 3.0.0.9.

    Is it possible for you to move to PSP2.1.3.11, witch is the one I use? I am no sure if that will make difference, but at least we are aligned on the S/W packages.

    with PSP2.1.3.11 & sdk3.0.0.9, I do have issue with FLIP mode on S-video output, but FRONT mode works with S-video output (res: 720x482).

  • Bin Liu said:

    The OMAP3 EVM S/W page http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/dvsdk/DVSDK_3_00/latest/index_FDS.html shows the latest PSP is v2.1.3.11 for gfx sdk 3.0.0.9.

    Is it possible for you to move to PSP2.1.3.11, witch is the one I use? I am no sure if that will make difference, but at least we are aligned on the S/W packages.

    with PSP2.1.3.11 & sdk3.0.0.9, I do have issue with FLIP mode on S-video output, but FRONT mode works with S-video output (res: 720x482).

     

    Thanks for the info.

    We are upgrading the PSP to 2.1.3.11, will do a test later on.

    We need the FLIP mode becuause FRONT mode brings tearing images in our case.

  • We are working on the FLIP mode internally. But I want to see you have FRONT mode working to ensure you don't miss anything.

  • Bin Liu said:

    We are working on the FLIP mode internally. But I want to see you have FRONT mode working to ensure you don't miss anything.

     

    We tested the upgraded system: PSP_02.01.03.11 + OMAP35x_Graphics_SDK_3_00_00_09. The kernel was built with default configuration.

    The problem still exists. Both FLIP and FRONT modes have the same issue.

     

    I am wondering the setting of the resultion made the difference between your environment and mine.

    I set the framebuffer this way:

    1.  In uboot:

    setenv bootargs mem=88M console=ttyS2,115200n8 noinitrd ip=192.168.1.240 root=/dev/nfs rw nfsroot=192.168.1.33:/data/omap3 omap-dss.def_disp="tv"

     

    2. After kernel starts up, an autorun program executes the following:

    ./tmp/fbset.real -xres 640 -yres 480 -depth 16
    ./tmp/fbset.real -vxres 640 -vyres 1920
    cd /etc/init.d/
    ./rc.pvr start

    3. run the sample.

     

    Can you post your environment settings? I would like to follow yours and give it a try.

    Thanks.

    Kevin

  • Sorry for my late response. But I have tried your config and not even one frame got rendered on the TV. The TV only shows vertical color strips.

    If you built kernel with defult config, you should use 'ttyS0' instead of 'ttyS2'. I see garbage output during kernel boots up with 'ttyS2'.

    After changed your bootargs to use 'ttyS0', your config works for me. gles1test1 test app works with FRONT mode.

    Where did you get fbset.real from? I use fbset command in the NFS rootfs provided in the PSP package.

    BTY, which evm version do you use?

     

    root@omap3evm:~# cat /etc/powervr.ini
    [default]
    WindowSystem=libpvrPVR2D_FRONTWSEGL.so
    #WindowSystem=libpvrPVR2D_FLIPWSEGL.so

  • by default the display will go to sleep (blank) in 20 sec. So I run the following command right after the kernel boots up to prevent it.

    echo 999999 > /sys/devices/platform/omapfb/sleep_timeout

  • Bin Liu said:

    Sorry for my late response. But I have tried your config and not even one frame got rendered on the TV. The TV only shows vertical color strips.

    If you built kernel with defult config, you should use 'ttyS0' instead of 'ttyS2'. I see garbage output during kernel boots up with 'ttyS2'.

    After changed your bootargs to use 'ttyS0', your config works for me. gles1test1 test app works with FRONT mode.

    Where did you get fbset.real from? I use fbset command in the NFS rootfs provided in the PSP package.

    BTY, which evm version do you use?

     

    root@omap3evm:~# cat /etc/powervr.ini
    [default]
    WindowSystem=libpvrPVR2D_FRONTWSEGL.so
    #WindowSystem=libpvrPVR2D_FLIPWSEGL.so

     

     

    Regarding the tty issue, I am sorry for not mentiong I have changed the configuration on UART. But anyway, it should not affect the Graphics.

     

    I tried gles1test1. I works for both FRONT and FLIP.

    However, what I tested before was the demos unde /opt/gfxsdkdemos/ogles. Can you test those programs?

    The reason that I used fbset.real was that the file system I used is came with the old PSP, under which fbset does not work properly. But now I have switched to the file system provided with PSP_02.01.03.11 and fbset works.

    Thanks.

  • I already run  this command.

  • It is strange to me that gles1test1 works for you but not other demos in gfxsdkdemos/ogles.

    I tested all those demos for few minutes each with 640x480@16 and 720x482@16 S-video resolutions, and have no any issue in FRONT mode.

    Which evm version do you use? just want to ensure we are aligned. I use rev G.

  • Bin Liu said:

    It is strange to me that gles1test1 works for you but not other demos in gfxsdkdemos/ogles.

    I tested all those demos for few minutes each with 640x480@16 and 720x482@16 S-video resolutions, and have no any issue in FRONT mode.

    Which evm version do you use? just want to ensure we are aligned. I use rev G.

     

     

    For my understanding, which might be simple and wrong, the difference between gles1test1 and the other demos is the amount of frames they display.  gles1test1 renders only a few (not more than 3) frames,  while the other demos, for example OGLESParticles,  shows a series of frames.  The problem of OGLESParticles is that it only shows the first few frames but then stops.

    Our tests were not conducted on the EMV board,  but on our own 2 boards . The Device revisions of CPUs are "B" and "D". Is it possible for you to conduct the test on rev B or D? Thanks.

    Please note that gles1test1 works for both FRONT and FLIP modes in our test.

  • I am kind of confused, if gles1test1 only renders few frames, how do you tell it works? because the app terminates normally?

    I am not aware of rev B or D. Where do you get the letters? Do you use TI processor board on your own board? The processor board has rev 'B...'

    I have few questions:

    1. give option '0' to gles1test1 will make it run forever, can you please try it to see if it still works for you?

    2. do those demos work with DVI output? just want to make sure you installed the libraries properly, you know there are gfx_xxx_es2.x and gfx_xxx_es3.x in the sdk.

  • Please see my answers in blue.

     

     

    Bin Liu said:

    I am kind of confused, if gles1test1 only renders few frames, how do you tell it works? because the app terminates normally?

    Yes. Under both lcd and tv mode,  image was displayed for a very short time, then the screen became blank, and the program terminated normally. So I thought it worked for both modes.

     

    I am not aware of rev B or D. Where do you get the letters? Do you use TI processor board on your own board? The processor board has rev 'B...'

    Yes, we are using the TI processor on the board. The prints on the CPU is :

    OMAP TM

    X3530BCU5S

    85Y0040 YB

     

     

     

    I have few questions:

    1. give option '0' to gles1test1 will make it run forever, can you please try it to see if it still works for you?

    It works in lcd mode. 2 triangles keep flipping. But in tv mode, it only shows 2 triangles flat, not flipping. So it seems to be the same issue of the demos.

    2. do those demos work with DVI output? just want to make sure you installed the libraries properly, you know there are gfx_xxx_es2.x and gfx_xxx_es3.x in the sdk.

    Yes, those demos work with DVI output.

     

    BTW,  I modified  file /etc/init.d/powervr.ini select the FRONT or FLIP mode, am I right?

    Thanks

     

  • powervr.ini shoud be in /etc/, not /etc/init.d/.

    I have posted my copy in my previous post.

     

  • Bin Liu said:

    powervr.ini shoud be in /etc/, not /etc/init.d/.

    I have posted my copy in my previous post.

     

     

    I am sorry, I just noticed this.

    It is because the "make install" command copies this file to /etc/init.d (line 243 of file Makefile).

    Now, the Front mode works.

     

    Thanks.

     

     

  • Glad we made it work eventually!

    It seems a bug in the makefile. Thanks for reporting that. We will fix it in next release.

  • Bin Liu said:

    Glad we made it work eventually!

    It seems a bug in the makefile. Thanks for reporting that. We will fix it in next release.

     

    Will you open the issue of the FLIP mode failure? I would consider it an easy fix for the development team.

    Thanks.