summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 370be03)
raw | patch | inline | side by side (parent: 370be03)
author | Frank Livingston <frank-livingston@ti.com> | |
Mon, 15 Aug 2016 19:45:41 +0000 (14:45 -0500) | ||
committer | Frank Livingston <frank-livingston@ti.com> | |
Mon, 15 Aug 2016 19:45:41 +0000 (14:45 -0500) |
diff --git a/procsdk_audio_x_xx_xx_xx/common/audioStreamProc_config.h b/procsdk_audio_x_xx_xx_xx/common/audioStreamProc_config.h
index 533faa6ab62d776ab19871ac9756be044fc4f6c0..1e8ccba84a3a6ede23ec9def468558435c27b46e 100644 (file)
} PAF_AST_Stream;
typedef struct PAF_AST_OutBuf {
- SIO_Handle hTxSio; // (*** ?) FL: SIO
+ SIO_Handle hTxSio;
PAF_OutBufConfig outBufConfig;
PAF_OutBufConfig *pOutBuf; /* Decode Processing Temporary */
PAF_OutBufStatus outBufStatus;
diff --git a/procsdk_audio_x_xx_xx_xx/common/audioStreamProc_params.h b/procsdk_audio_x_xx_xx_xx/common/audioStreamProc_params.h
index 0d57f9f44f3b93c16d7710ba4494b6b3e8c566a8..7499db2b4c50b04d5843b41c554abdadfb02fa44 100644 (file)
Int (*passProcessingCopy) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *);
Int (*autoProcessing) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, ALG_Handle);
- //FL: Source select index takes place of ALG_Handle. Temporary retain ALG_Handle.
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeProcessing) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle);
//Int (*decodeProcessing) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle, Int);
Int (*decodeProcessing) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int);
Int (*decodeCommand) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *);
Int (*encodeCommand) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *);
- //FL: Source select index takes place of ALG_Handle. Temporary retain ALG_Handle.
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeInit) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *);
//Int (*decodeInit) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int);
Int (*decodeInit) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int);
-
+
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeInfo) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
Int (*decodeInfo) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int);
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeInfo1) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
Int (*decodeInfo1) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int);
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeInfo2) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
Int (*decodeInfo2) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int);
Int (*decodeCont) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
- //FL: Source select index takes place of ALG_Handle. Temporary retain ALG_Handle.
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeDecode) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
//Int (*decodeDecode) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int, Int);
Int (*decodeDecode) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int, Int);
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeStream) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
Int (*decodeStream) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int);
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeEncode) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
Int (*decodeEncode) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int);
+ // FL: Source select index takes place of ALG_Handle.
//Int (*decodeFinalTest) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, ALG_Handle *, Int, Int);
Int (*decodeFinalTest) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int);
Int (*stopOutput) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *);
Int (*setCheckRateX) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int);
Int (*streamChainFunction) (const struct PAF_AST_Params *, const struct PAF_AST_Patchs *, struct PAF_AST_Config *, Int, Int, Int);
- Int (*deviceAllocate) (SIO_Handle *, int, int, int, Ptr); // FL: (***? ) SIO
- Int (*deviceSelect) (SIO_Handle *, int, int, Ptr); // FL: (***? ) SIO
+ Int (*deviceAllocate) (SIO_Handle *, int, int, int, Ptr);
+ Int (*deviceSelect) (SIO_Handle *, int, int, Ptr);
+ // FL: change ALG_Handle to zone index
//Int (*computeFrameLength) (ALG_Handle, Int, Int);
- Int (*computeFrameLength) (Int, Int, Int); //FL: change ALG_Handle to zone index
+ Int (*computeFrameLength) (Int, Int, Int);
- Int (*updateInputStatus) (SIO_Handle, PAF_InpBufStatus *, PAF_InpBufConfig *); // (***? ) FL: SIO
+ Int (*updateInputStatus) (SIO_Handle, PAF_InpBufStatus *, PAF_InpBufConfig *);
Int (*copy) (Uns, PAF_InpBufConfig *, Uns, PAF_OutBufConfig *);
#ifdef HSE
index 55b1d71ee18b024ebcc55212a35485533800633d..37d890133dc23565ff67f0de6f7239705648dcb7 100644 (file)
#include "fwkPort.h"
// FL: Temporary, 1st parameter for audioStream1Task().
-// FL: Need to remove this since SYS/BIOS 6.21 doesn't allow more than 2 parameters for a task.
+// FL: Need to remove first task parameter since SYS/BIOS 6.45 doesn't allow more than 2 parameters for a task.
Int gBetaPrimeValue=0;
far LoggerBuf_Struct trace;
diff --git a/procsdk_audio_x_xx_xx_xx/common/paf_alg_create.c b/procsdk_audio_x_xx_xx_xx/common/paf_alg_create.c
index 01bbde0f6f2f0f6cb6be5e3090de0a839991a405..8c5f28eccfa3d6be6ced6818af54da50413ffa1f 100644 (file)
#include <xdc/runtime/Memory.h>
#include "alg.h"
-//#include "pafhjt.h" // FL: ??
+//#include "pafhjt.h"
#include "paf_alg.h"
#include "paf_alg_priv.h"
diff --git a/procsdk_audio_x_xx_xx_xx/common/paf_decOpCircBuf.c b/procsdk_audio_x_xx_xx_xx/common/paf_decOpCircBuf.c
index 31ccf41e5694a54af3c63915f93f08aed16485e8..a4b4865a5654d5036ae872f59d2ba5b6ea90e5ce 100644 (file)
#include "paf_decOpCircBuf.h"
#define MAX_NUM_AF_PCM ( 4 )
-#define MAX_NUM_AF_DDP ( 2 ) //Qin - Increased to prevent cb overflow.
+#define MAX_NUM_AF_DDP ( 2 )
#define CB_INIT_RD_LAG ( 2 )
// initialize audio frame PCM buffers
pPcmBuf = pCb->pcmBuf;
- pMetaBuf = pCb->metaBuf; //QIN
+ pMetaBuf = pCb->metaBuf; //QIN
for (n=0; n<pCb->maxNumAfCb; n++)
{
pAfCb = &pCb->afCb[n];
pAfCb->data.samsiz[i] = 0;
}
- //Initialize metadata buffers //QIN
+ //Initialize metadata buffers //QIN
for (i=0; i<PAF_MAX_NUM_PRIVATE_MD; i++)
{
- pAfCb->pafPrivateMetadata[i].offset = 0;
- pAfCb->pafPrivateMetadata[i].size = 0;
- pAfCb->pafPrivateMetadata[i].pMdBuf = pMetaBuf;
- pMetaBuf += PAF_MAX_PRIVATE_MD_SZ;
+ pAfCb->pafPrivateMetadata[i].offset = 0;
+ pAfCb->pafPrivateMetadata[i].size = 0;
+ pAfCb->pafPrivateMetadata[i].pMdBuf = pMetaBuf;
+ pMetaBuf += PAF_MAX_PRIVATE_MD_SZ;
}
}
// update flags
pCb->emptyFlag = 0;
//pCb->cbWriteAfInit = 0;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
// Write back AF circular buffer
for (i=0; i<PAF_MAX_NUM_PRIVATE_MD; i++) // Write back metadata //QIN
{
Cache_wb(&pAfCb->pafPrivateMetadata[i], sizeof(PAF_PrivateMetadata), Cache_Type_ALLD, 0);
- }
+ }
}
Cache_wait();
Int8 n;
Int8 i;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Invalidate circular buffer configuration.
// NOTE: Probably only a subset of this information needs to be updated.
Cache_inv(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
for (i=0; i<PAF_MAX_NUM_PRIVATE_MD; i++) //QIN
{
Cache_inv(&pAfCb->pafPrivateMetadata[i], sizeof(PAF_PrivateMetadata), Cache_Type_ALLD, 0);
- }
+ }
}
Cache_wait();
pCb->writerActiveFlag = 1;
pCb->emptyFlag = 0;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
pCb->writerActiveFlag = 0;
pCb->emptyFlag = 1;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
// update flags
pCb->readerActiveFlag = 1;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
// update flags
pCb->readerActiveFlag = 0;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
pCb->readerActiveFlag = 1;
pCb->writerActiveFlag = 1;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
Int8 i;
Int16 j;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Invalidate circular buffer configuration.
Cache_inv(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
Cache_wait();
// get pointer to current audio frame in circular buffer
pAfCb = &pCb->afCb[pCb->afRdIdx];
- // (***) FL: hackin'
+ // (***) FL: revisit
// Invalidate audio frame
Cache_inv(pAfCb, sizeof(PAF_AudioFrame), Cache_Type_ALLD, 0);
Cache_inv(pAfCb->data.samsiz, PAF_DECOP_CB_MAX_NUM_PCM_CH*sizeof(PAF_AudioSize), Cache_Type_ALLD, 0);
pAfRd->sampleCount = pCb->strFrameLen;
pAfRd->channelConfigurationRequest = pAfCb->channelConfigurationRequest;
pAfRd->channelConfigurationStream = pAfCb->channelConfigurationStream;
+
// read metadata information updated by decoder //QIN
pAfRd->bsMetadata_type = pAfCb->bsMetadata_type; /* non zero if metadata is attached. */
- pAfRd->pafBsMetadataUpdate = pAfCb->pafBsMetadataUpdate; /* indicates whether bit-stream metadata update */
+ pAfRd->pafBsMetadataUpdate = pAfCb->pafBsMetadataUpdate; /* indicates whether bit-stream metadata update */
pAfRd->numPrivateMetadata = pAfCb->numPrivateMetadata; /* number of valid private metadata (0 or 1 if metadata filtering enabled) */
pAfRd->bsMetadata_offset = pAfCb->bsMetadata_offset; /* offset into audio frame for change in bsMetadata_type field */
+
// read PCM samples
for (i = 0; i < PAF_DECOP_CB_MAX_NUM_PCM_CH; i++)
{
for (i = 0; i < PAF_MAX_NUM_PRIVATE_MD; i++)
{
//Invalidate metadata data
- Cache_inv(&pAfCb->pafPrivateMetadata[i], sizeof(PAF_PrivateMetadata), Cache_Type_ALLD, 0);
+ Cache_inv(&pAfCb->pafPrivateMetadata[i], sizeof(PAF_PrivateMetadata), Cache_Type_ALLD, 0);
Cache_wait();
if ((pAfCb->pafPrivateMetadata[i].offset >= pCb->pcmRdIdx)
- &&(pAfCb->pafPrivateMetadata[i].offset < (pCb->pcmRdIdx + pCb->strFrameLen))
- &&(pAfCb->pafPrivateMetadata[i].size))
+ &&(pAfCb->pafPrivateMetadata[i].offset < (pCb->pcmRdIdx + pCb->strFrameLen))
+ &&(pAfCb->pafPrivateMetadata[i].size))
{
//Invalidate metadata data
- Cache_inv(pAfCb->pafPrivateMetadata[i].pMdBuf, pAfCb->pafPrivateMetadata[i].size, Cache_Type_ALLD, 0);
+ Cache_inv(pAfCb->pafPrivateMetadata[i].pMdBuf, pAfCb->pafPrivateMetadata[i].size, Cache_Type_ALLD, 0);
Cache_wait();
- // the offset is adjusted for segment [pCb->pcmRdIdx, (pCb->pcmRdIdx + pCb->pafFrameLen)]
- pAfRd->pafPrivateMetadata[i].offset = 0;//pAfCb->pafPrivateMetadata[i].offset - pCb->pcmRdIdx;
- pAfRd->pafPrivateMetadata[i].size = pAfCb->pafPrivateMetadata[i].size;
- memcpy (pAfRd->pafPrivateMetadata[i].pMdBuf, pAfCb->pafPrivateMetadata[i].pMdBuf, pAfCb->pafPrivateMetadata[i].size);
+ // the offset is adjusted for segment [pCb->pcmRdIdx, (pCb->pcmRdIdx + pCb->pafFrameLen)]
+ pAfRd->pafPrivateMetadata[i].offset = 0;//pAfCb->pafPrivateMetadata[i].offset - pCb->pcmRdIdx;
+ pAfRd->pafPrivateMetadata[i].size = pAfCb->pafPrivateMetadata[i].size;
+ memcpy (pAfRd->pafPrivateMetadata[i].pMdBuf, pAfCb->pafPrivateMetadata[i].pMdBuf, pAfCb->pafPrivateMetadata[i].size);
+ }
+ else //reset un-used buf
+ {
+ pAfRd->pafPrivateMetadata[i].offset = 0;
+ pAfRd->pafPrivateMetadata[i].size = 0;
}
- else //reset un-used buf
- {
- pAfRd->pafPrivateMetadata[i].offset = 0;
- pAfRd->pafPrivateMetadata[i].size = 0;
- }
}
pCb->pcmRdIdx += pCb->strFrameLen; // update PCM read index
if (pCb->pcmRdIdx == pCb->decOpFrameLen)
}
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration.
// NOTE: Probably only a subset of this information needs to be updated.
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
Int8 i;
Int16 j;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Invalidate circular buffer configuration.
// NOTE: Probably only a subset of this information needs to be updated.
Cache_inv(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
pAfCb->channelConfigurationStream = pAfWrt->channelConfigurationStream;
// write metadata information updated by decoder//QIN
pAfCb->bsMetadata_type = pAfWrt->bsMetadata_type; /* non zero if metadata is attached. */
- pAfCb->pafBsMetadataUpdate = pAfWrt->pafBsMetadataUpdate; /* indicates whether bit-stream metadata update */
+ pAfCb->pafBsMetadataUpdate = pAfWrt->pafBsMetadataUpdate; /* indicates whether bit-stream metadata update */
pAfCb->numPrivateMetadata = pAfWrt->numPrivateMetadata; /* number of valid private metadata (0 or 1 if metadata filtering enabled) */
pAfCb->bsMetadata_offset = pAfWrt->bsMetadata_offset; /* offset into audio frame for change in bsMetadata_type field */
// write PCM samples
for (i = 0; i < PAF_MAX_NUM_PRIVATE_MD; i++)
{
if (pAfWrt->pafPrivateMetadata[i].size )
- {
+ {
pAfCb->pafPrivateMetadata[i].offset = pAfWrt->pafPrivateMetadata[i].offset;
- pAfCb->pafPrivateMetadata[i].size = pAfWrt->pafPrivateMetadata[i].size;
- memcpy (pAfCb->pafPrivateMetadata[i].pMdBuf, pAfWrt->pafPrivateMetadata[i].pMdBuf, pAfWrt->pafPrivateMetadata[i].size);
- }
- else
- {
+ pAfCb->pafPrivateMetadata[i].size = pAfWrt->pafPrivateMetadata[i].size;
+ memcpy (pAfCb->pafPrivateMetadata[i].pMdBuf, pAfWrt->pafPrivateMetadata[i].pMdBuf, pAfWrt->pafPrivateMetadata[i].size);
+ }
+ else
+ {
pAfCb->pafPrivateMetadata[i].offset = 0;
- pAfCb->pafPrivateMetadata[i].size = 0;
- }
+ pAfCb->pafPrivateMetadata[i].size = 0;
+ }
}
// update audio frame write index
pCb->afWrtIdx++;
// update number of audio frames in circular buffer
pCb->numAfCb++;
- // (***) FL: hackin'
+ // (***) FL: revisit
// Write back circular buffer configuration
Cache_wb(pCb, sizeof(PAF_DecodeOpCircBuf), Cache_Type_ALLD, 0);
// write back audio frame
diff --git a/procsdk_audio_x_xx_xx_xx/test_arm/framework/audioStreamDecodeProc.c b/procsdk_audio_x_xx_xx_xx/test_arm/framework/audioStreamDecodeProc.c
index 214ed6ae26ce251717fcd76791421d3720f1d035..ee8ecf5e1315a66235041875a80a2b3fd30a959a 100644 (file)
* Audio Stream Decode Processing task function
*/
Void taskAsdpFxn(
-// Int betaPrimeValue, // FL: comeback to this
+// Int betaPrimeValue, // FL: revisit
const PAF_AST_Params *pP,
const PAF_AST_Patchs *pQ
)
Int errno; /* error number */
Int size;
Int argIdx;
- // FL: decoder output circular buffer
+ // Decoder output circular buffer
PAF_DecodeOpCircBuf *pCb;
PAF_AudioFrame *pAfWrt;
Int cbErrno;
- // FL: Messaging
+ // Messaging
PAF_InpBufConfig *pIpBufConfig;
ASP_Msg *pAspMsg;
MessageQ_QueueId queId;
return;
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
- // (***) FL: hackin'
+ // (***) FL: revisit
Cache_inv((Ptr)(&IACP_STD_BETA_TABLE.pStatus[0]), 512*sizeof(IALG_Status *), Cache_Type_ALLD, 0); // invalidate entire beta table
Cache_wait();
pP->fxns->memStatusPrint(HEAP_INTERNAL, HEAP_INTERNAL1, HEAP_EXTERNAL, HEAP_INTERNAL1_SHM);
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Status structure addresses for Beta Units initialized on Slave
Cache_wb((Ptr)(&IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), sizeof(IALG_Status *), Cache_Type_ALLD, 0);
Cache_wb((Ptr)(&IACP_STD_BETA_TABLE.pStatus[STD_BETA_PCM]), sizeof(IALG_Status *), Cache_Type_ALLD, 0);
//Cache_wb((Ptr)(&IACP_STD_BETA_TABLE.pStatus[STD_BETA_DDP2]), sizeof(IALG_Status *), Cache_Type_ALLD, 0);
Cache_wait();
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Status structures for Beta Units initialized on Slave
size = IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]->size;
Cache_wb((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), size, Cache_Type_ALLD, 0);
//Cache_wb((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DDP2]), size, Cache_Type_ALLD, 0);
Cache_wait();
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Dec configuration
Cache_wb(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
// simulate dec activate load
//simLoad(DEC_ACTIVATE_LOAD);
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Status structures for shared Beta Units
size = IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]->size;
Cache_inv((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), size, Cache_Type_ALLD, 0);
errno = dec->fxns->reset(dec, NULL, &pC->xDec[z].decodeControl, &pC->xDec[z].decodeStatus);
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Status structures for shared Beta Units
size = IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]->size;
Cache_wb((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), size, Cache_Type_ALLD, 0);
// Get input associated w/ decoder
zI = pP->inputsFromDecodes[z];
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Inp configuration
Cache_inv(&gPAF_AST_config.xInp[zI], sizeof(PAF_AST_InpBuf), Cache_Type_ALLD, 0);
// invalidate input data
diff --git a/procsdk_audio_x_xx_xx_xx/test_dsp/application/itopo/evmk2g/atboot.c b/procsdk_audio_x_xx_xx_xx/test_dsp/application/itopo/evmk2g/atboot.c
index bd82fa665ffa61a0c84b045e7a01d766ae5d5001..1fed4a8b1a90a64c8d7db454f7b197c9792eaeb9 100644 (file)
writeVOLOffsetMasterN(0x7fff), \
writeSYSRecreationModeDirect, \
writeSYSChannelConfigurationRequestSurround4_1, \
- execPAIOutAnalog, \
- execPAIInHDMIStereo
+ execPAIOutAnalogSlave, \
+ execPAIInAnalog
#else
#define CUS_ATBOOT_S \
diff --git a/procsdk_audio_x_xx_xx_xx/test_dsp/framework/as0.c b/procsdk_audio_x_xx_xx_xx/test_dsp/framework/as0.c
index 1fde5775a861b88d96c78a2c704f6deb6b8351ec..f101a6048f1e64a0527320e653c2d33aab8e7273 100644 (file)
//#include <ti/procsdk_audio/procsdk_audio_typ.h>
#include <procsdk_audio_typ.h>
-#include <sio.h> // FL: added
+#include <sio.h>
#include "as0.h"
)
{
Int m, n, o, p;
- // FL: Messaging
+ // Messaging
ASP_Msg *pAspMsg;
Int argIdx;
Int errno; /* error number */
diff --git a/procsdk_audio_x_xx_xx_xx/test_dsp/framework/audioStreamInpProc.c b/procsdk_audio_x_xx_xx_xx/test_dsp/framework/audioStreamInpProc.c
index 26c86569bfb83c4f1a78a0448a10bcb75fcf51e4..f8223edb02887d3bf7760108dd24c04d5cf818ce 100644 (file)
* Audio Stream Input Processing task function
*/
Void taskAsipFxn(
-// Int betaPrimeValue, // FL: comeback to this
+// Int betaPrimeValue, // FL: revisit
const PAF_AST_Params *pP,
const PAF_AST_Patchs *pQ
)
{
// Task data
- //PAF_AST_Config PAF_AST_config; /* Local configuration */
- //PAF_AST_Config *pC; /* Local configuration pointer */
+ PAF_AST_Config PAF_AST_config; /* Local configuration */
+ PAF_AST_Config *pC; /* Local configuration pointer */
// Local data
Int as; /* Audio Stream Number (1, 2, etc.) */
Int z; /* input/encode/stream/decode/output counter */
Int loopCount = 0; // used to stop trace to see startup behavior.
UInt32 curTime;
Int size;
- // FL: Messaging
- ASP_Msg *pAspMsg;
+ // Messaging
+ ASP_Msg *pAspMsg;
Int status;
Log_info0("Enter taskAsipFxn()");
pP->fxns->memStatusPrint(HEAP_INTERNAL, HEAP_INTERNAL1, HEAP_EXTERNAL, HEAP_INTERNAL1_SHM);
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back configuration
Cache_wb(&gPAF_AST_config, sizeof(gPAF_AST_config), Cache_Type_ALLD, 0);
Cache_wb(&pC, sizeof(pC), Cache_Type_ALLD, 0);
Cache_wait();
- // (***) FL: hackin'
+ // (***) FL: revisit
// write Dec configuration
Cache_wb(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back entire beta table
Cache_wb((Ptr)(&IACP_STD_BETA_TABLE.pStatus[0]), 512*sizeof(IALG_Status *), Cache_Type_ALLD, 0);
Cache_wait();
SW_BREAKPOINT;
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Status structure addresses for Beta Units initialized on Slave
Cache_inv((Ptr)(&IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), sizeof(IALG_Status *), Cache_Type_ALLD, 0);
Cache_inv((Ptr)(&IACP_STD_BETA_TABLE.pStatus[STD_BETA_PCM]), sizeof(IALG_Status *), Cache_Type_ALLD, 0);
//if (!IACP_STD_BETA_TABLE.pStatus[STD_BETA_DDP]) Log_info0("ERROR: beta unit for Dec==NULL");
//if (!IACP_STD_BETA_TABLE.pStatus[STD_BETA_DDP2]) Log_info0("ERROR: beta unit for Dec==NULL");
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Status structures for Beta Units initialized on Slave
Cache_inv((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), sizeof(Int), Cache_Type_ALLD, 0);
size = IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]->size;
//Cache_inv((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DDP2]), size, Cache_Type_ALLD, 0);
Cache_wait();
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
{
// FL: added for decode output circular buffer
- // FL: (***)hackin'
+ // FL: (***)revisit
Int z; /* decode counter */
for (z=DECODE1; z < DECODEN; z++)
Int as = pC->as; /* Audio Stream Number (1, 2, etc.) */
Int z; /* input/encode/stream/decode/output counter */
Int zMS = pC->masterStr;
- Int errno; /* error number */
- PAF_DecodeOpCircBuf *pCb; // FL: decoder output circular buffer
+ Int errno; /* error number */
+ PAF_DecodeOpCircBuf *pCb; /* Decoder output circular buffer */
TRACE_TERSE1("PAF_ASIT_initPhaseConfig: AS%d: initialization phase - configuration", as+zMS);
pC->xDec[z].decodeStatus = *pP->z_pDecodeStatus[z];
// Initialize decoder output circular buffer
- // (***) FL: Ugly, here PCM is hard-coded for 256 sample dec op frame length
+ // (***) FL: revisit, here PCM is hard-coded for 256 sample dec op frame length
pCb = &pC->xDec[z].decOpCb;
errno = cbInit(PAF_SOURCE_PCM, 256, FRAMELENGTH, pCb);
if (errno)
}
//frameLength = pP->fxns->computeFrameLength (pcmAlgMaster, FRAMELENGTH,
// pC->xDec[zMD].decodeStatus.bufferRatio);
- frameLength = FRAMELENGTH; // FL: fix PCM frameLength, hack for demo.
+ frameLength = FRAMELENGTH; // FL: fix PCM frameLength for alpha release.
if (errno = SIO_ctrl (pC->xInp[zMI].hRxSio,
PAF_SIO_CONTROL_SET_PCMFRAMELENGTH, frameLength))
gAsipInitCnt++;
Log_info0("TaskAsip: state=INIT");
- // (***) FL: hackin'
+ // (***) FL: revisit
#if 0 // status for shared beta units can change (e.g. at-boot or alpha)
// write back Status structures for shared Beta Units
size = IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]->size;
}
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Status structures for shared Beta Units
size = IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]->size;
Cache_inv((Ptr)(IACP_STD_BETA_TABLE.pStatus[STD_BETA_DECODE]), size, Cache_Type_ALLD, 0);
Log_info0("TaskAsip: state=INFO1");
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Inp configuration
Cache_wb(&gPAF_AST_config.xInp[0], INPUTN*sizeof(PAF_AST_InpBuf), Cache_Type_ALLD, 0);
// write back input data
}
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
Log_info0("TaskAsip: state=INFO2");
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Inp configuration
Cache_wb(&gPAF_AST_config.xInp[0], INPUTN*sizeof(PAF_AST_InpBuf), Cache_Type_ALLD, 0);
// write back input data
}
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
Log_info0("TaskAsip: state=DECODE");
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Dec configuration
Cache_wb(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
}
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[0], DECODEN*sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
Int zI, zS;
Int zMD = pC->masterDec;
Int zMI = pP->zone.master;
- // FL: messaging
- ASP_Msg* pAspMsg;
+ ASP_Msg* pAspMsg; /* Messaging */
Int argIdx;
Int decErrno;
Int status;
- PAF_DecodeOpCircBuf *pCb; // FL: decoder output circular buffer
+ PAF_DecodeOpCircBuf *pCb; /* Decoder output circular buffer */
(void)as; // clear compiler warning in case not used with tracing disabled
decAlg[z]->fxns->algActivate (decAlg[z]);
#endif
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Dec configuration
Cache_wb(&gPAF_AST_config.xDec[z], sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
SW_BREAKPOINT;
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[z], sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
FRAMELENGTH,
pC->xDec[z].decodeStatus.bufferRatio);
#endif
-#if 0 // (***) FL: hackin'. Bypass computeFrameLength().
+#if 0 // (***) FL: revisit. Bypass computeFrameLength().
frameLength = pP->fxns->computeFrameLength(z,
FRAMELENGTH,
pC->xDec[z].decodeStatus.bufferRatio);
pC->xDec[z].decodeInStruct.sampleCount = frameLength;
pC->xDec[z].decodeControl.sampleRate = PAF_SAMPLERATE_UNKNOWN;
- // (***) FL: hackin'. Count samples for DDP.
+ // (***) FL: revisit. Count samples for DDP.
// Add framework frame length and running sample count to decoder control.
//pC->xDec[z].decodeControl.pafFrameLength = FRAMELENGTH;
//pC->xDec[z].decodeControl.rdSampleCount = 0;
Int zMI = pP->zone.master;
Int zMS = pC->masterStr;
UInt32 curTime;
- // FL: Messaging
- ASP_Msg *pAspMsg;
+ ASP_Msg *pAspMsg; /* Messaging */
Int argIdx;
Int status;
- // FL: hackin'
+ // FL: revisit
//Int size;
//PAF_InpBufConfig *pIpBufConfig;
}
#if 1
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Inp configuration
Cache_wb(&gPAF_AST_config.xInp[zI], sizeof(PAF_AST_InpBuf), Cache_Type_ALLD, 0);
// write back input data // (***) GJ: don't need this for 1xI2S HDMI/SPDIF. Maybe need this for 4xI2S HDMI.
}
#if 1
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[z], sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
pC->xDec[zMD].decodeStatus.sourceProgram = sourceProgram;
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
Cache_wb((Ptr)&pC->xDec[zMD].decodeStatus.sourceProgram,
sizeof(pC->xDec[zMD].decodeStatus.sourceProgram), Cache_Type_ALLD, 0);
Cache_wait();
}
#if 0
- // (***) FL: hackin'
+ // (***) FL: revisit
Cache_wb((Ptr)&pC->xDec[z].decodeStatus.sourceDecode,
sizeof(pC->xDec[z].decodeStatus.sourceDecode), Cache_Type_ALLD, 0);
Cache_wait();
Int z; /* decode/stream counter */
Int errno; /* error number */
//Int ch;
- // FL: Messaging
- ASP_Msg *pAspMsg;
+ ASP_Msg *pAspMsg; /* Messaging */
Int argIdx;
Int status;
Int cbErrno;
// FL: debug, capture input buffer
//capIbPcm(pC->xInp[z].pInpBuf);
- // (***) FL: hackin'
+ // (***) FL: revisit
// write back Dec configuration
Cache_wb(&gPAF_AST_config.xDec[z], sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
SW_BREAKPOINT;
}
- // (***) FL: hackin'
+ // (***) FL: revisit
// invalidate Dec configuration
Cache_inv(&gPAF_AST_config.xDec[z], sizeof(PAF_AST_Decode), Cache_Type_ALLD, 0);
Cache_wait();
FRAMELENGTH,
pC->xDec[z].decodeStatus.bufferRatio);
#endif
-#if 0 // (***) FL: hackin'. Bypass computeFrameLength().
+#if 0 // (***) FL: revisit. Bypass computeFrameLength().
frameLength = pP->fxns->computeFrameLength(z,
FRAMELENGTH,
pC->xDec[z].decodeStatus.bufferRatio);
diff --git a/procsdk_audio_x_xx_xx_xx/test_dsp/framework/audioStreamOutProc.c b/procsdk_audio_x_xx_xx_xx/test_dsp/framework/audioStreamOutProc.c
index d67f7a1bdbde5f66e75cbf3dd9aa96a013a78bcd..bf467b01578aed9e6b32b41acf543107bcd09d41 100644 (file)
* Audio Stream Output Processing task function
*/
Void taskAsopFxn(
-// Int betaPrimeValue, // FL: comeback to this
+// Int betaPrimeValue, // FL: revisit
const PAF_AST_Params *pP,
const PAF_AST_Patchs *pQ
)
Int z; /* decode/encode counter */
Int errno; /* error number */
Int zO, zS;
- PAF_DecodeOpCircBuf *pCb; // FL: decoder output circular buffer
+ PAF_DecodeOpCircBuf *pCb; /* decoder output circular buffer */
for (z=DECODE1; z < DECODEN; z++)
{
Int z; /* encode/output counter */
Int errno; /* error number */
Int zX, zE, zS;
- UInt32 curTime; // FL: added
+ UInt32 curTime;
// Await output buffers (but not first time)
Int block
)
{
- Int as = pC->as; /* Audio Stream Number (1, 2, etc.) */
- Int z; /* decode/encode counter */
- Int errno; /* error number */
- PAF_DecodeOpCircBuf *pCb; // FL: decoder output circular buffer
+ Int as = pC->as; /* Audio Stream Number (1, 2, etc.) */
+ Int z; /* decode/encode counter */
+ Int errno; /* error number */
+ PAF_DecodeOpCircBuf *pCb; /* decoder output circular buffer */
(void)as; // clear compiler warning in case not used with tracing disabled
diff --git a/procsdk_audio_x_xx_xx_xx/test_dsp/framework/systemInit.c b/procsdk_audio_x_xx_xx_xx/test_dsp/framework/systemInit.c
index 5d6a6f7d7050b1d17946176d7dec9076e9ea629e..d0b5cc2d540bc58926bf913959c8e0a3a8b6da6e 100644 (file)
#include "aspMsg_master.h"
#include "fwkSim.h"
-extern Void ACP_main_cus(Void); // (*** ?) FL: fix this hack
-extern Void idleAudioStream(Void); // (*** ?) FL: fix this hack
+extern Void ACP_main_cus(Void); // (*** ?) FL: revisit -- check method of patching alpha codes
+extern Void idleAudioStream(Void); // (*** ?) FL: revisit -- shouldn't need to call this from system init
const PAFHJT_t *pafhjt;