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.

TMDSLCDK6748: receive and send audio data SAMPLE PER SAMPLE

Part Number: TMDSLCDK6748

Hi,

I bought the TMDSLCDK6748 evaluation board for my active noise cancellation project.

I've tried the "MCASP_Audio_lcdkOMAPL138_c674xExampleProject" from the SDK and also the "mcasp_c674x_c6748_lcdkC6748" example from the starterware and both are working.

The problem is, that this examples work with transfering FRAMES.

I would like to have a SAMPLE PER SAMPLE example because of the acitve noise cancelling application. Is there something like this or could you give me a short code example how to receive and send samples one by one?

I've searched a lot in forums and also books and so on, but don't know how to proceed...

Thank you very much.

  • Christoph,

    Will get back to you.

    Lali
  • Christoph,

    Here's a suggestion to do a SAMPLE per SAMPLE:

    1. Change the BUFLEN in audioSample_io.c from 1024 to 1.
    2. Rebuild the project.

    This will allow you to get a frame with 1 sample in it.
    Hope this helps.

    Lali
  • Hi Lali,

    Thanks for your response.

    1) I tried your solution, but it didn't work.
    Building and debuging is working, but there is no sound at the LINE OUT when setting BUFLEN to 1.

    I also tried different combination of BUFLEN and BUFALIGN.
    It works with BUFLEN = 8 and BUFLEN = 64, and so on... but not with BUFLEN = 1.

    2) Another question is, how can I use all 4 inputs independent of each other (right, left MIC IN and right, left LINE IN) and both outputs (right, left LINE OUT), because i want to use the board for a MIMO-ANC System?
    So how do I have to change the code?
    Do I have to add channels at the Mcasp_ChanParams in mcasp_cfg.c?
    And if yes, how do I do this correctly?

    Thank you very much!

    Christoph
  • Hi,

    Maybe someone cold help me in this case, because the examples from the SDK and the Starterware aren't very userfriendly or easy to use for beginners at working with dsp-boards.

    Aren't there simple examples for the TMDSLCDK6748 like those who come with the TMS320C6713 DSK from Spectrum Digital, e.g. the "sin8_LED" example? (I would use the TMS320C6713, but the board has too less analog inputs...)

    Thank you very much!

    BR, Christoph
  • Christoph,

    The EDMA3 may require the minimum transfer block size. Have you tried BUFLEN = 2 or 4?
    If that works, then you can use 2 or 4 samples in a frame, assuming your algorithm can tolerate 2 or 4 samples in a chunk.

    Otherwise, you would have to implement the sample by sample approach. Will need to use the interrupts (or polling) from McASP instead of EDMA3 to be informed when a sample is ready.

    Fortunately, there is a McASP polling example that uses this approach in Processor SDK. It is located at \pdk_omapl137_1_0_3\packages\ti\board\diag\mcasp\src\mcasp_poll_test.c .

    Hope this helps.

    Lali
  • Lalo,

    Thank you very much.

    A polling or interrupt example is what i'm searching for.

    My only question is, how to run the mcasp_poll_test.c example?

    I've included all necessary files, but some identifier are missing and a lot of functions are declared implicitly (see attached file). I've also tried it with additional peripheral information, like the soc_C6748.h file, but without any success.

    Tank you for your help!

    Christoph

    Description	Resource	Path	Location	Type
    #20 identifier "CSL_BOOTCFG_PADCONFIG0_MUXMODE_MASK" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 113	C/C++ Problem
    #20 identifier "CSL_BOOTCFG_PADCONFIG0_MUXMODE_SHIFT" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 113	C/C++ Problem
    #20 identifier "CSL_I2C_0_DATA_CFG" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 128	C/C++ Problem
    #20 identifier "CSL_I2C_0_DATA_CFG" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 143	C/C++ Problem
    #20 identifier "CSL_I2C_0_DATA_CFG" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 159	C/C++ Problem
    #20 identifier "CSL_I2C_0_DATA_CFG" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 379	C/C++ Problem
    #20 identifier "CSL_MCASP_1_CFG_REGS" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 199	C/C++ Problem
    #20 identifier "CSL_MCASP_1_CFG_REGS" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 299	C/C++ Problem
    #20 identifier "CSL_MCASP_1_CFG_REGS" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 333	C/C++ Problem
    #20 identifier "CSL_MPU_INTC_MPU_DISTRIBUTOR_REGS" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 101	C/C++ Problem
    #20 identifier "CSL_MPU_INTC_MPU_PHYS_CPU_IF_REGS" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 100	C/C++ Problem
    #20 identifier "CSL_UART_0_REGS" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 88	C/C++ Problem
    #20 identifier "hBootCfg" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 113	C/C++ Problem
    #20 identifier "MCASP_PIN_ACLKR" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 274	C/C++ Problem
    #20 identifier "MCASP_PIN_ACLKX" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 272	C/C++ Problem
    #20 identifier "MCASP_PIN_AFSR" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 273	C/C++ Problem
    #20 identifier "MCASP_PIN_AFSX" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 271	C/C++ Problem
    #20 identifier "MCASP_PIN_AHCLKX" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 275	C/C++ Problem
    #20 identifier "MCASP_RX_CLK_INTERNAL" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 230	C/C++ Problem
    #20 identifier "MCASP_RX_CLK_POL_FALL_EDGE" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 231	C/C++ Problem
    #20 identifier "MCASP_RX_CLKFAIL" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 287	C/C++ Problem
    #20 identifier "MCASP_RX_DMAERROR" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 286	C/C++ Problem
    #20 identifier "MCASP_RX_FS_INT_BEGIN_ON_RIS_EDGE" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 224	C/C++ Problem
    #20 identifier "MCASP_RX_FS_WIDTH_BIT" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 223	C/C++ Problem
    #20 identifier "MCASP_RX_MODE_NON_DMA" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 204	C/C++ Problem
    #20 identifier "MCASP_RX_OVERRUN" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 289	C/C++ Problem
    #20 identifier "MCASP_RX_SYNCERROR" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 288	C/C++ Problem
    #20 identifier "MCASP_TX_CLK_INTERNAL" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 238	C/C++ Problem
    #20 identifier "MCASP_TX_CLK_INTERNAL" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 246	C/C++ Problem
    #20 identifier "MCASP_TX_CLK_INTERNAL" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 299	C/C++ Problem
    #20 identifier "MCASP_TX_CLK_POL_RIS_EDGE" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 239	C/C++ Problem
    #20 identifier "MCASP_TX_CLK_POL_RIS_EDGE" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 247	C/C++ Problem
    #20 identifier "MCASP_TX_CLKCHCK_DIV1" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 232	C/C++ Problem
    #20 identifier "MCASP_TX_CLKFAIL" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 282	C/C++ Problem
    #20 identifier "MCASP_TX_DMAERROR" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 281	C/C++ Problem
    #20 identifier "MCASP_TX_FS_INT_BEGIN_ON_RIS_EDGE" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 227	C/C++ Problem
    #20 identifier "MCASP_TX_MODE_NON_DMA" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 207	C/C++ Problem
    #20 identifier "MCASP_TX_STAT_DATAREADY" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 307	C/C++ Problem
    #20 identifier "MCASP_TX_SYNCERROR" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 283	C/C++ Problem
    #20 identifier "MCASP_TX_UNDERRUN" is undefined	mcasp_poll_test.c	/McAsp_Polling	line 284	C/C++ Problem
    gmake: *** [mcasp_poll_test.obj] Error 1	McAsp_Polling		 	C/C++ Problem
    gmake: Target 'all' not remade because of errors.	McAsp_Polling		 	C/C++ Problem
    #112-D statement is unreachable	mcasp_poll_test.c	/McAsp_Polling	line 352	C/C++ Problem
    #190-D enumerated type mixed with another type	.ccsproject	/McAsp_Polling	line 222, external location: C:\TI\SDK_RTOS_OMAPL138_LCDK\pdk_omapl138_1_0_6\packages\ti\csl\src\ip\arm_gic\V0\csl_armGicAux.h	C/C++ Problem
    #225-D function "CSL_A15_INIT_copyVectorTable" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 106	C/C++ Problem
    #225-D function "MCASP_PIN_AXR" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 276	C/C++ Problem
    #225-D function "McASPIsSerializerRcvReady" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 333	C/C++ Problem
    #225-D function "McASPIsSerializerXmtReady" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 339	C/C++ Problem
    #225-D function "McASPPinDirInputSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 277	C/C++ Problem
    #225-D function "McASPPinDirOutputSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 271	C/C++ Problem
    #225-D function "McASPPinMcASPSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 269	C/C++ Problem
    #225-D function "McASPRxBufRead" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 336	C/C++ Problem
    #225-D function "McASPRxClkCfg" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 230	C/C++ Problem
    #225-D function "McASPRxClkCheckConfig" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 232	C/C++ Problem
    #225-D function "McASPRxClkPolaritySet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 231	C/C++ Problem
    #225-D function "McASPRxClkStart" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 299	C/C++ Problem
    #225-D function "McASPRxEnable" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 311	C/C++ Problem
    #225-D function "McASPRxFmtGet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 210	C/C++ Problem
    #225-D function "McASPRxFmtI2SSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 203	C/C++ Problem
    #225-D function "McASPRxFmtSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 212	C/C++ Problem
    #225-D function "McASPRxFrameSyncCfg" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 223	C/C++ Problem
    #225-D function "McASPRxIntEnable" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 286	C/C++ Problem
    #225-D function "McASPRxReset" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 199	C/C++ Problem
    #225-D function "McASPRxSerActivate" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 304	C/C++ Problem
    #225-D function "McASPRxTimeSlotSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 255	C/C++ Problem
    #225-D function "McASPSerializerRxSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 262	C/C++ Problem
    #225-D function "McASPSerializerTxSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 261	C/C++ Problem
    #225-D function "McASPTxBufWrite" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 343	C/C++ Problem
    #225-D function "McASPTxClkCfg" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 238	C/C++ Problem
    #225-D function "McASPTxClkCfg" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 246	C/C++ Problem
    #225-D function "McASPTxClkCheckConfig" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 240	C/C++ Problem
    #225-D function "McASPTxClkCheckConfig" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 248	C/C++ Problem
    #225-D function "McASPTxClkPolaritySet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 239	C/C++ Problem
    #225-D function "McASPTxClkPolaritySet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 247	C/C++ Problem
    #225-D function "McASPTxClkStart" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 300	C/C++ Problem
    #225-D function "McASPTxEnable" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 310	C/C++ Problem
    #225-D function "McASPTxFmtGet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 214	C/C++ Problem
    #225-D function "McASPTxFmtI2SSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 206	C/C++ Problem
    #225-D function "McASPTxFmtSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 216	C/C++ Problem
    #225-D function "McASPTxFrameSyncCfg" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 226	C/C++ Problem
    #225-D function "McASPTxIntEnable" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 281	C/C++ Problem
    #225-D function "McASPTxReset" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 200	C/C++ Problem
    #225-D function "McASPTxRxClkSyncEnable" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 253	C/C++ Problem
    #225-D function "McASPTxSerActivate" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 303	C/C++ Problem
    #225-D function "McASPTxStatusGet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 307	C/C++ Problem
    #225-D function "McASPTxTimeSlotSet" declared implicitly	mcasp_poll_test.c	/McAsp_Polling	line 256	C/C++ Problem
     declared implicitly

  • Christoph

    My only question is, how to run the mcasp_poll_test.c example?

    Please see http://software-dl.ti.com/processor-sdk-rtos/esd/docs/05_01_00_11/rtos/Board_EVM_Abstration.html#diagnostics mcasp_poll_test.c is part of the DIAGNOSTICS package.

    Lali

  • Lali,

    I don't want to only build a .out file tu run it with the board.
    Which additional files do I need for building and debuging the "mcasp_poll_test.c" example?
    Because when I include all header file paths which are #included in the main c.file, I have a lot of errors because of undefined identifier.

    Thank you,
    Christoph
  • Hi Christoph,

    Please refer to the makefile located at for \pdk\packages\ti\board\diag\mcasp\build\evmOMAPL137\c674x to see what needs to be added to the CCS project. If you are getting undefined errors, I suspect you haven't linked the required libraries.