xref: /btstack/chipset/atwilc3000/btstack_chipset_atwilc3000.h (revision c7d3427cb5e932ff8c99d04eee15ac67d949bfbc)
1ccebdf93SMatthias Ringwald /*
2ccebdf93SMatthias Ringwald  * Copyright (C) 2014 BlueKitchen GmbH
3ccebdf93SMatthias Ringwald  *
4ccebdf93SMatthias Ringwald  * Redistribution and use in source and binary forms, with or without
5ccebdf93SMatthias Ringwald  * modification, are permitted provided that the following conditions
6ccebdf93SMatthias Ringwald  * are met:
7ccebdf93SMatthias Ringwald  *
8ccebdf93SMatthias Ringwald  * 1. Redistributions of source code must retain the above copyright
9ccebdf93SMatthias Ringwald  *    notice, this list of conditions and the following disclaimer.
10ccebdf93SMatthias Ringwald  * 2. Redistributions in binary form must reproduce the above copyright
11ccebdf93SMatthias Ringwald  *    notice, this list of conditions and the following disclaimer in the
12ccebdf93SMatthias Ringwald  *    documentation and/or other materials provided with the distribution.
13ccebdf93SMatthias Ringwald  * 3. Neither the name of the copyright holders nor the names of
14ccebdf93SMatthias Ringwald  *    contributors may be used to endorse or promote products derived
15ccebdf93SMatthias Ringwald  *    from this software without specific prior written permission.
16ccebdf93SMatthias Ringwald  * 4. Any redistribution, use, or modification is done solely for
17ccebdf93SMatthias Ringwald  *    personal benefit and not for any commercial purpose or for
18ccebdf93SMatthias Ringwald  *    monetary gain.
19ccebdf93SMatthias Ringwald  *
20ccebdf93SMatthias Ringwald  * THIS SOFTWARE IS PROVIDED BY BLUEKITCHEN GMBH AND CONTRIBUTORS
21ccebdf93SMatthias Ringwald  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22ccebdf93SMatthias Ringwald  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
23ccebdf93SMatthias Ringwald  * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL MATTHIAS
24ccebdf93SMatthias Ringwald  * RINGWALD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
25ccebdf93SMatthias Ringwald  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
26ccebdf93SMatthias Ringwald  * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
27ccebdf93SMatthias Ringwald  * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
28ccebdf93SMatthias Ringwald  * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
29ccebdf93SMatthias Ringwald  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
30ccebdf93SMatthias Ringwald  * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31ccebdf93SMatthias Ringwald  * SUCH DAMAGE.
32ccebdf93SMatthias Ringwald  *
33ccebdf93SMatthias Ringwald  * Please inquire about commercial licensing options at
34ccebdf93SMatthias Ringwald  * [email protected]
35ccebdf93SMatthias Ringwald  *
36ccebdf93SMatthias Ringwald  */
37ccebdf93SMatthias Ringwald 
38ccebdf93SMatthias Ringwald /*
39ccebdf93SMatthias Ringwald  *  btstack_chipset_atwilc3000.c
40ccebdf93SMatthias Ringwald  *
41ccebdf93SMatthias Ringwald  *  Adapter to use atwilc3000-based chipsets with BTstack
42ccebdf93SMatthias Ringwald  *
43ccebdf93SMatthias Ringwald  */
44ccebdf93SMatthias Ringwald 
45ccebdf93SMatthias Ringwald #ifndef __BTSTACK_CHIPSET_ATWILC3000_H
46ccebdf93SMatthias Ringwald #define __BTSTACK_CHIPSET_ATWILC3000_H
47ccebdf93SMatthias Ringwald 
48ccebdf93SMatthias Ringwald #if defined __cplusplus
49ccebdf93SMatthias Ringwald extern "C" {
50ccebdf93SMatthias Ringwald #endif
51ccebdf93SMatthias Ringwald 
52ccebdf93SMatthias Ringwald #include "btstack_chipset.h"
53ccebdf93SMatthias Ringwald #include "btstack_uart_block.h"
54ccebdf93SMatthias Ringwald 
55ccebdf93SMatthias Ringwald /**
56ccebdf93SMatthias Ringwald  * @brief get chipset instance
57ccebdf93SMatthias Ringwald  */
58ccebdf93SMatthias Ringwald const btstack_chipset_t * btstack_chipset_atwilc3000_instance(void);
59ccebdf93SMatthias Ringwald 
60ccebdf93SMatthias Ringwald /**
61ccebdf93SMatthias Ringwald  * @brief Download firmware via uart_driver
62ccebdf93SMatthias Ringwald  * @param uart_driver -- already initialized
63*c7d3427cSMatthias Ringwald  * @param baudrate for firmware update
64ccebdf93SMatthias Ringwald  * @param done callback. 0 = Success
65ccebdf93SMatthias Ringwald  */
66*c7d3427cSMatthias Ringwald void btstack_chipset_atwilc3000_download_firmware(const btstack_uart_block_t * uart_driver, uint32_t baudrate, const uint8_t * fw, uint32_t fw_size, void (*done)(int result));
67ccebdf93SMatthias Ringwald 
68ccebdf93SMatthias Ringwald #if defined __cplusplus
69ccebdf93SMatthias Ringwald }
70ccebdf93SMatthias Ringwald #endif
71ccebdf93SMatthias Ringwald 
72ccebdf93SMatthias Ringwald #endif // __BTSTACK_CHIPSET_ATWILC3000_H
73