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.

Video application in C6657

Hi, 

    I want to develop a application to deal with C6657. But I don't know how to start. Which peripheral in C6657 should I use to fetch the source of Analog data from device(like camera)? SRIO maybe? And what I need to connect the camera to C6657?

      Thanks very much.

     Alex

  • Hi Alex,

    The C6657 does not have an interface that supports a camera directly. You could design an FPGA interface for the camera and then stream the data to the C6657 using SRIO or PCIE. 

    Regards, Bill

  • Hi Bill,

            Yeah, you inspired me. Thanks a lot

            Regards,

            Alex

  • Hi, Bill

          I want use QDMA to transfer 1K data , but I cannot complete the code. This is all I got. Would please modify it for me please. I would appreciate it very much. I referred an example in MCSDK, but it don't help for I don't have evm6657 ,I can't find the context of the function like“EDMA3_DRV_setQdmaTrigWord”, so I don't have a  clue of the functions in it . I just need an example CSL.

         Best wishes.

        Alex..

    int memoryTrans_QDMA(uint32_t *dstAddr)
    {
    CSL_Edma3Handle hModule;
    CSL_Edma3Obj edmaObj;
    CSL_Status status;
    CSL_Edma3ChannelHandle hChannel;
    CSL_Edma3ChannelObj chObj;
    CSL_Edma3ChannelAttr chAttr;
    CSL_Edma3ParamHandle hParamBasic;
    CSL_Edma3ParamSetup myParamSetup;

    // Module Initialization
    CSL_edma3Init(NULL);

    // Module Level Open
    hModule = CSL_edma3Open(&edmaObj,0,NULL,&status);
    // Enables QDMA Channel 1 for Global Region.
    CSL_edma3QDMAChannelEnable(hModule, CSL_EDMA3_REGION_GLOBAL, 1);

    //channel configuration!!!
    // Maps QDMA Channel 1 to Param ID Block 5.
    CSL_edma3MapQDMAChannelToParamBlock(hModule, 1, 5);

    // Configure QDMA Channel 1 Trigger Word as 7
    CSL_edma3SetQDMATriggerWord(hModule, 1, 7);

    //Is this right to open QDMA?
    // Open QDMA Channel 1.
    chAttr.regionNum = CSL_EDMA3_REGION_GLOBAL;
    chAttr.chaNum = 1;
    hChannel = CSL_edma3ChannelOpen(&chObj, 0, &chAttr, &status);
    if ((hChannel == NULL) || (status != CSL_SOK))
    {
    printf ("Error: Unable to open EDMA Channel:%d\n");
    return -1;
    }
    // Map the channel to PARAM Entry 5
    CSL_edma3HwChannelSetupParam(hChannel, 5);
    //....


    //PaRAM Configuration!!!
    // Obtain a handle to PARAM Entry 5
    hParamBasic = CSL_edma3GetParamHandle(hChannel,5,&status);
    //...
    // Setup the first param Entry (Ping buffer)
    myParamSetup.option = CSL_EDMA3_OPT_MAKE(CSL_EDMA3_ITCCH_DIS, \
    CSL_EDMA3_TCCH_DIS, \
    CSL_EDMA3_ITCINT_DIS, \
    CSL_EDMA3_TCINT_EN,\
    0,CSL_EDMA3_TCC_NORMAL,\
    CSL_EDMA3_FIFOWIDTH_NONE, \
    CSL_EDMA3_STATIC_EN, \
    CSL_EDMA3_SYNC_AB, \
    CSL_EDMA3_ADDRMODE_INCR, \
    CSL_EDMA3_ADDRMODE_INCR);
    myParamSetup.srcAddr = (uint32_t)(buffer) | 10000000;
    myParamSetup.aCntbCnt = CSL_EDMA3_CNT_MAKE(256,4);

    myParamSetup.dstAddr = (uint32_t)dstAddr;
    myParamSetup.srcDstBidx = CSL_EDMA3_BIDX_MAKE(256,256);
    myParamSetup.linkBcntrld = CSL_EDMA3_LINKBCNTRLD_MAKE(CSL_EDMA3_LINK_NULL,0);
    myParamSetup.srcDstCidx = CSL_EDMA3_CIDX_MAKE(0,0);
    // myParamSetup.cCnt = 1;

    // Configure the PARAM Entry with the setup information.
    CSL_edma3ParamSetup(hParamBasic,&myParamSetup);

    // Write trigger word
    CSL_edma3ParamWriteWord(hParamBasic, 7, myParamSetup.cCnt);

    //How to wait until data transfer finish?
    // wait until transfer complete, clear interrupt
    while(!(hModule->regs->TPCC_IPR & CSL_TPCC_TPCC_IPR_IPR0_MASK));
    hModule->regs->TPCC_ICR= (1 << CSL_TPCC_TPCC_ICR_ICR0_SHIFT);

    }

  • Hi Alex,

    I'm not a software expert. I'll pass this on to the team supporting software. In future, I would suggest that you start a new post. This question is unrelated enough that the correct people wouldn't find it easily.

    Regards, Bill

  • Hi,

    If you want to use CSL to configure EDMA, there is an example code under \MCSDK_02_01_02_06\pdk_C6678_1_1_2_6\packages\ti\csl\example that shows correct ways to do various transfers using EDMA.  For C6657, you simply need to link to the library under \MCSDK_02_01_02_06\pdk_C6657_1_1_2_6\packages\ti\csl\lib.

    So please refer to the examples for correct usage.

    Xiaohui

  • Hi, xiaohui

          Thank you very much. I installed BIOS_MCSDK but I don't have pdk_C6678 on my computer. Is this sofeware free for use? By the way the CCSv5.5 I am using is free too.

         Why I cannot find the folder pdk_C6657, maybe I did't install it rightly...

            Regards

  • Alex,

    Did you installed  MCSDK_02_01_02_06?  It should have pdk_C6678_1_1_2_6 in the installed directory.

    Xiaohui