mcu_hi3321_watch/tjd/ble/protocol/ble_sleep_server.h
2025-05-26 20:15:20 +08:00

52 lines
1.4 KiB
C

/*----------------------------------------------------------------------------
* Copyright (c) Fenda Technologies Co., Ltd. 2021. All rights reserved.
*
* Description: ble_sleep_server.h
*
* Author: shey.tanxiaoyu
*
* Create: 2021-09-13
*--------------------------------------------------------------------------*/
#ifndef __BLE_SLEEP_SERVER__H
#define __BLE_SLEEP_SERVER__H
#include <stdint.h>
#include "ble_protocol.h"
enum {
SLEEP_FRAME_START_TIME_TYPE = 0x01,
SLEEP_FRAME_END_TIME_TYPE = 0x02,
SLEEP_FRAME_COUNT_TYPE = 0x03,
};
enum {
SLEEP_ACTIVE_NOTIFY_TYPE = 0x01,
};
enum {
SLEEP_FRAME_INDEX_TYPE = 0x01,
SLEEP_FRAME_LIST_TYPE = 0xFE,
SLEEP_TYPE_TYPE = 0x02,
SLEEP_START_TIME_TYPE = 0x03,
SLEEP_TIME_OFFSET_TYPE = 0x04,
};
enum {
SET_SLEEP_MEASURING_SWITCH_TYPE = 0x01,
};
enum {
GET_SLEEP_MEASURE_FRAME_NUMBER_ID = 1, //4.6.1
SLEEP_MEASURE_REPORT_ID, //4.6.2
GET_SLEEP_MEASURE_FRAME_DETAIL_ID, //4.6.3
SET_SLEEP_MEASURE_SWITCH_ID, //4.6.4
SLEEP_SERVERE_MAX_ID,
};
void ble_sleep_measure_report(void);
extern const p_func_t sleep_server_func[SLEEP_SERVERE_MAX_ID];
#endif