bluetoothengine/btnotif/inc/bluetoothtrace.h
changeset 70 f5508c13dfe0
parent 29 48ae3789ce00
equal deleted inserted replaced
67:16e4b9007960 70:f5508c13dfe0
     1 /*
     1 /*
     2 * ============================================================================
     2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
     3 *  Name        : bluetoothtrace.h
     3 * All rights reserved.
     4 *  Part of     : BluetoothUI / bluetoothuimodel       *** Info from the SWAD
     4 * This component and the accompanying materials are made available
     5 *  Description : API declaration of run-time debug tracing
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
     6 *
     8 *
     7 *  Copyright © 2009 Nokia Corporation and/or its subsidiary(-ies).
     9 * Initial Contributors:
     8 *  All rights reserved.
    10 * Nokia Corporation - initial contribution.
     9 *  This component and the accompanying materials are made available
       
    10 *  under the terms of "Eclipse Public License v1.0"
       
    11 *  which accompanies this distribution, and is available
       
    12 *  at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
    13 *
    11 *
    14 *  Initial Contributors:
    12 * Contributors:
    15 *  Nokia Corporation - initial contribution.
       
    16 *
    13 *
    17 *  Contributors:
    14 * Description:  BtDeviceDialogWidget class declaration.
    18 *  Nokia Corporation
    15 *
    19 * ============================================================================
       
    20 * Template version: 4.2
       
    21 */
    16 */
    22 
    17 
    23 #ifndef BLUETOOTHTRACE_H
    18 #ifndef BLUETOOTHTRACE_H
    24 #define BLUETOOTHTRACE_H
    19 #define BLUETOOTHTRACE_H
    25 
    20 
   142 /**
   137 /**
   143  * internal tracing implementation, do not use it out of this file.
   138  * internal tracing implementation, do not use it out of this file.
   144  */
   139  */
   145 inline void Trace(const TDesC &trGrp, const TDesC &trTxt)
   140 inline void Trace(const TDesC &trGrp, const TDesC &trTxt)
   146 {
   141 {
   147     _LIT(Format, "%S%S%S");
       
   148     TBuf16<0x180> str; 
       
   149     TPtrC cp(KComponentName);
   142     TPtrC cp(KComponentName);
   150     str.Format(Format, &cp, &trGrp, &trTxt);
       
   151 #ifdef BLUETOOTHTRACE_MEDIA_FILE
   143 #ifdef BLUETOOTHTRACE_MEDIA_FILE
   152     RFileLogger::WriteFormat( KLogDir, KLogFile, EFileLoggingModeAppend, str);
   144     RFileLogger::WriteFormat( KLogDir, KLogFile, EFileLoggingModeAppend, _L("%S%S%S"),&cp,&trGrp,&trTxt);
   153 #else
   145 #else
   154     RDebug::Print( str );
   146     RDebug::Print( _L("%S%S%S"),&cp,&trGrp,&trTxt );
   155 #endif
   147 #endif
   156 }
   148 }
   157 
   149 
   158 /*
   150 /*
   159  * trace with no parameters
   151  * trace with no parameters
   160  */
   152  */
   161 #define BOstrace0( aGroupName, aTraceName, aTraceText ) \
   153 #define BOstrace0( aGroupName, aTraceName, aTraceText ) \
   162 {\
   154 {\
   163     _LIT(TrGrp, aGroupName); _LIT(TrTxt, aTraceText); \
   155     Trace( aGroupName, aTraceText ); \
   164     Trace( TrGrp, TrTxt ); \
       
   165 }
   156 }
   166 
   157 
   167 /*
   158 /*
   168  * trace with one 32-bit parameter
   159  * trace with one 32-bit parameter
   169  */
   160  */
   170 #define BOstrace1( aGroupName, aTraceName, aTraceText, aParam ) \
   161 #define BOstrace1( aGroupName, aTraceName, aTraceText, aParam ) \
   171 {\
   162 {\
   172     _LIT(TrGrp, aGroupName); _LIT(TrTxt, aTraceText); \
   163     TBuf<200> buf; TBtTraceOflowTruncate16 overflow; \
   173     TBuf<512> buf; TBtTraceOflowTruncate16 overflow; \
   164     buf.AppendFormat(aTraceText, &overflow, aParam); \
   174     buf.AppendFormat(TrTxt, &overflow, aParam); \
   165     Trace( aGroupName, buf ); \
   175     Trace( TrGrp, buf ); \
       
   176 }
   166 }
   177 
   167 
   178 /*
   168 /*
   179  * trace with more than 32 bits of data. Not supported
   169  * trace with more than 32 bits of data. Not supported
   180  */
   170  */
   189 /*
   179 /*
   190  * trace with two parameters.
   180  * trace with two parameters.
   191  */
   181  */
   192 #define BOstraceExt2( aGroupName, aTraceName, aTraceText, aParam1, aParam2 ) \
   182 #define BOstraceExt2( aGroupName, aTraceName, aTraceText, aParam1, aParam2 ) \
   193 {\
   183 {\
   194     _LIT(TrGrp, aGroupName); _LIT(TrTxt, aTraceText); \
   184     TBuf<200> buf; TBtTraceOflowTruncate16 overflow; \
   195     TBuf<512> buf; TBtTraceOflowTruncate16 overflow; \
   185     buf.AppendFormat(aTraceText, &overflow, aParam1, aParam2); \
   196     buf.AppendFormat(TrTxt, &overflow, aParam1, aParam2); \
   186     Trace( aGroupName, buf ); \
   197     Trace( TrGrp, buf ); \
       
   198 }
   187 }
   199 
   188 
   200 /*
   189 /*
   201  * trace with three parameters.
   190  * trace with three parameters.
   202  */
   191  */
   203 #define BOstraceExt3( aGroupName, aTraceName, aTraceText, aParam1, aParam2, aParam3 ) \
   192 #define BOstraceExt3( aGroupName, aTraceName, aTraceText, aParam1, aParam2, aParam3 ) \
   204 {\
   193 {\
   205     _LIT(TrGrp, aGroupName); _LIT(TrTxt, aTraceText); \
   194     TBuf<200> buf; TBtTraceOflowTruncate16 overflow; \
   206     TBuf<512> buf; TBtTraceOflowTruncate16 overflow; \
   195     buf.AppendFormat(aTraceText, &overflow, aParam1, aParam2, aParam3); \
   207     buf.AppendFormat(TrTxt, &overflow, aParam1, aParam2, aParam3); \
   196     Trace( aGroupName, buf ); \
   208     Trace( TrGrp, buf ); \
       
   209 }
   197 }
   210 
   198 
   211 /*
   199 /*
   212  * trace with four parameters
   200  * trace with four parameters
   213  */    
   201  */    
   214 #define BOstraceExt4( aGroupName, aTraceName, aTraceText, aParam1, aParam2, aParam3, aParam4 ) \
   202 #define BOstraceExt4( aGroupName, aTraceName, aTraceText, aParam1, aParam2, aParam3, aParam4 ) \
   215 {\
   203 {\
   216     _LIT(TrGrp, aGroupName); _LIT(TrTxt, aTraceText); \
   204     TBuf<200> buf; TBtTraceOflowTruncate16 overflow; \
   217     TBuf<512> buf; TBtTraceOflowTruncate16 overflow; \
   205     buf.AppendFormat(aTraceText, &overflow, aParam1, aParam2, aParam3, aParam4); \
   218     buf.AppendFormat(TrTxt, &overflow, aParam1, aParam2, aParam3, aParam4); \
   206     Trace( aGroupName, buf ); \
   219     Trace( TrGrp, buf ); \
       
   220 }
   207 }
   221 
   208 
   222 /*
   209 /*
   223  * trace with five parameters
   210  * trace with five parameters
   224  */   
   211  */   
   225 #define BOstraceExt5( aGroupName, aTraceName, aTraceText, aParam1, aParam2, aParam3, aParam4, aParam5 ) \
   212 #define BOstraceExt5( aGroupName, aTraceName, aTraceText, aParam1, aParam2, aParam3, aParam4, aParam5 ) \
   226 {\
   213 {\
   227     _LIT(TrGrp, aGroupName); _LIT(TrTxt, aTraceText); \
   214     TBuf<200> buf; TBtTraceOflowTruncate16 overflow; \
   228     TBuf<512> buf; TBtTraceOflowTruncate16 overflow; \
   215     buf.AppendFormat(aTraceText, &overflow, aParam1, aParam2, aParam3, aParam4, aParam5); \
   229     buf.AppendFormat(TrTxt, &overflow, aParam1, aParam2, aParam3, aParam4, aParam5); \
   216     Trace( aGroupName, buf ); \
   230     Trace( TrGrp, buf ); \
       
   231 }
   217 }
   232 
   218 
   233 /*
   219 /*
   234  * Function entry trace without extra parameters. 
   220  * Function entry trace without extra parameters. 
   235  * The trace is mapped to TRACE_API group.
   221  * The trace is mapped to TRACE_API group.
   236  */
   222  */
   237 #define BOstraceFunctionEntry0( aTraceName ) \
   223 #define BOstraceFunctionEntry0( aTraceName ) \
   238 {\
   224 {\
   239     _LIT(TrGrp, "[ API ]"); \
   225     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   240     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   226     TBuf<200> buf; buf.Copy( func.Left(150) ); buf.Insert(0, _L(">> ") );\
   241     _LIT(Entry, ">> "); \
   227     Trace( _L("[ API ]"), buf ); \
   242     TBuf<512> buf; buf.Copy( func ); buf.Insert(0, Entry );\
       
   243     Trace( TrGrp, buf ); \
       
   244 }
   228 }
   245 
   229 
   246 /*
   230 /*
   247  * Function entry trace with a parameter representing the instance identifier, e.g.
   231  * Function entry trace with a parameter representing the instance identifier, e.g.
   248  * "this" pointer.
   232  * "this" pointer.
   249  * The trace is mapped to TRACE_API group.
   233  * The trace is mapped to TRACE_API group.
   250  */
   234  */
   251 #define BOstraceFunctionEntry1( aTraceName, aInstance ) \
   235 #define BOstraceFunctionEntry1( aTraceName, aInstance ) \
   252 {\
   236 {\
   253     _LIT(TrGrp, "[ API ]");\
   237     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   254     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   238     TBuf<200> buf; buf.Copy( func.Left(150) ); buf.Insert(0, _L(">> ") ); \
   255     _LIT(Entry, ">> "); _LIT(Fmt, " 0x%X(%d)"); \
   239     TBtTraceOflowTruncate16 overflow; \
   256     TBuf<512> buf; buf.Copy( func ); buf.Insert(0, Entry); \
   240     buf.AppendFormat(_L(" 0x%X(%d)"), &overflow, aInstance, aInstance); \
   257     TBtTraceOflowTruncate16 overflow; \
   241     Trace( _L("[ API ]"), buf ); \
   258     buf.AppendFormat(Fmt, &overflow, aInstance, aInstance); \
       
   259     Trace( TrGrp, buf ); \
       
   260 }
   242 }
   261 
   243 
   262 /*
   244 /*
   263  * Function entry trace, which traces function parameters.
   245  * Function entry trace, which traces function parameters.
   264  * The trace is mapped to TRACE_API group. 
   246  * The trace is mapped to TRACE_API group. 
   265  */
   247  */
   266 #define BOstraceFunctionEntryExt(aTraceName, aInstance, aArg) \
   248 #define BOstraceFunctionEntryExt(aTraceName, aInstance, aArg) \
   267 { \
   249 { \
   268     _LIT(TrGrp, "[ API ]");\
   250     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   269     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   251     TBuf<200> buf; buf.Copy( func.Left(150) );  buf.Insert(0, _L(">> ")); \
   270     _LIT(Entry, ">> "); _LIT(Fmt, " 0x%X(%d) arg %d"); \
   252     TBtTraceOflowTruncate16 overflow; \
   271     TBuf<512> buf; buf.Copy( func );  buf.Insert(0, Entry); \
   253     buf.AppendFormat(_L(" 0x%X(%d) arg %d"), &overflow, aInstance, aInstance, aArg); \
   272     TBtTraceOflowTruncate16 overflow; \
   254     Trace( _L("[ API ]"), buf ); \
   273     buf.AppendFormat(Fmt, &overflow, aInstance, aInstance, aArg); \
       
   274     Trace( TrGrp, buf ); \
       
   275 }
   255 }
   276 /*
   256 /*
   277  * Function exit trace without extra parameters. 
   257  * Function exit trace without extra parameters. 
   278  * The trace is mapped to TRACE_API group.
   258  * The trace is mapped to TRACE_API group.
   279  */
   259  */
   280 #define BOstraceFunctionExit0( aTraceName ) \
   260 #define BOstraceFunctionExit0( aTraceName ) \
   281 {\
   261 {\
   282     _LIT(TrGrp, "[ API ]"); \
   262     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   283     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   263     TBuf<200> buf; buf.Copy( func.Left(150) );  buf.Insert(0, _L("<< ")); \
   284     _LIT(Entry, "<< "); \
   264     Trace( _L("[ API ]"), buf ); \
   285     TBuf<512> buf; buf.Copy( func );  buf.Insert(0, Entry); \
       
   286     Trace( TrGrp, buf ); \
       
   287 }
   265 }
   288 
   266 
   289 /*
   267 /*
   290  * Function exit trace with a parameter representing the instance identifier
   268  * Function exit trace with a parameter representing the instance identifier
   291  * for example "this" pointer.
   269  * for example "this" pointer.
   292  * The trace is mapped to TRACE_API group.
   270  * The trace is mapped to TRACE_API group.
   293  */
   271  */
   294 #define BOstraceFunctionExit1( aTraceName, aInstance ) \
   272 #define BOstraceFunctionExit1( aTraceName, aInstance ) \
   295 {\
   273 {\
   296     _LIT(TrGrp, "[ API ]"); \
   274     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   297     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   275     TBuf<200> buf; buf.Copy( func.Left(150) );  buf.Insert(0, _L("<< ")); \
   298     _LIT(Entry, "<< "); _LIT(Fmt, " 0x%X(%d)"); \
   276     TBtTraceOflowTruncate16 overflow; \
   299     TBuf<512> buf; buf.Copy( func );  buf.Insert(0, Entry); \
   277     buf.AppendFormat(_L(" 0x%X(%d)"), &overflow, aInstance, aInstance); \
   300     TBtTraceOflowTruncate16 overflow; \
   278     Trace( _L("[ API ]"), buf ); \
   301     buf.AppendFormat(Fmt, &overflow, aInstance, aInstance); \
       
   302     Trace( TrGrp, buf ); \
       
   303 }
   279 }
   304 
   280 
   305 /*
   281 /*
   306  * Function exit trace with parameters representing the instance identifier, 
   282  * Function exit trace with parameters representing the instance identifier, 
   307  * for example "this" pointer, and return value.
   283  * for example "this" pointer, and return value.
   308  * The trace is mapped to TRACE_API group.
   284  * The trace is mapped to TRACE_API group.
   309  */
   285  */
   310 #define BOstraceFunctionExitExt(aTraceName, aInstance, aRetval) \
   286 #define BOstraceFunctionExitExt(aTraceName, aInstance, aRetval) \
   311 {\
   287 {\
   312     _LIT(TrGrp, "[ API ]");\
   288     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   313     TPtrC8 func( (TUint8*) __PRETTY_FUNCTION__ ); \
   289     TBuf<200> buf; buf.Copy( func.Left(150) );  buf.Insert(0, _L("<< ")); \
   314     _LIT(Entry, "<< "); _LIT(Fmt, " 0x%X(%d) ret %d"); \
   290     TBtTraceOflowTruncate16 overflow; \
   315     TBuf<512> buf; buf.Copy( func );  buf.Insert(0, Entry); \
   291     buf.AppendFormat(_L(" 0x%X(%d) ret %d"), &overflow, aInstance, aInstance, aRetval); \
   316     TBtTraceOflowTruncate16 overflow; \
   292     Trace( _L("[ API ]"), buf ); \
   317     buf.AppendFormat(Fmt, &overflow, aInstance, aInstance, aRetval); \
       
   318     Trace( TrGrp, buf ); \
       
   319 }
   293 }
   320 
   294 
   321 /*
   295 /*
   322  * Performance measurement event start trace without extra parameters. 
   296  * Performance measurement event start trace without extra parameters. 
   323  * The trace is mapped to TRACE_PERFORMANCE group.
   297  * The trace is mapped to TRACE_PERFORMANCE group.
   324  */
   298  */
   325 #define BOstraceEventStart0( aTraceName, aEventName ) \
   299 #define BOstraceEventStart0( aTraceName, aEventName ) \
   326 {\
   300 {\
   327     _LIT(TrGrp, "[PFMAN]"); _LIT(EvName, aEventName); \
   301     TBuf<200> buf(_L("[Start] ")); buf.Append( aEventName ); \
   328     _LIT(Entry, "[Start] "); \
   302     Trace( _L("[PFMAN]"), buf ); \
   329     TBuf<512> buf(Entry); buf.Append( EvName ); \
       
   330     Trace( TrGrp, buf ); \
       
   331 }
   303 }
   332 
   304 
   333 /*
   305 /*
   334  * Performance measurement event start trace with single 32-bit parameter. 
   306  * Performance measurement event start trace with single 32-bit parameter. 
   335  * The trace is mapped to TRACE_PERFORMANCE group.
   307  * The trace is mapped to TRACE_PERFORMANCE group.
   336  */
   308  */
   337 #define BOstraceEventStart1( aTraceName, aEventName, aParam ) \
   309 #define BOstraceEventStart1( aTraceName, aEventName, aParam ) \
   338 {\
   310 {\
   339     _LIT(TrGrp, "[PFMAN]"); _LIT(EvName, aEventName); \
   311     TPtrC evt(aEventName); TBuf<200> buf; \
   340     _LIT(Entry, "[Start] %S 0x%X(%d)"); \
   312     TBtTraceOflowTruncate16 overflow; \
   341     TPtrC evt(EvName); TBuf<512> buf; \
   313     buf.AppendFormat(_L("[Start] %S 0x%X(%d)"), &overflow, &evt, aParam, aParam ); \
   342     TBtTraceOflowTruncate16 overflow; \
   314     Trace( _L("[PFMAN]"), buf ); \
   343     buf.AppendFormat(Entry, &overflow, &evt, aParam, aParam ); \
       
   344     Trace( TrGrp, buf ); \
       
   345 }
   315 }
   346 
   316 
   347 /*
   317 /*
   348  * Performance measurement event end trace. 
   318  * Performance measurement event end trace. 
   349  * The trace is mapped to TRACE_PERFORMANCE group.
   319  * The trace is mapped to TRACE_PERFORMANCE group.
   350  */
   320  */
   351 #define BOstraceEventStop( aTraceName, aEventName ) \
   321 #define BOstraceEventStop( aTraceName, aEventName ) \
   352 {\
   322 {\
   353     _LIT(TrGrp, "[PFMAN]"); _LIT(EvName, aEventName); \
   323     TBuf<200> buf(_L("[Stop] ")); buf.Append( aEventName ); \
   354     _LIT(Entry, "[Stop] "); \
   324     Trace( _L("[PFMAN]"), buf ); \
   355     TBuf<512> buf(Entry); buf.Append( EvName ); \
       
   356     Trace( TrGrp, buf ); \
       
   357 }
   325 }
   358 
   326 
   359 /*
   327 /*
   360  * State transition event.
   328  * State transition event.
   361  * The trace is mapped to TRACE_STATE group.
   329  * The trace is mapped to TRACE_STATE group.
   362  */
   330  */
   363 #define BOstraceState0( aTraceName, aStateName, aNewState ) \
   331 #define BOstraceState0( aTraceName, aStateName, aNewState ) \
   364 {\
   332 {\
   365     _LIT(TrGrp, "[STATE]"); _LIT(StName, aStateName); \
   333     TPtrC evt(aStateName); TBuf<200> buf; \
   366     _LIT(Entry, "%S 0x%X(%d)"); \
   334     TBtTraceOflowTruncate16 overflow; \
   367     TPtrC evt(StName); TBuf<512> buf; \
   335     buf.AppendFormat(_L("%S 0x%X(%d)"), &overflow, &evt, aNewState, aNewState ); \
   368     TBtTraceOflowTruncate16 overflow; \
   336     Trace( _L("[STATE]"), buf ); \
   369     buf.AppendFormat(Entry, &overflow, &evt, aNewState, aNewState ); \
       
   370     Trace( TrGrp, buf ); \
       
   371 }
   337 }
   372 
   338 
   373 /*
   339 /*
   374  * State transition event with instance identifier.
   340  * State transition event with instance identifier.
   375  * The trace is mapped to TRACE_STATE group.
   341  * The trace is mapped to TRACE_STATE group.
   376  */
   342  */
   377 #define BOstraceState1( aTraceName, aStateName, aNewState, aInstance ) \
   343 #define BOstraceState1( aTraceName, aStateName, aNewState, aInstance ) \
   378 {\
   344 {\
   379     _LIT(TrGrp, "[STATE]"); _LIT(StName, aStateName); \
   345     TPtrC evt(aStateName); TBuf<200> buf; \
   380     _LIT(Entry, "%S 0x%X(%d) instance=0x%X(%d)"); \
   346     TBtTraceOflowTruncate16 overflow; \
   381     TPtrC evt(StName); TBuf<512> buf; \
   347     buf.AppendFormat(_L("%S 0x%X(%d) instance=0x%X(%d)"), &overflow, &evt, aNewState, aNewState, aInstance, aInstance ); \
   382     TBtTraceOflowTruncate16 overflow; \
   348     Trace( _L("[STATE]"), buf ); \
   383     buf.AppendFormat(Entry, &overflow, &evt, aNewState, aNewState, aInstance, aInstance ); \
       
   384     Trace( TrGrp, buf ); \
       
   385 }
   349 }
   386 
   350 
   387 #endif // BLUETOOTHTRACE_MEDIA_OST
   351 #endif // BLUETOOTHTRACE_MEDIA_OST
   388 
   352 
   389 // Extended tracing macros facilitating domain specific tracing needs:
   353 // Extended tracing macros facilitating domain specific tracing needs:
   397  * trace macro for BT device address printing with an additional trace text. 
   361  * trace macro for BT device address printing with an additional trace text. 
   398  * aParam must be TBTDevAddr type.
   362  * aParam must be TBTDevAddr type.
   399  */
   363  */
   400 #define BtTraceBtAddr1( aGroupName, aTraceName, aTraceText, aParam ) \
   364 #define BtTraceBtAddr1( aGroupName, aTraceName, aTraceText, aParam ) \
   401 { \
   365 { \
   402     _LIT(TrTxt, aTraceText); TPtrC p(TrTxt); \
       
   403     TBuf<12> buf; \
   366     TBuf<12> buf; \
   404     aParam.GetReadable( buf ); TPtrC p2(buf);\
   367     aParam.GetReadable( buf ); TPtrC p2(buf);\
   405     BOstraceExt2( aGroupName, aTraceName, "%S%S", &p, &p2 ); \
   368     BOstraceExt2( aGroupName, aTraceName, "%S%S", aTraceText, &p2 ); \
   406 }
   369 }
   407 
   370 
   408 /*
   371 /*
   409  * trace macro for BT device address printing with no additional trace text. 
   372  * trace macro for BT device address printing with no additional trace text. 
   410  * aParam must be TBTDevAddr type.
   373  * aParam must be TBTDevAddr type.
   411  */
   374  */
   412 #define BtTraceBtAddr0( aGroupName, aTraceName, aParam ) \
   375 #define BtTraceBtAddr0( aGroupName, aTraceName, aParam ) \
   413 { \
   376 { \
   414     TBuf<12> buf; aParam.GetReadable( buf ); TPtrC p(buf); \
   377     TBuf<12> buf; aParam.GetReadable( buf ); TPtrC p(buf); \
   415     BOstraceExt1( aGroupName, aTraceName, "%S", &p ); \
   378     BOstraceExt1( aGroupName, aTraceName, _L("%S"), &p ); \
   416 }
   379 }
   417 
   380 
   418 #else // BLUETOOTHTRACE_ENABLED
   381 #else // BLUETOOTHTRACE_ENABLED
   419 
   382 
   420 #define BOstrace0( aGroupName, aTraceName, aTraceText )
   383 #define BOstrace0( aGroupName, aTraceName, aTraceText )