PASDK-443: Added comments for CB capture code.
authorChitresh Gupta <chitresh.g@pathpartnertech.com>
Thu, 9 Nov 2017 07:33:16 +0000 (13:03 +0530)
committerChitresh Gupta <chitresh.g@pathpartnertech.com>
Thu, 9 Nov 2017 07:33:16 +0000 (13:03 +0530)
pasdk/common/aspDecOpCircBuf_common.h
pasdk/test_arm/framework/aspDecOpCircBuf_slave.c
pasdk/test_arm/framework/audioStreamDecodeProc.c
pasdk/test_dsp/framework/aspDecOpCircBuf_master.c

index cb22f203900e773669ad3ccd604cbd74b43c0d20..b02a403b10817134069fa461fa47543bd8f8be62 100644 (file)
@@ -43,12 +43,12 @@ All rights reserved.
 
 //#include "dbgBenchmark.h" // PCM high-sampling rate + SRC + CAR benchmarking
 
-//#define CB_RW_OP_CAP_PP // debug
+//#define CB_RW_OP_CAP_PP 1// debug
 #ifdef CB_RW_OP_CAP_PP
 #define CB_OP_NONE        0
 #define CB_OP_W           1     // ARM write
 #define CB_OP_R           2     // DSP read
-#define CB_OP_COUNT_MAX   10000
+#define CB_OP_COUNT_MAX   15000
 #endif
 
 // CB control
index 0cc35f09626769fc6f2c95defc60273e8115c3ca..a5025e0e5005e32d7b130ad19292c72957375925 100644 (file)
@@ -869,7 +869,7 @@ Int cbWriteAf(
             }
             Cache_wait();
 
-#if 0 // (***) FL: shows timing of CB write
+#if 0 // also for CB_RW_OP_CAP_PP (***) FL: shows timing of CB write
             // debug
             {
                 static Uint8 toggleState = 0;
index 1b12149a5224391832ef6a7f41d7e68a07aade62..23ea1dbc16442f20be61949eb94034a62a113093 100644 (file)
@@ -133,7 +133,7 @@ UInt32 gSlaveDecDeactivateCnt   =0;
 //#define CAPTURE_DECODER_OUTSAMPLES_PP
 #ifdef CAPTURE_DECODER_OUTSAMPLES_PP
 
-#define CAP_FRAME_MAX            2000
+#define CAP_FRAME_MAX            10000
 Uint32 tempCap_frameCnt = 0;
 int tempCap_decSampleOut[CAP_FRAME_MAX] = {0};
 #endif
@@ -800,6 +800,15 @@ Void taskAsdpFxn(
                         if (tempCap_frameCnt < CAP_FRAME_MAX)
                         {
                             tempCap_decSampleOut[tempCap_frameCnt] = pAfWrt->sampleCount;
+                            // alternative toggle
+                            {
+                                static Uint8 toggleState = 0;
+                                if (toggleState == 0)
+                                    GPIOSetOutput(GPIO_PORT_1, GPIO_PIN_25);
+                                else
+                                    GPIOClearOutput(GPIO_PORT_1, GPIO_PIN_25);
+                               toggleState = ~(toggleState);
+                            }
                             tempCap_frameCnt++;
                         }
                         #endif
index 870e476f8213d1216e2b4003e8f88f2d35d97964..06c8957365b4d63f76c2a5a4a7122a6a3175079f 100644 (file)
@@ -775,7 +775,7 @@ Int cbReadAf(
             cbReadMuteWithLastAfInfo(pCb, pAfRd);
             //SW_BREAKPOINT; // debug
             
-#if 1 // (***) FL: shows timing of CB underflow
+#if 1 // also for CB_RW_OP_CAP_PP (***) FL: shows timing of CB underflow
             // debug
             {
                 static Uint8 toggleState = 0;
@@ -1057,7 +1057,7 @@ Int cbReadAf(
                 // Mute output on underflow
                 cbReadMuteWithLastAfInfo(pCb, pAfRd);
                 
-#if 1 // (***) FL: shows timing of CB underflow
+#if 1 // also for CB_RW_OP_CAP_PP (***) FL: shows timing of CB underflow
                 // debug
                 {
                     static Uint8 toggleState = 0;
@@ -1100,7 +1100,7 @@ Int cbReadAf(
         // Read AF complete, update Last CB AF Info
         cbUpdateLastAfInfo(pCb, pAfRd);
 
-#if 0 // (***) FL: shows timing of successful CB read
+#if 0 // also for CB_RW_OP_CAP_PP (***) FL: shows timing of successful CB read
         {
             static Uint8 toggleState = 0;
             if (toggleState == 0)