drivers/nble: Update RPC to Nordic chip

Following changes in NBLE firmware update our RPC, shall be compatible
with firmware images building from 02/10.

Change-Id: Ifeb1193a241e9fea39c52a6c0f5bbd6c21041c08
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
This commit is contained in:
Andrei Emeltchenko 2016-02-10 10:37:05 +02:00 committed by Anas Nashif
commit edd64e0746
3 changed files with 22 additions and 14 deletions

View file

@ -630,14 +630,11 @@ enum BLE_GAP_SCAN_OPTIONS {
BLE_GAP_SCAN_WHITE_LISTED = 0x02,
};
struct ble_gap_scan_params {
uint16_t timeout; /**< scan timeout in s, 0 never */
/**< interval: 0x4 - 0x4000 (unit: 0.625ms), default: 0xffff (0x0010) */
struct nble_gap_scan_params {
uint16_t interval;
/**< Window: 0x4 - 0x4000 (unit: 0.625ms), default 0xffff (= 0x0010) */
uint16_t window;
/**< scan options, ORed options from @ref BLE_GAP_SCAN_OPTIONS */
uint8_t options;
uint8_t scan_type;
uint8_t use_whitelist;
};
/**
@ -647,9 +644,8 @@ struct ble_gap_scan_params {
* @ref on_ble_gap_start_scan_rsp
*
* @param par Scan parameters
* @param user_data Pointer to user data
*/
void ble_gap_start_scan_req(const struct ble_gap_scan_params *par, void *priv);
void nble_gap_start_scan_req(const struct nble_gap_scan_params *par);
/**
* Response to @ref ble_gap_start_scan_req.
@ -859,6 +855,12 @@ struct ble_gap_conn_update_evt {
*/
void on_ble_gap_conn_update_evt(const struct ble_gap_conn_update_evt *ev);
struct nble_gap_adv_report_evt {
bt_addr_le_t addr;
int8_t rssi;
uint8_t adv_type;
};
struct ble_gap_rssi_evt {
uint16_t conn_handle; /**< Connection handle */
int8_t rssi_lvl; /**< RSSI level (compared to 0 dBm) */

View file

@ -15,10 +15,14 @@
*/
/* declare the list of functions sorted by signature */
#define LIST_FN_SIG_NONE
#define LIST_FN_SIG_NONE \
FN_SIG_NONE(nble_gap_stop_scan_req)
#define LIST_FN_SIG_S \
FN_SIG_S(ble_gap_start_advertise_req, struct ble_gap_adv_params *)
FN_SIG_S(ble_gap_start_advertise_req, \
struct ble_gap_adv_params *) \
FN_SIG_S(nble_gap_start_scan_req, \
const struct nble_gap_scan_params *)
#define LIST_FN_SIG_P \
FN_SIG_P(ble_get_version_req, void *) \
@ -26,7 +30,6 @@
FN_SIG_P(ble_gap_read_bda_req, void *) \
FN_SIG_P(ble_gap_stop_advertise_req, void *) \
FN_SIG_P(ble_gap_clr_white_list_req, void *) \
FN_SIG_P(ble_gap_stop_scan_req, void *) \
FN_SIG_P(ble_gap_sm_clear_bonds_req, void *) \
FN_SIG_P(ble_gap_cancel_connect_req, void *) \
FN_SIG_P(ble_get_bonded_device_list_req, void *)
@ -63,8 +66,6 @@
void *) \
FN_SIG_S_P(ble_gap_connect_req, \
const struct ble_gap_connect_req_params *, void *) \
FN_SIG_S_P(ble_gap_start_scan_req, \
const struct ble_gap_scan_params *, void *) \
FN_SIG_S_P(ble_gap_generic_cmd_req, \
const struct ble_gap_gen_cmd_params *, void *) \
FN_SIG_S_P(ble_gap_set_option_req, \

View file

@ -76,7 +76,9 @@
FN_SIG_S(on_ble_gap_stop_advertise_rsp, \
const struct ble_core_response *) \
FN_SIG_S(on_ble_gatts_read_evt, \
const struct nble_gatt_rd_evt *)
const struct nble_gatt_rd_evt *) \
FN_SIG_S(on_nble_gap_scan_start_stop_rsp, \
const struct ble_core_response *)
#define LIST_FN_SIG_P \
FN_SIG_P(on_ble_gap_dtm_init_rsp, void *)
@ -99,6 +101,9 @@
uint8_t) \
FN_SIG_S_B(on_ble_gattc_discover_rsp, \
const struct ble_gattc_disc_rsp *, \
const uint8_t *, uint8_t) \
FN_SIG_S_B(on_nble_gap_adv_report_evt, \
const struct nble_gap_adv_report_evt *, \
const uint8_t *, uint8_t)
#define LIST_FN_SIG_B_B_P