NOTICE: The Processors Wiki will End-of-Life in December of 2020. It is recommended to download any files or other content you may need that are hosted on processors.wiki.ti.com. The site is now set to read only.
GSG: DVSDK for WinCE - Running the Demos
This page describes how to run demonstration applications on the OMAP35xx and DM37xx EVMs using DVSDK for Windows CE
Loading the target image
After the OS design is compiled, follow the procedure outlined in the Board Support Package user's guide to load the image onto the OMAP35x/DM37xx EVM.
Running the demos
After booting the OS image (with a default name of NK.bin) on the OMAP35xx/DM37xx EVM, you can use Windows Media Player (WMP) to play AVI and MP4 files. WMP uses TI's DSP accelerator enabled video transform filters to decode H.264, MPEG2, and MPEG4 video while using the ARM for mp3 decoding.
Some AVI media files can be found here http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/media/wince/index_FDS.html
To try out TI's DSP accelerated H.264 and MPEG4 encoders, you can use an application called CaptureTest which is available with the ARM A8 BSP. This allows you to capture video upto D1 resolution from the S-Video, component or composite ports of the OMAP35xx/DM37xx EVMs and encode it using the H.264 or MPEG4 encoders and save it in an ASX container.
Testing DMAI applications
If you want to experiment with video encoders (H.264 and MPEG4), video decoders (H.264, MPEG4, MPEG2), Audio decode (AAC LE HC), JPEG image encode or decode, g711 speech encode or decode, DMAI sample applications are provided. These sample applications use file-based input and output to perform encode or decode. Use the instructions that follow to run the sample applications. Issue the desired commands shown in the following subsections at the target control prompts provided in Visual Studio 2005 Professional Edition (with Windows Embedded CE 6.0 R2/R3 with Platform Builder support installed).
These test commands assume that media files are located in the %_FLATRELEASEDIR%/Release/data directory. Media files are not provided as part of the BSP, and must be downloaded separately. Similarly output files will be put under %_FLATRELEASEDIR%/Release/results. This empty directory needs to be created before the tests are run.
The media test files can be found here http://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/media/wince/dmai_test_files.zip
Test commands for DMAI decode applications
Note: Type the test commands shown here on a single command line.
To perform an H.264 decode of 50 frames of an H.264 elementary stream into UYVY packed RAW frames:
s video_decode_io2_omap3530 -c h264dec -i /Release/data/davincieffect_ntsc.264 -o /Release/results/davincieffect_ntsc.264.yuv -n 50
To perform an AAC decode of 200 frames of an AAC elementary stream into a PCM audio file:
s audio_decode_io1_omap3530 -c aachedec -i /Release/data/davincieffect.aac -o /Release/results/davincieffect.aac.pcm -n 200
To perform a JPEG decode of a JPEG image into a UYVY Packed RAW frame:
s image_decode_io1_omap3530 -c jpegdec -i /Release/data/fruitbasket_352x288_420p.jpg -o /Release/results/fruitbasket_352x288_420p.jpg.uyvy
To perform an MPEG2 decode of 50 frames of an MPEG2 elementary stream into UYVY packed RAW frames:
s video_decode_io2_omap3530 -c mpeg2dec -i /Release/data/davincieffect_cif.m2v -o /Release/results/davincieffect_cif.m2v.yuv -n 50
To perform a speech decode of 1000 speech frames from g.711 alaw format to 16 bit linear PCM format:
s speech_decode_io1_omap3530 -c g711dec -i /Release/data/davincieffect.g711 -o /Release/results/davincieffect.pcm --compandinglaw alaw -n 1000
Test commands for DMAI encode applications
Note: Type the test commands shown here on a single command line.
Some of the media files used for encoding are generated by the decode operation above. The relevant files need to be copied from %_FLATRELEASEDIR%/Release/results into %_FLATRELEASEDIR%/Release/data directory.
To perform a JPEG encode of a UYVY packed RAW frame of resolution 352x288 into a JPEG image:
s image_encode_io1_omap3530 -c jpegenc -i /Release/data/fruitbasket_352x288_420p.jpg.uyvy -o /Release/results/fruitbasket_352x288_420p.jpg -r 352x288 --iColorSpace 3
To perform an H.264 encode of 50 UYVY packed RAW frames of resolution 720x480 into an H.264 elementary stream at a bitrate of 1 Mbps:
s video_encode_io1_omap3530 -c h264enc -i /Release/data/davincieffect_ntsc.264.uyvy -o /Release/results/davincieffect_ntsc.264 -r 720x480 -b 1000000 -n 50
To perform a speech encode of 1000 speech frames from 16bit linear PCM format to g.711 alaw format:
s speech_encode_io1_omap3530 -c g711enc -i /Release/data/davincieffect.pcm -o /Release/results/davincieffect.alaw --compandinglaw alaw -n 1000
Running C6Accel Sample Application
- The c6accel_app.exe application has some special memory requirements that require it to run on a modified memory configuration different from what is configured in the DVSDK 1.10 package out of the box. To achieve this, the following steps must be followed.
- Make a backup copy of %DVSDK_INSTALL_DIR%\src\misc\cmem.reg.
- Overwrite %DVSDK_INSTALL_DIR%\src\misc\cmem.reg with %DVSDK_INSTALL_DIR%\src\misc\cmem_c6accel.reg using the following command
- copy %DVSDK_INSTALL_DIR%\src\misc\cmem_c6accel.reg %DVSDK_INSTALL_DIR%\src\misc\cmem.reg
- Rebuild DVSDK (NOTE: it is not necessary to rebuild CMEM or any other source component) and the BSP and bring up the target with the new BSP image.
- Copy the directory %DVSDK_INSTALL_DIR%\src\c6accel_1_01_00_02\soc\app\test_files to a SD card.
- Insert the SD card with the test_files directory.
- Run c6accel_app.exe. If the application runs successfully, benchamarks for the various C6Accel algorithms are captured in the file \\Storage Card\\benchmarking.txt on the SD card.
- Restore the original cmem.reg for future DVSDK builds not requiring C6accel_app execution.
NOTE: You might see CMEM errors when the app starts. These can be safely ignored. This is because c6accel_app tries to allocate heap buffers from Block 1 of CMEM configured memory first and then from Block 0 if that fails. In cmem_c6accel.reg, CMEM is configured not to use Block 1, so any heap memory allocation from this block will fail but c6accel_app will subsequently try to allocate heap buffers from Block 0, which will succeed. If the default cmem.reg supplied in DVSDK is used to configure CMEM, c6accel_app cannot run because of insufficient heap memory configured in Block 0. In this case, c6accel_app will claim to have run successfully but in fact, no C6Accel algorithms would have been run.