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.

  • Resolved

[OMAPL138] Hello DSPLink Program

Hello,

I am looking for most basic examples on DSPLink specially for OMAPL138

(Hawkboard) For both Linux/Arm Side & DSP Side.

 

Examples specially what a DSP books teaches,Like convolution ,cross correlation ,FFT etc

even much simple apps like multiply a location of shared area by contanst by DSP etc will too suffice.

Sample programs in the DVSDK is too complex to be understood by students/new to 

DSP/ARM (OMAP).

 

Any help on this program,API documentation for Linux to Use dsplinkk.ko etc 

would be greatly appreciated.

 

Thx,

Alok

 

  • In reply to Deepali Uppal:

    Hi Deepali,

    Thanks, but I don't understand how this could happen, as I never touched the settings in tci and tcf file besides changing SDRAM to DDR.

    The strange thing is that sometime can see this: Entered helloDSP_Create ()

    sometime can't.

     

    clliu

  • In reply to clliu:

    Clliu,

    If you suspect DSPLink API , you can enable trace. See here: http://processors.wiki.ti.com/index.php/Enabling_trace_in_DSPLink

    If you suspect other code, you will have to add some more print based logging.

    Deepali

  • In reply to Deepali Uppal:

    It's been a few days, no much progress.

    What I have done is:

    1, Re-configured the dsplink using command:

    perl dsplinkcfg.pl --platform=OMAPL138 --nodsp=1 --dspcfg_0=OMAPL138GEMSHMEM --dspos_0=DSPBIOS5XX --gppos=ARM --comps=ponslrmc --trace=1 --DspTskMode=1

    This turns on the trace function.

    2, Re-build dsplink following this link: http://processors.wiki.ti.com/index.php/Building_DSPLink

     Made some modifications to use 3 script files instead of 2,

    paths.sh:

    #!/bin/sh

    # paths.tcsh

    # This file simply creates environment variables.  We will utilize

    # these variables in build_dsplink.tcsh by passing them on the

    # command line.

     

    export PERL_DIR=/usr/bin

     

    export ARM_BASE_BUILDOS=${HOME}/OMAP-L138_arm_1_00_00_11/DaVinci-PSP-SDK-03.20.00.06/src/kernel/linux-03.20.00.06

    export ARM_BASE_TOOLCHAIN=${HOME}/CodeSourcery/Sourcery_G++_Lite

    export ARM_BASE_CGTOOLS=${ARM_BASE_TOOLCHAIN}/bin

     

    # ARM_CGTOOLS_NAME is just a "helper variable" (i.e. not directly used in make)

    export ARM_CGTOOLS_NAME=arm-none-linux-gnueabi

     

    # ARM_CGTOOLS_VERSION is just a "helper variable" (i.e. not directly used in make)

    export ARM_CGTOOLS_VERSION=4.3.3

     

    export ARM_COMPILER=$ARM_BASE_TOOLCHAIN/bin/$ARM_CGTOOLS_NAME-gcc

    export ARM_LINKER=$ARM_BASE_TOOLCHAIN/bin/$ARM_CGTOOLS_NAME-ld

    export ARM_ARCHIVER=$ARM_BASE_TOOLCHAIN/bin/$ARM_CGTOOLS_NAME-ar

    export ARM_OSINC_TARGET=$ARM_BASE_TOOLCHAIN/$ARM_CGTOOLS_NAME/include

    export ARM_OSINC_PLATFORM=$ARM_BASE_TOOLCHAIN/lib/gcc/$ARM_CGTOOLS_NAME/$ARM_CGTOOLS_VERSION/include

     

    export DSP_BASE_CGTOOLS=${HOME}/OMAP-L138_arm_1_00_00_11/cg6x_6_1_9

    export DSP_BASE_SABIOS=${HOME}/OMAP-L138_arm_1_00_00_11/bios_5_41_02_14

     

    build_dsplink_gpp:

    #!/bin/sh

    # You shouldn't need to modify this file.  Only your paths should change

    # and that should be done in paths.tcsh.

    #

    # You should make this file executable and putting it in the "dsplink"

    # directory for your build.

    source ./paths.sh

     

    export MAKE_ARGS_ARM="DSPLINK=$DSPLINK BASE_CGTOOLS=$ARM_BASE_CGTOOLS TOOL_PATH=$ARM_BASE_CGTOOLS COMPILER=$ARM_COMPILER LD=$ARM_LINKER ARCHIVER1=$ARM_LINKER ARCHIVER2=$ARM_ARCHIVER LINKER=$ARM_COMPILER KERNEL_DIR=$ARM_BASE_BUILDOS BASE_BUILDOS=$ARM_BASE_BUILDOS BASE_OSINC=$ARM_BASE_BUILDOS/include OSINC_PLATFORM=$ARM_OSINC_PLATFORM OSINC_TARGET=$ARM_OSINC_TARGET BASE_PERL=$PERL_DIR"

     

    make -s -C $DSPLINK/gpp/src $1 $MAKE_ARGS_ARM

    build_dsplink_dsp:

    #!/bin/sh

    # You shouldn't need to modify this file.  Only your paths should change

    # and that should be done in paths.tcsh.

    #

    # You should make this file executable and putting it in the "dsplink"

    # directory for your build.

    source ./paths.sh

     

    export MAKE_ARGS_DSP="DSPLINK=$DSPLINK BASE_CGTOOLS=$DSP_BASE_CGTOOLS BASE_SABIOS=$DSP_BASE_SABIOS"

     

    make -s -C $DSPLINK/dsp/src $1 $MAKE_ARGS_DSP

     

    3, re-build helloDSP application for both GPP and DSP sides.

    when running the program, got thse messages from terminal console:

    ......

    ......

    Leaving _RingIO_init ()         status [0x8100]
    Entered _SYNC_USR_leaveCS ()
            csObj   [0x29020]
    Leaving _SYNC_USR_leaveCS ()    status [0x8000]
    Leaving PROC_attach ()  status [0x8000]
    Entered POOL_open ()
            poolId  [0x0]
            params  [0x281e0]
    Entered _SYNC_USR_enterCS ()
            csObj   [0x29020]
    Leaving _SYNC_USR_enterCS ()    status [0x8000]
    Entered DRV_Invoke ()
            drvObj  [0x29008]
            cmdId   [Á18e03f]

    or like this:

    ......

    ......

    Leaving _RingIO_init ()         status [0x8100]
    Entered _SYNC_USR_leaveCS ()
            csObj   [0x29020]
    Leaving _SYNC_USR_leaveCS ()    status [0x8000]
    Leaving PROC_attach ()  status [0x8000]
    Entered POOL_open ()
            poolId  [0x0]
            params  [0x281e0]
    Entered _SYNC_USR_enterCS ()
            csObj   [0x29020]
    Leaving _SYNC_USR_enterCS ()    status [0x8000]
    Entered DRV_Invoke ()
            drvObj  [0x29008]
            cmdId   [0xc018e03f]
            arg1    [0xbed8ac08]
            arg2    [0x0]
    Status: 8000
    Leaving DRV_Invoke ()   status [0x8000]
    EîÑ•Éÿ

    Each time it hung at almost the same place, please nothce the unreadable charactors.

    If run it with trace disabled, got these:

    ----- Before helloDSP_Main
    ========== Sample Application : helloDSP ==========
    Entered helloDSP_Create ()
    ----- After PROC_setup


    ----- Before helloDSP_Main
    ========== Sample Application : helloDSP ==========
    Entered helloDSP_Create ()
    ----- After PROC_setup


    root@arago:/media/ram# ./helloDSPgpp ./helloDSP.out 2
    ----- Before helloDSP_Main
    ========== Sample Application : helloDSP ==========
    Entered helloDSP_Create ()
    ----- After PROC_setup
    ----- After PROC_attach
    ----- After POOL_open
    ----- After MSGQ_open
    ----- After MSGQ_setErrorHandler
    ----- doDspCtrl !=  DSP_BootMode_NoBoot
    ----- After PROC_load


    root@arago:/media/ram# ./helloDSPgpp ./helloDSP.out 2
    ----- Before helloDSP_Main
    ========== Sample Application : helloDSP ==========
    Entered helloDSP_Create ()
    ----- After PROC_setup
    ----- After PROC_attach
    ----- After POOL_open
    ----- After MSGQ_open
    ----- After MSGQ_setErrorHandler
    ----- doDspCtrl !=  DSP_BootMode_NoBoot

    The messages started with dashes were added by me.

    My questions:

    1, the dsp application should be given the absolute name or just the name itself(it 's in the same directory with gpp exectable)? before adding './' to the dsp application name, proc_load() was never executed.

    As I am unable to boot the experimentor board through NFS, still failed after googling and trying many times, i copy the necessary files to the /media/ram using tftp and run there. The directory /home/root is too small to save the files. So:

    2, Is /media/ram the right place to run application?

    3, Why /home/root is so small?

    4, Combining 2 & 3, is the linux pre-built on the experimentor board ready to run application(sorry for this question, it may be out of boundary)?

    5, Should I have to re-build kernel and rootfs for running application on the board standalone?

    6, My current testing setup is: Windows XP host + Fedora 12 VMware client, the board connects to XP through a USB-ethernet adapter, compilation is done in Fedora, the biggest problem is the board can't ping fedora. Tried setting the NAT and brighed(Vnet0 + USB-ethernet adapter) mode of fedora network, no luck. Now have to ftp files to XP and tftp get to put them o the board. Any hints?

    Thanks,

     

     

     

     

     

     

     

     

  • In reply to clliu:

     

    I have a few questions.

    1) Have you updated the mem variable in the Linux bootargs for the memory map that you are using?

    2) Can you share the BIOS version that you are using? I will check if the there is an overlap in the default timer which could be causing the hang?

    Deepali

  • In reply to clliu:

    Hi,clliu :

          Do you solve this problem? I am facing to this problem now. Can you give me some advices? Thank you!

  • In reply to Deepali Uppal:

    Hi,Deepali:

          Can you give me some advices to solve this problem, I am facing to it now . Thank you !

  • In reply to Deepali Uppal:

    Hi,Deepali:

          Can you give me some advices to solve this problem, I am facing to it now . Thank you !

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.