Hardware setup - LeopardBoard DM365

From RidgeRun Developer Connection

Revision as of 21:45, 12 July 2011 by Mmadrigal (Talk | contribs)
Jump to:navigation, search

This page shows the steps necessary to setup the different hardware modules available for the LeopardBoard DM365. The instructions provided are based in the SDK 2011Q2 for LeopardBoard DM365.

Contents

Capture Modules

5Mpx Camera Module - LI-5M03

Figure 1. LI-5M03 camera module.

In order to activate the camera module follow the next steps:

1. Activate the MT9P031 sensor driver. You can find this driver at the following path into the configuration window:

    -> Kernel configuration                                                
        -> Device Drivers                                                    
          -> Multimedia support (MEDIA_SUPPORT [=y])                         
            -> Video capture adapters (VIDEO_CAPTURE_DRIVERS [=y]) 

And select the option mt9p031 support as is shown in the figure 2.

Figure 2. SDK MT9P031 driver.

2. Once you have selected the driver for your camera module exit the configuration window and save the changes made.

3. Rebuild your SDK by running the make command and install it into the board running the make install command.

4. In order to test the module has been built correctly you can run the following GStreamer pipeline which will record 1000 buffers of video and store them into a video file called video_camera_capture.mp4. Once the video has been recorded it can be played using any multimedia player such as VLC or mplayer.

FILE_NAME=video_camera_capture.mp4

gst-launch -e v4l2src always-copy=false num-buffers=1000 ! 'video/x-raw-yuv,format=(fourcc)NV12, width=1280, height=720, framerate=(fraction)23/1' ! \
dmaiaccel ! dmaienc_h264 encodingpreset=2 ratecontrol=4 ! dmaiperf ! queue ! qtmux ! filesink location=$FILE_NAME

Video composite input board - LI-VI365

There is a video composite input board which allows to capture video from either a composite input or a S-Video input. The module is shown in the figure 3.

Figure 3. LI-VI365 video capture module.

In order to use this module follow the next steps:

1. In order to activate this module you need to activate the Texas Instruments TVP514x video decoder driver in the following path into the configuration window of the SDK (See figure 4):

     -> Kernel configuration                                                
        -> Device Drivers                                                    
          -> Multimedia support (MEDIA_SUPPORT [=y])                        
            -> Video capture adapters (VIDEO_CAPTURE_DRIVERS [=y])           
              -> Autoselect pertinent encoders/decoders and other helper     
                -> Encoders/decoders and other helper chips


Figure 4. Selecting driver for LI-VI365 video capture module.

Note: in order to use the LI-VI365 module it is necessary to desactivate the MT9P031 camera sensor driver.

2. Once you have selected the driver for the module, you can save all the changes and rebuild your SDK by running the make command.

3. Install the SDK into your board by running the make install command.

4. Start your board with the module connected.

5. In order to verify that the new module was installed correctly you can run the following GStreamer command which will capture a video from the composite input of the module and record it to a video file called composite_capture_module.mp4, then you can reproduce the video file with any multimedia application such as VLC or mplayer.

FILE_NAME=composite_capture_module.mp4

gst-launch -e v4l2src input-src=composite always-copy=false num-buffers=1000 ! 'video/x-raw-yuv,format=(fourcc)NV12, width=640, height=480,pitch=736' \
! queue ! dmaiaccel ! dmaienc_h264 encodingpreset=2 ratecontrol=4 ! qtmux ! filesink location=$FILE_NAME

Video HD component input board - LI-HDI365

It is available a video component input board for the LeopardBoard DM365 which is shown in the following figure.

Figure 5. LI-HDI365 video capture module.

In order to activate the driver for this module follow the next steps:

1. Ensures the drivers for the LI-5M03 camera module and the LI-VI365 video composite capture modules are disable in the configuration window.

2. Select the driver by activating the Texas Instruments TVP5150 video decoder option in the following path

      -> Kernel configuration                                                                                    
        -> Device Drivers                                                                                        
          -> Multimedia support (MEDIA_SUPPORT [=y])                                                             
            -> Video capture adapters (VIDEO_CAPTURE_DRIVERS [=y])                                               
              -> Autoselect pertinent encoders/decoders and other helper chips (VIDEO_HELPER_CHIPS_AUTO [=n])    
                -> Encoders/decoders and other helper chips

As is shown in the following figure

Figure 5. LI-HDI365 video capture module.

3. Save the changes and rebuild the SDK running the make command.

4. Install the SDK into the board by running the make install command.

5. Start your board with the module connected. In order to verify it is working properly you can run the following GStreamer pipeline which will capture the composite video from the module and record it to a video file called component_capture_module.jpeg. You can reproduce this file using any media player such as VLC or mplayer.

FILE_NAME=component_capture_module.jpeg

gst-launch -e v4l2src input-src=component always-copy=false num-buffers=1000 ! 'video/x-raw-yuv,format=(fourcc)NV12, width=1280, height=720,framerate=(fraction)23/1' \
! queue ! dmaiaccel ! dmaienc_h264 encodingpreset=2 ratecontrol=4 ! qtmux ! filesink location=$FILE_NAME

Display Modules

DVI output module - LI-DVI1

One of the capabilities on what video displaying refers to, in dm365 leopard board, is to display by using a DVI format.

First of all, it is necessary to attach the LI-DVI1 module to the Parallel RGB (PRGB) port, which is numbered J7, so it is possible to have the right hardware configuration.

Figure 1. LI-DVI1 DVI output module for dm365 leopard.


Configuration

DVI configuration is achieved after three basic steps, both at RidgeRung's SDK configuration menu.

1) Make sure that the dm365_generic_prgb_encoder is selected to be built. This can be checked at:

Kernel configuration -> Device Drivers -> Multimedia support -> Video capture adapters -> Generic PRGB Encoder support 
Figure 2. Generic PRGB Encoder enabling.

2) Set the video output to work as PRGB, then choose the max resolution size that is planed to be used for this output (480P, 720P, 1080I).

Architecture configurations -> Video Output (PRGB)
Architecture configurations -> Maximum Video Output Buffer Size    
Figure 3. Generic PRGB output and Maximum Video Output Buffer.

3) Set the standard configuration at kernel extra arguments.

Kernel configuration -> Extra kernel arguments   
Figure 4. Generic PRGB encoder data setup.

At this point it is important to notice that, for setting the standard, it is required to identify the module to which the information is going to, This is made by the instruction "dm365_generic_prgb_encoder.mode="

A couple examples of standards to be configured would be:

dm365_generic_prgb_encoder.mode=1280x720MR-16@60
dm365_generic_prgb_encoder.mode=720x480MR-16@30
Navigation
Toolbox