diff --git a/pasdk/test_dsp/framework/audioStreamOutProc.c b/pasdk/test_dsp/framework/audioStreamOutProc.c
index 51c045ed2d2af3dd56266d918256ec1c42eaf9c2..a4e9327dfd12af59a5d1c02298a944c9a6fcce64 100644 (file)
//Int32 gNumPfpAsot1=0; // debug
// debug
-//#include "evmc66x_gpio_dbg.h"
-//#include "dbgCapAf.h"
+#include "evmc66x_gpio_dbg.h"
//#include "ioConfig.h"
if (events & Evt_Id_AsotTxMcaspEdma)
{
gProcDecOutState_EvtTxMcaspEdma_cnt++;
- events &= Evt_Id_AsotTxMcaspEdma; // clear event
+ events &= ~Evt_Id_AsotTxMcaspEdma; // clear event
+
+#if 1 // (***) FL: shows timing of Output (Tx McASP EDMA)
+ // (***) debug // B8
+ {
+ static Uint8 toggleState = 0;
+ if (toggleState == 0)
+ GPIOSetOutput(GPIO_PORT_0, GPIO_PIN_106);
+ else
+ GPIOClearOutput(GPIO_PORT_0, GPIO_PIN_106);
+ toggleState = ~(toggleState);
+ }
+#endif
// Process Output
status = PAF_ASOT_procDecOut(pP, pQ, pAsotCfg, &procOutFirstTime, asopFrameCount);
*pOutDevSel = FALSE;
return status;
}
-
- //// I/O physical layer prime operation required by McASP LLD
- //// FL, New IO: API for single Output
- //asopIoPhyPrime(&pAsotCfg->pIoOut[zO]);
}
pAstCfg->xOut[zO].outBufStatus.sioSelect = device | 0x80;
}
}
- // FL, New IO: assumption here is Output frame size (output frame size)
- // & McASP Tx clock dividers are set correctly (stream)
- // before IO prime, i.e. IO prime is not set to default
+ // FL, New IO: assumption here is Tx McASP clock dividers &
+ // Output frame size are set correctly before IO prime,
+ // i.e. IO prime is not using defaults
+ // FL, New IO: API for single Output
+
// I/O physical layer prime operation required by McASP LLD
- // FL, New IO: API for single Output
asopIoPhyPrime(&pAsotCfg->pIoOut[zO]);
return ASOP_SOK;
if (status == ASOP_SOK)
{
- // Execute encode
- errno = asopDecOutProcEncode(pP, pQ, pAsotCfg, frame);
- if (errno < 0)
+ // Update Output buffer configuration
+ errno = asopUpdateOutBufConfig(&pAstCfg->xOut[zO], &pAsotCfg->pIoOut[zO]);
+ if (errno)
{
status = errno;
}
+ else
+ {
+ // Execute encode
+ errno = asopDecOutProcEncode(pP, pQ, pAsotCfg, frame);
+ if (errno < 0)
+ {
+ status = errno;
+ }
+ else
+ {
+ // Mark Output buffers write complete
+ errno = asopMarkOutBuffsWriteComplete(&pAstCfg->xOut[zO], &pAsotCfg->pIoOut[zO]);
+ if (errno)
+ {
+ status = errno;
+ }
+ }
+ }
}
if (status == ASOP_SOK)