xref: /btstack/platform/embedded/hci_dump_segger_rtt_binary.h (revision 2fca4dad957cd7b88f4657ed51e89c12615dda72)
1128d6c99SMatthias Ringwald /*
2128d6c99SMatthias Ringwald  * Copyright (C) 2014 BlueKitchen GmbH
3128d6c99SMatthias Ringwald  *
4128d6c99SMatthias Ringwald  * Redistribution and use in source and binary forms, with or without
5128d6c99SMatthias Ringwald  * modification, are permitted provided that the following conditions
6128d6c99SMatthias Ringwald  * are met:
7128d6c99SMatthias Ringwald  *
8128d6c99SMatthias Ringwald  * 1. Redistributions of source code must retain the above copyright
9128d6c99SMatthias Ringwald  *    notice, this list of conditions and the following disclaimer.
10128d6c99SMatthias Ringwald  * 2. Redistributions in binary form must reproduce the above copyright
11128d6c99SMatthias Ringwald  *    notice, this list of conditions and the following disclaimer in the
12128d6c99SMatthias Ringwald  *    documentation and/or other materials provided with the distribution.
13128d6c99SMatthias Ringwald  * 3. Neither the name of the copyright holders nor the names of
14128d6c99SMatthias Ringwald  *    contributors may be used to endorse or promote products derived
15128d6c99SMatthias Ringwald  *    from this software without specific prior written permission.
16128d6c99SMatthias Ringwald  * 4. Any redistribution, use, or modification is done solely for
17128d6c99SMatthias Ringwald  *    personal benefit and not for any commercial purpose or for
18128d6c99SMatthias Ringwald  *    monetary gain.
19128d6c99SMatthias Ringwald  *
20128d6c99SMatthias Ringwald  * THIS SOFTWARE IS PROVIDED BY BLUEKITCHEN GMBH AND CONTRIBUTORS
21128d6c99SMatthias Ringwald  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22128d6c99SMatthias Ringwald  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
23*2fca4dadSMilanka Ringwald  * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BLUEKITCHEN
24*2fca4dadSMilanka Ringwald  * GMBH OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
25128d6c99SMatthias Ringwald  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
26128d6c99SMatthias Ringwald  * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
27128d6c99SMatthias Ringwald  * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
28128d6c99SMatthias Ringwald  * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
29128d6c99SMatthias Ringwald  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
30128d6c99SMatthias Ringwald  * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31128d6c99SMatthias Ringwald  * SUCH DAMAGE.
32128d6c99SMatthias Ringwald  *
33128d6c99SMatthias Ringwald  * Please inquire about commercial licensing options at
34128d6c99SMatthias Ringwald  * [email protected]
35128d6c99SMatthias Ringwald  *
36128d6c99SMatthias Ringwald  */
37128d6c99SMatthias Ringwald 
38128d6c99SMatthias Ringwald /*
39128d6c99SMatthias Ringwald  * Dump HCI trace on SEGGER RTT Logging Channel #1
40128d6c99SMatthias Ringwald  */
41128d6c99SMatthias Ringwald 
42128d6c99SMatthias Ringwald #ifndef HCI_DUMP_SEGGER_RTT_BINARY_H
43128d6c99SMatthias Ringwald #define HCI_DUMP_SEGGER_RTT_BINARY_H
44128d6c99SMatthias Ringwald 
45128d6c99SMatthias Ringwald #include <stdint.h>
46128d6c99SMatthias Ringwald #include <stdarg.h>       // for va_list
47128d6c99SMatthias Ringwald 
48128d6c99SMatthias Ringwald #include "hci_dump.h"
49128d6c99SMatthias Ringwald 
50128d6c99SMatthias Ringwald #if defined __cplusplus
51128d6c99SMatthias Ringwald extern "C" {
52128d6c99SMatthias Ringwald #endif
53128d6c99SMatthias Ringwald 
54128d6c99SMatthias Ringwald /**
55128d6c99SMatthias Ringwald  * @brief Get HCI Dump SEGGER RTT Binary Instance
56128d6c99SMatthias Ringwald  * @return hci_dump_impl
57128d6c99SMatthias Ringwald  */
58128d6c99SMatthias Ringwald const hci_dump_t * hci_dump_segger_rtt_binary_get_instance(void);
59128d6c99SMatthias Ringwald 
60128d6c99SMatthias Ringwald /**
61128d6c99SMatthias Ringwald  * @brief Open Log Channel
62128d6c99SMatthias Ringwald  * @param format
63128d6c99SMatthias Ringwald  */
64128d6c99SMatthias Ringwald void hci_dump_segger_rtt_binary_open(hci_dump_format_t format);
65128d6c99SMatthias Ringwald 
66128d6c99SMatthias Ringwald /* API_END */
67128d6c99SMatthias Ringwald 
68128d6c99SMatthias Ringwald #if defined __cplusplus
69128d6c99SMatthias Ringwald }
70128d6c99SMatthias Ringwald #endif
71128d6c99SMatthias Ringwald #endif // HCI_DUMP_SEGGER_RTT_STDOUT_H
72