|
|
@ -1,6 +1,7 @@ |
|
|
|
#include <math.h> |
|
|
|
|
|
|
|
#include "app_event.h" |
|
|
|
#include "basic/device_info_mgr.h" |
|
|
|
#include "basic/zble_module.h" |
|
|
|
#include "basic/zdatachannel_service.h" |
|
|
|
#include "ble_cmd_process_service.h" |
|
|
@ -398,10 +399,14 @@ void one_conduction_main() { |
|
|
|
ztm_t tm; |
|
|
|
znordic_rtc_gettime(&tm); |
|
|
|
NRF_LOG_INFO("RTC time :%d-%d-%d %d:%d:%d", tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, tm.tm_hour, tm.tm_min, tm.tm_sec); |
|
|
|
static uint8_t ble_name[20]; |
|
|
|
sn_t sn; |
|
|
|
device_info_read_sn(&sn); |
|
|
|
memcpy(ble_name, sn.sn, sizeof(sn.sn)); |
|
|
|
|
|
|
|
static zble_module_cfg_t cfg = // |
|
|
|
{ |
|
|
|
.deviceName = BLE_NAME, |
|
|
|
.deviceName = ble_name, |
|
|
|
.on_service_init = on_service_init, |
|
|
|
}; |
|
|
|
zble_module_init(&cfg); |
|
|
|