-
Notifications
You must be signed in to change notification settings - Fork 399
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
nimble: controller: Add initial support for CS HCI
Add stubs for Channel Sounding.
- Loading branch information
1 parent
58eb408
commit f639326
Showing
6 changed files
with
273 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, | ||
* software distributed under the License is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
* KIND, either express or implied. See the License for the | ||
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
|
||
/* All Channel Sounding APIs are experimental and subject to change at any time */ | ||
|
||
#ifndef H_BLE_LL_CS | ||
#define H_BLE_LL_CS | ||
|
||
#include <stdint.h> | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
/* HCI handlers */ | ||
int ble_ll_cs_hci_rd_loc_supp_cap(uint8_t *rspbuf, uint8_t *rsplen); | ||
int ble_ll_cs_hci_rd_rem_supp_cap(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_wr_cached_rem_supp_cap(const uint8_t *cmdbuf, uint8_t cmdlen, uint8_t *rspbuf, uint8_t *rsplen); | ||
int ble_ll_cs_hci_sec_enable(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_set_def_settings(const uint8_t *cmdbuf, uint8_t cmdlen, uint8_t *rspbuf, uint8_t *rsplen); | ||
int ble_ll_cs_hci_rd_rem_fae(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_wr_cached_rem_fae(const uint8_t *cmdbuf, uint8_t cmdlen, uint8_t *rspbuf, uint8_t *rsplen); | ||
int ble_ll_cs_hci_create_config(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_remove_config(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_set_chan_class(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_set_proc_params(const uint8_t *cmdbuf, uint8_t cmdlen, uint8_t *rspbuf, uint8_t *rsplen); | ||
int ble_ll_cs_hci_proc_enable(const uint8_t *cmdbuf, uint8_t cmdlen); | ||
int ble_ll_cs_hci_test(const uint8_t *cmdbuf, uint8_t cmdlen, uint8_t *rspbuf, uint8_t *rsplen); | ||
int ble_ll_cs_hci_test_end(void); | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, | ||
* software distributed under the License is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
* KIND, either express or implied. See the License for the | ||
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
|
||
#include <syscfg/syscfg.h> | ||
#if MYNEWT_VAL(BLE_LL_CHANNEL_SOUNDING) | ||
#include <stdint.h> | ||
#include "nimble/hci_common.h" | ||
#include "controller/ble_ll_utils.h" | ||
#include "controller/ble_ll.h" | ||
#include "controller/ble_ll_conn.h" | ||
#include "controller/ble_ll_hci.h" | ||
#include "controller/ble_ll_cs.h" | ||
|
||
int | ||
ble_ll_cs_hci_rd_loc_supp_cap(uint8_t *rspbuf, uint8_t *rsplen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_rd_rem_supp_cap(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_wr_cached_rem_supp_cap(const uint8_t *cmdbuf, uint8_t cmdlen, | ||
uint8_t *rspbuf, uint8_t *rsplen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_sec_enable(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_set_def_settings(const uint8_t *cmdbuf, uint8_t cmdlen, | ||
uint8_t *rspbuf, uint8_t *rsplen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_rd_rem_fae(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_wr_cached_rem_fae(const uint8_t *cmdbuf, uint8_t cmdlen, | ||
uint8_t *rspbuf, uint8_t *rsplen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_create_config(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_remove_config(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_set_chan_class(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_set_proc_params(const uint8_t *cmdbuf, uint8_t cmdlen, | ||
uint8_t *rspbuf, uint8_t *rsplen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_proc_enable(const uint8_t *cmdbuf, uint8_t cmdlen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_test(const uint8_t *cmdbuf, uint8_t cmdlen, | ||
uint8_t *rspbuf, uint8_t *rsplen) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
int | ||
ble_ll_cs_hci_test_end(void) | ||
{ | ||
return BLE_ERR_UNSUPPORTED; | ||
} | ||
|
||
#endif /* BLE_LL_CHANNEL_SOUNDING */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters