remove ble_srv_common.c dependency
This commit is contained in:
parent
3da08add42
commit
3c612f81f3
@ -11,7 +11,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/* Attention!
|
/* Attention!
|
||||||
* To maintain compliance with Nordic Semiconductor ASA’s Bluetooth profile
|
* To maintain compliance with Nordic Semiconductor ASAs Bluetooth profile
|
||||||
* qualification listings, this section of source code must not be modified.
|
* qualification listings, this section of source code must not be modified.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1005,6 +1005,12 @@ static void service_error_handler(uint32_t nrf_error)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void ascii_to_utf8(ble_srv_utf8_str_t * p_utf8, char * p_ascii)
|
||||||
|
{
|
||||||
|
p_utf8->length = (uint16_t)strlen(p_ascii);
|
||||||
|
p_utf8->p_str = (uint8_t *)p_ascii;
|
||||||
|
}
|
||||||
|
|
||||||
/**@brief Function for initializing services that will be used by the application.
|
/**@brief Function for initializing services that will be used by the application.
|
||||||
*/
|
*/
|
||||||
static void services_init(void)
|
static void services_init(void)
|
||||||
@ -1026,9 +1032,9 @@ static void services_init(void)
|
|||||||
ble_dis_init_t dis_init;
|
ble_dis_init_t dis_init;
|
||||||
memset(&dis_init, 0, sizeof(dis_init));
|
memset(&dis_init, 0, sizeof(dis_init));
|
||||||
|
|
||||||
ble_srv_ascii_to_utf8(&dis_init.manufact_name_str, DIS_MANUFACTURER);
|
ascii_to_utf8(&dis_init.manufact_name_str, DIS_MANUFACTURER);
|
||||||
ble_srv_ascii_to_utf8(&dis_init.model_num_str, DIS_MODEL);
|
ascii_to_utf8(&dis_init.model_num_str, DIS_MODEL);
|
||||||
ble_srv_ascii_to_utf8(&dis_init.fw_rev_str, DIS_FIRMWARE);
|
ascii_to_utf8(&dis_init.fw_rev_str, DIS_FIRMWARE);
|
||||||
|
|
||||||
BLE_GAP_CONN_SEC_MODE_SET_OPEN(&dis_init.dis_attr_md.read_perm);
|
BLE_GAP_CONN_SEC_MODE_SET_OPEN(&dis_init.dis_attr_md.read_perm);
|
||||||
BLE_GAP_CONN_SEC_MODE_SET_NO_ACCESS(&dis_init.dis_attr_md.write_perm);
|
BLE_GAP_CONN_SEC_MODE_SET_NO_ACCESS(&dis_init.dis_attr_md.write_perm);
|
||||||
|
@ -106,7 +106,6 @@ C_SOURCE_FILES += $(SDK_PATH)/drivers_nrf/common/nrf_drv_common.c
|
|||||||
C_SOURCE_FILES += $(SDK_PATH)/drivers_nrf/uart/nrf_drv_uart.c
|
C_SOURCE_FILES += $(SDK_PATH)/drivers_nrf/uart/nrf_drv_uart.c
|
||||||
#C_SOURCE_FILES += $(SDK_PATH)/drivers_nrf/power/nrf_drv_power.c
|
#C_SOURCE_FILES += $(SDK_PATH)/drivers_nrf/power/nrf_drv_power.c
|
||||||
|
|
||||||
C_SOURCE_FILES += $(SDK_PATH)/ble/common/ble_srv_common.c
|
|
||||||
C_SOURCE_FILES += $(SDK_PATH)/ble/ble_services/ble_dfu/ble_dfu.c
|
C_SOURCE_FILES += $(SDK_PATH)/ble/ble_services/ble_dfu/ble_dfu.c
|
||||||
C_SOURCE_FILES += $(SDK_PATH)/ble/ble_services/ble_dis/ble_dis.c
|
C_SOURCE_FILES += $(SDK_PATH)/ble/ble_services/ble_dis/ble_dis.c
|
||||||
|
|
||||||
|
@ -69,7 +69,6 @@
|
|||||||
</folder>
|
</folder>
|
||||||
</folder>
|
</folder>
|
||||||
<folder Name="common">
|
<folder Name="common">
|
||||||
<file file_name="../../nRF5_SDK_11.0.0_89a8197/components/ble/common/ble_srv_common.c" />
|
|
||||||
<file file_name="../../nRF5_SDK_11.0.0_89a8197/components/ble/common/ble_srv_common.h" />
|
<file file_name="../../nRF5_SDK_11.0.0_89a8197/components/ble/common/ble_srv_common.h" />
|
||||||
</folder>
|
</folder>
|
||||||
</folder>
|
</folder>
|
||||||
|
Loading…
Reference in New Issue
Block a user