Mistake on this page?
Report an issue in GitHub or email us
hci_drv.h
Go to the documentation of this file.
1 /*************************************************************************************************/
2 /*!
3  * \file
4  *
5  * \brief HCI driver interface.
6  *
7  * Copyright (c) 2012-2018 Arm Ltd. All Rights Reserved.
8  *
9  * Copyright (c) 2019 Packetcraft, Inc.
10  *
11  * Licensed under the Apache License, Version 2.0 (the "License");
12  * you may not use this file except in compliance with the License.
13  * You may obtain a copy of the License at
14  *
15  * http://www.apache.org/licenses/LICENSE-2.0
16  *
17  * Unless required by applicable law or agreed to in writing, software
18  * distributed under the License is distributed on an "AS IS" BASIS,
19  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20  * See the License for the specific language governing permissions and
21  * limitations under the License.
22  */
23 /*************************************************************************************************/
24 #ifndef HCI_DRV_H
25 #define HCI_DRV_H
26 
27 #ifdef __cplusplus
28 extern "C" {
29 #endif
30 
31 /**************************************************************************************************
32  Function Declarations
33 **************************************************************************************************/
34 
35 /*************************************************************************************************/
36 /*!
37  * \brief Write data the driver.
38  *
39  * \param type HCI packet type
40  * \param len Number of bytes to write.
41  * \param pData Byte array to write.
42  *
43  * \return Return actual number of data bytes written.
44  *
45  * \note The type parameter allows the driver layer to prepend the data with a header on the
46  * same write transaction.
47  */
48 /*************************************************************************************************/
49 uint16_t hciDrvWrite(uint8_t type, uint16_t len, uint8_t *pData);
50 
51 /*************************************************************************************************/
52 /*!
53  * \brief Read data bytes from the driver.
54  *
55  * \param len Number of bytes to read.
56  * \param pData Byte array to store data.
57  *
58  * \return Return actual number of data bytes read.
59  */
60 /*************************************************************************************************/
61 uint16_t hciDrvRead(uint16_t len, uint8_t *pData);
62 
63 /*************************************************************************************************/
64 /*!
65  * \brief Returns TRUE if driver allows MCU to enter low power sleep mode.
66  *
67  * \return TRUE if ready to sleep, FALSE otherwise.
68  */
69 /*************************************************************************************************/
70 bool_t hciDrvReadyToSleep(void);
71 
72 #ifdef __cplusplus
73 };
74 #endif
75 
76 #endif /* HCI_DRV_H */
uint16_t hciDrvWrite(uint8_t type, uint16_t len, uint8_t *pData)
Write data the driver.
uint16_t hciDrvRead(uint16_t len, uint8_t *pData)
Read data bytes from the driver.
bool_t hciDrvReadyToSleep(void)
Returns TRUE if driver allows MCU to enter low power sleep mode.
Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.