Infineon Logo AIROC BTSDK v4.7 - Documentation
 
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
AIROC Trace Utilities

Trace Utilities. More...

Macros

#define WICED_BT_TRACE(...)   wiced_printf(NULL, 0, __VA_ARGS__)
 Macro WICED_BT_TRACE. More...
 
#define WICED_BT_TRACE_ARRAY(ptr, len,...)   wiced_printf(NULL, 0, __VA_ARGS__); wiced_trace_array(ptr, len);
 Macro WICED_BT_TRACE_ARRAY. More...
 
#define wiced_set_debug_uart   wiced_set_debug_uart_patch
 Macro wiced_set_debug_uart. More...
 

Enumerations

enum  wiced_debug_uart_types_t {
  WICED_ROUTE_DEBUG_NONE = 0x00, WICED_ROUTE_DEBUG_TO_WICED_UART, WICED_ROUTE_DEBUG_TO_HCI_UART, WICED_ROUTE_DEBUG_TO_DBG_UART,
  WICED_ROUTE_DEBUG_TO_PUART
}
 Debug trace message destinations. More...
 

Functions

void wiced_set_debug_uart_patch (wiced_debug_uart_types_t uart)
 Function wiced_set_debug_uart. More...
 
void wiced_set_debug_uart_baudrate (uint32_t baudrate)
 Function wiced_set_debug_uart_baudrate. More...
 

Detailed Description

Trace Utilities.

Support for applications to send debug or information messages to debug UART destinations.

Macro Definition Documentation

#define WICED_BT_TRACE (   ...)    wiced_printf(NULL, 0, __VA_ARGS__)

Macro WICED_BT_TRACE.

Utility macro to output trace messages to the debug UART destination.

Use this printf()-style macro to print custom messages from application code. Standard printf() % format arguments supported include: 'u,d,i,x,X,c,s'

In addition, a custom B format argument is provided for convenience in printing 6 octect Bluetooth addresses. Supply a byte array as the corresponding argument to match the B format specifier. For example:

WICED_BT_TRACE("Received inquiry response from: %B\n", p_inquiry_result->remote_bd_addr);

#define WICED_BT_TRACE_ARRAY (   ptr,
  len,
  ... 
)    wiced_printf(NULL, 0, __VA_ARGS__); wiced_trace_array(ptr, len);

Macro WICED_BT_TRACE_ARRAY.

Utility macro to dump a string message followed by an array of hex data to the debug UART destination.

Use this macro to display a string message followed by up to 16 hex bytes of an array from application code. For example:

WICED_BT_TRACE_ARRAY("Received EIR data:\n", p_inquiry_result->eir);

#define wiced_set_debug_uart   wiced_set_debug_uart_patch

Macro wiced_set_debug_uart.

Override/redirect to wiced_set_debug_uart_patch()

Enumeration Type Documentation

Debug trace message destinations.

Used when calling wiced_set_debug_uart().

Enumerator
WICED_ROUTE_DEBUG_NONE 

No traces.

WICED_ROUTE_DEBUG_TO_WICED_UART 

send debug strings in formatted AIROC HCI messages over HCI UART to ClientControl or MCU

WICED_ROUTE_DEBUG_TO_HCI_UART 

send debug strings as plain text to HCI UART, used by default if wiced_set_debug_uart() not called

WICED_ROUTE_DEBUG_TO_DBG_UART 

Deprecated.

WICED_ROUTE_DEBUG_TO_PUART 

send debug strings as plain text to the peripheral uart (PUART)

Function Documentation

void wiced_set_debug_uart_baudrate ( uint32_t  baudrate)

Function wiced_set_debug_uart_baudrate.

It configures the value for wiced_set_debug_uart.

Parameters
[in]baudrate: baudrate to be used
Returns
void
Note
To reflect the configured baudrate, wiced_set_debug_uart API should be invoked
void wiced_set_debug_uart_patch ( wiced_debug_uart_types_t  uart)

Function wiced_set_debug_uart.

To specify the UART to be used for the debug traces. Overridden by #define to wiced_set_debug_uart_patch()

Parameters
[in]uart: type of the UART to be used (see wiced_debug_uart_types_t)
Returns
void