****************************************************************************** * DM6467 Encoder Demo streaming over network * * Beta release * * readme.txt * * * * September 22 2009 * ****************************************************************************** Description =========== This is 1080i30 H.264 input encoding as 1080p30 demonstration with streaming over the network. The encoding does B frame encoding of the content. 1080p30 HP encode demo runs at 675 MHz of DM6467 EVM. The demo demonstartes taking the video input from the Video capture por from the component input and then encoding H.264 ES. The H.264 encoded streams are send over network which can played on PC using VLC player or on a set top box. This application support has been validated in the following configuration: DM6467 EVM, DSP 675 MHz, DDR 310 MHz Support the video file recording to H.264 ES Tests & Dependencies ==================== DSP Side : Tested on :- - DM6467 EVM -CCS 3.3 - DVSDK 1.40.01.32 Codec Engine 2.10.02 Framework Components 2.10.02 BIOS 5.32.01 xDAIS 6.10.01 DSP/BIOS Link 1.50 XDC 3.00.06 C64x+ Codegen Tools 6.0.16 Monta Vista Linux 4.0.1 Red Hat Enterprise Linux 4 Installation =============================== -Connect the serial cable between board and PC. -Connect Ethernet cable with the switch. -Start tera term or hyperterminal and start the session. -Make sure you have the DM6467 EVM running at 675 MHz. -Follow the following instructions for putting the uImage available in encode1080p.tar.gz package. -Start the tftp server. -Place the uImage_675MHz_vdce file contained in the attached tarball in your tftp directory. -Power on the board and stop u-boot from auto booting by pressing any key. -Setup the serverip variable -setenv serverip 192.168.0.101(PC ip address) -Setup the bootfile variable -setenv bootfile uImage_675MHz_vdce -Download the uImage file to the boards DDR. - "dhcp" -You should see the uImage file download. It is downloaded to address 0x80700000 and the last line of the download will give the size of the image. This size must be rounded -up to the next page. Each page is 2048bytes (0x800). For this version of the uImage the size should be rounded to 0x158000 -Erase the nand where the kernel is to be placed. - "nand erase 0xa0000 0x158000" -Write the uImage to nand. - "nand write 0x80700000 0xa0000 0x158000 " -Set the bootcmd variable to boot the kernel from flash. - "setenv bootcmd 'nboot 80700000 0 a0000;bootm' " - "setenv bootargs mem=96M console=ttyS0,115200n8 root=/dev/hda1 rw noinitrd ip=dhcp davincihd_capture.channel0_numbuffers=4 " -The kernel has now been updated in flash. -Type “boot” command on the prompt. -Login as root. The IP address of the board will be available at the login prompt. ==Run== -VLC Player Setup -Ensure that the PC and the EVM are on the same subnet -Start the VLC player on the PC -Open Network file as Media -> Open Network Ctrl-N? -Specify the Protocol as " UDP ". Specify the Address as " 239.10.10.10 ". Set the Port to " 5000 " -Press " Play" -VLC player will wait for the UDP multicast to start -Application Setup -ftp the encode1080p.tar.gz under /opt folder on the harddisk. -Run tar zxf encode1080p.tar.gz to uncompress the file. -cd encode1080p -Run the CMEM loader - ./encode1080p.sh -Run the Application - ./encode1080p -v demo1080p.264 -m demo1080p.ts -b 8000000 -t 3000 -u -The application supports the following command line options: <-v> - Specifies the video file to which the encoded bitstream is captured <-b> - Specifies the bit rate at which the input content is encoded <-t> - Specifies the time in seconds for which the capture will be triggered <-m> - Specifies the file to record the MPEG2 Transport Stream <-u> - Enables the Streaming through UDP Multicast <-h> - Provides the help information If no options are given, the application runs the encoder at 8 Mbps forever and discards the encoded frames. This specific option could be used for sanity check and stress tests. The options <-v>, <-m> and <-u> could be run together in any combination. For example: <-u> - Discards the H.264 Elementary Stream and sends the MPEG2 Transport Stream via UDP multicast <-v> & <-m> - Stores the H.264 ES ; Stores the MPEG2 TS <-v> & <-u> - Stores the H.264 ES ; Sends the MPEG2 TS via UDP multicast <-m> & <-u> - Discards the H.264 ES ; Stores the MPEG2 TS ; Sends the MPEG2 TS via UDP multicast <-v>, <-m> & <-u> - Stores the H.264 ES ; Stores the MPEG2 TS ; Sends the MPEG2 TS via UDP multicast Note: Ensure that the bitstreams are in the local hard disk of the EVM. If there is a write to/read from NFS, it will impact the system performance Build Info ================ Prerequisites -------------------- -User is familiar with the DVSDK installation and build procedure -DM6467 DVSDK is installed and built on the host -DM6467 EVM is up and running -DVSDK demo applications run successfully on the EVM Build Setup ====================== -Create a work directory - encode1080pstreaming -Untar the 1080P encode streaming package in the work directory -Update DVSDK_INSTALL_DIR in Rules.make to point to the actual DVSDK installation directory -Update MY_WORK_DIR in Rules.make to point to the work directory which was just created -Update LINUXKERNEL_INSTALL_DIR in Rules.make to point to the Linux kernel installation directory -Update EXEC_DIR in Rules.make to point to the target installation directory -Ensure all variables in the Rules.make are valid and accurate Building Linux Kernel ================================== -Replace the default VDCE driver in the Linux kernel installation directory with the driver given in this package. The default VDCE driver is at LINUXKERNEL_INSTALL_DIR/drivers/char -Build the Linux kernel. Refer to Sec 4.5 of the SPRUF88B? (DVEVM Setup Guide) -Copy the Linux kernel to the TFTP root directory Building Combo ========================== Goto $(MY_WORK_DIR)/combo Copy the codec RTSC package "h264fhdvenc" to packages/ti/sdo/codecs. Note: The H.264 encoder library h264fhdvenc_tii.l64P should be available in $(MY_WORK_DIR)/combo/packages/ti/sdo/codecs/h264fhdvenc/lib Update config.bld to point C64P? .rootDir to the C64x+ Codegen tools installation directory Update DVSDK_INSTALL_DIR in Makefile to point to the actual DVSDK installation directory Ensure that all the paths in the Makefile are correct and valid Run "gmake". The combo is generated in packages/ti/sdo/servers/encode1080p Building DMAI ===================== Goto $(MY_WORK_DIR)/dmai/packages/ti/sdo/dmai Run "gmake dm6467_al" Building Application Goto $(MY_WORK_DIR)/codecapps/dm6467/encode1080p Run "gmake" Build Options ============================= The following build options can be enabled in the Makefile: PROFILE_APP - Measures the encode time for each frame and displays it on the stdout PERF_DUMP - Dumps encode time for each frame into performance.csv file ENC_FRAMESIZE - Stores the size of each encoded frame into framesize.txt file H264_MULTISLICE - Enables the H.241 Multislicing feature