Update ASOT tracing
authorFrank Livingston <frank-livingston@ti.com>
Thu, 17 Aug 2017 21:24:37 +0000 (16:24 -0500)
committerFrank Livingston <frank-livingston@ti.com>
Thu, 17 Aug 2017 21:24:37 +0000 (16:24 -0500)
pasdk/test_dsp/framework/audioStreamInpProc.c
pasdk/test_dsp/framework/audioStreamOutProc.c

index 1d509a4bfdb19e6278b1dec80bd094ad3f8fa37f..6d8580367872d10150cba449685e7af1bc0d776a 100644 (file)
@@ -89,7 +89,7 @@ Int32 gNumPfpAsit2=0;
 #define TR_MOD  trace
 
 // Allow a developer to selectively enable tracing.
-#define CURRENT_TRACE_MASK      0x21
+#define CURRENT_TRACE_MASK      0x27
 
 #define TRACE_MASK_TERSE        0x01   // only flag errors and show init
 #define TRACE_MASK_GENERAL      0x02   // half dozen lines per frame
index 2abd0709c1a83e69efcde3db5e1a50a783f9e1eb..9fbe6638fa433d1932af4275a1a2cf1430a0c02d 100644 (file)
@@ -70,8 +70,61 @@ Int32 gNumPfpAsot1=0; // debug
 #include "dbgCapAf.h"
 
 
+// -----------------------------------------------------------------------------
+// Debugging Trace Control, local to this file.
+// 
+#include "logp.h"
+
 #define TRACE_TIME(a)
 
+// Allow a developer to selectively enable tracing.
+#define CURRENT_TRACE_MASK      0x07
+
+#define TRACE_MASK_TERSE        0x01   // only flag errors and show init
+#define TRACE_MASK_GENERAL      0x02   // half dozen lines per frame
+#define TRACE_MASK_VERBOSE      0x04   // trace full operation
+
+#if !(CURRENT_TRACE_MASK & TRACE_MASK_TERSE)
+    #undef  TRACE_TERSE0
+    #undef  TRACE_TERSE1
+    #undef  TRACE_TERSE2
+    #undef  TRACE_TERSE3
+    #undef  TRACE_TERSE4
+    #define TRACE_TERSE0(a)
+    #define TRACE_TERSE1(a,b)
+    #define TRACE_TERSE2(a,b,c)
+    #define TRACE_TERSE3(a,b,c,d)
+    #define TRACE_TERSE4(a,b,c,d,e)
+#endif
+    
+#if !(CURRENT_TRACE_MASK & TRACE_MASK_GENERAL)
+    #undef  TRACE_GEN0
+    #undef  TRACE_GEN1
+    #undef  TRACE_GEN2
+    #undef  TRACE_GEN3
+    #undef  TRACE_GEN4
+    #define TRACE_GEN0(a)
+    #define TRACE_GEN1(a,b)
+    #define TRACE_GEN2(a,b,c)
+    #define TRACE_GEN3(a,b,c,d)
+    #define TRACE_GEN4(a,b,c,d,e)
+#endif
+
+#if !(CURRENT_TRACE_MASK & TRACE_MASK_VERBOSE)
+    #undef  TRACE_VERBOSE0
+    #undef  TRACE_VERBOSE1
+    #undef  TRACE_VERBOSE2
+    #undef  TRACE_VERBOSE3
+    #undef  TRACE_VERBOSE4
+    #define TRACE_VERBOSE0(a)
+    #define TRACE_VERBOSE1(a,b)
+    #define TRACE_VERBOSE2(a,b,c)
+    #define TRACE_VERBOSE3(a,b,c,d)
+    #define TRACE_VERBOSE4(a,b,c,d,e)
+#endif
+
+// .............................................................................
+
 //
 // Audio Stream Definitions
 //
@@ -302,7 +355,7 @@ Void taskAsopFxn(
 
     if (!pQ)
     {
-        TRACE_TERSE0("TaskAsip: No Patchs defined. Exiting.");
+        TRACE_TERSE0("TaskAsop: No Patchs defined. Exiting.");
         LINNO_RPRT(TaskAsop, -1);
         return;
     }    
@@ -380,7 +433,7 @@ Void taskAsopFxn(
     //   
     for (z=STREAM1; z < STREAMN; z++)
     {
-        TRACE_VERBOSE1("TaskAsip: AS%d: running", as+z);
+        TRACE_VERBOSE1("TaskAsop: AS%d: running", as+z);
     }
     
     errno = 0;                      // init error indicator -- no error
@@ -2498,7 +2551,7 @@ PAF_ASOT_decodeEncode(
             //
             //Semaphore_pend(semaphoreTxAudio, BIOS_WAIT_FOREVER);
             curTime = Clock_getTicks();
-            //System_printf("System time in TaskAsipFxn Tx audio = %lu\n", (ULong)curTime);
+            //System_printf("System time in TaskAsopFxn Tx audio = %lu\n", (ULong)curTime);
             //Log_info1("outputEncode():Tx SIO reclaim(), system time = %u", curTime);
         }
         else