| Airoha M0 BLE API 1.0.5.4

service_generic_access.h
1 /******************************************************************************
2 Copyright (c) Airoha 2016 - All rights reserved
3
4 FILE NAME
5 service_generic_access.h
6 DESCRIPTION
7 NOTES
8 ********************************************************************************/
9 #ifndef __GENERIC_ACCESS_SERVICE_H_
10 #define __GENERIC_ACCESS_SERVICE_H_
11
19 #include "ble_gatt_server.h"
20
24 typedef struct
25 {
26 uint16_t min_interval;
27 uint16_t max_interval;
28 uint16_t slave_latency;
29 uint16_t supervision_TO;
30 }PPCP_t;
31
35 typedef struct
36 {
37 uint16_t appearance;
38 uint8_t * device_name_buf;
39 uint16_t device_name_ini_length;
40 uint16_t device_name_max_length;
41 ATTCB device_name_write_CB;
42 PPCP_t * parameter;
43 ATTCB appearance_write_CB;
44 }gas_init_para;
45
49 typedef struct
50 {
51 uint8_t * reconnection_addr;
52 ATTCB reconnection_addr_CB;
53 }gas_privacy_init_para;
54
60 void GAS_init(gas_init_para * para);
61
67 void GAS_support_privacy_feature(gas_privacy_init_para * para);
68
69
70
71
72
76 #endif
gas_privacy_init_para::reconnection_addr
uint8_t * reconnection_addr
Definition: service_generic_access.h:51
gas_privacy_init_para
privacy feature initialization Parameters
Definition: service_generic_access.h:49
gas_init_para::device_name_write_CB
ATTCB device_name_write_CB
Definition: service_generic_access.h:41
gas_init_para::parameter
PPCP_t * parameter
Definition: service_generic_access.h:42
gas_privacy_init_para::reconnection_addr_CB
ATTCB reconnection_addr_CB
Definition: service_generic_access.h:52
GAS_support_privacy_feature
void GAS_support_privacy_feature(gas_privacy_init_para *para)
Initialization function of privacy feature. Should not be used before GAS_init.
PPCP_t::slave_latency
uint16_t slave_latency
Definition: service_generic_access.h:28
ATTCB
void(* ATTCB)(ATT_CB_TYPE type, uint8_t linkindex, uint16_t handle)
attribute value accessed call back function.
Definition: ble_att.h:111
PPCP_t::min_interval
uint16_t min_interval
Definition: service_generic_access.h:26
gas_init_para::appearance_write_CB
ATTCB appearance_write_CB
Definition: service_generic_access.h:43
gas_init_para::device_name_ini_length
uint16_t device_name_ini_length
Definition: service_generic_access.h:39
GAS_init
void GAS_init(gas_init_para *para)
Initialization function of generic access service.
gas_init_para::device_name_buf
uint8_t * device_name_buf
Definition: service_generic_access.h:38
gas_init_para::appearance
uint16_t appearance
Definition: service_generic_access.h:37
PPCP_t
Peripheral Preferred Connection Parameters.
Definition: service_generic_access.h:24
PPCP_t::supervision_TO
uint16_t supervision_TO
Definition: service_generic_access.h:29
PPCP_t::max_interval
uint16_t max_interval
Definition: service_generic_access.h:27
gas_init_para
generic access service initialization Parameters
Definition: service_generic_access.h:35
gas_init_para::device_name_max_length
uint16_t device_name_max_length
Definition: service_generic_access.h:40