#endif
#endif
-uint32_t ConfigModelInit(void)
-{
- OHOS::ConfigModel::GetInstance()->Init();
- return 0;
-}
-
-/***
- * 蓝牙服务是否开启
- */
-bool custom_ble_service_on_flag(void)
-{
- return OHOS::ConfigModel::GetInstance()->GetClassicBlueToothState();
-}
-/***
- * Cat1服务是否开启
- */
-bool poweron_cat1_on_bootup_flag(void)
-{
- return OHOS::ConfigModel::GetInstance()->GetCat1_4Gability();
-}
-void sync_all_config_to_disk(void)
-{
- OHOS::ConfigModel::GetInstance()->sync_all_to_disk();
-}
-
+ uint32_t ConfigModelInit(void)
+ {
+ OHOS::ConfigModel::GetInstance()->Init();
+ return 0;
+ }
-void initScreenBrightness(void)
-{
- WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "initScreenBrightness");
- int brightness = OHOS::ConfigModel::GetInstance()->GetBrightness();
- uapi_setScreenBrightness(brightness);
-}
+ /***
+ * 蓝牙服务是否开启
+ */
+ bool custom_ble_service_on_flag(void)
+ {
+ return OHOS::ConfigModel::GetInstance()->GetClassicBlueToothState();
+ }
+ /***
+ * Cat1服务是否开启
+ */
+ bool poweron_cat1_on_bootup_flag(void)
+ {
+ return OHOS::ConfigModel::GetInstance()->GetCat1_4Gability();
+ }
+ void sync_all_config_to_disk(void)
+ {
+ OHOS::ConfigModel::GetInstance()->sync_all_to_disk();
+ }
-void initializeScreenDuration(void)
-{
- WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "initializeScreenDuration");
- unsigned int time = OHOS::ConfigModel::GetInstance()->GetScreenDuration();
- uapi_setScreenDuration(time);
-}
+ void initScreenBrightness(void)
+ {
+ WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "initScreenBrightness");
+ int brightness = OHOS::ConfigModel::GetInstance()->GetBrightness();
+ uapi_setScreenBrightness(brightness);
+ }
-void initializeRaiseToWake(void)
-{
- WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "initializeRaiseToWake");
- bool isOpen = OHOS::ConfigModel::GetInstance()->GetRaiseToWake();
- if(isOpen == true)
+ void initializeScreenDuration(void)
{
- uapi_take_to_wake(1);
+ WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "initializeScreenDuration");
+ unsigned int time = OHOS::ConfigModel::GetInstance()->GetScreenDuration();
+ uapi_setScreenDuration(time);
}
- else
+
+ void initializeRaiseToWake(void)
{
- uapi_take_to_wake(0);
+ WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "initializeRaiseToWake");
+ bool isOpen = OHOS::ConfigModel::GetInstance()->GetRaiseToWake();
+ if (isOpen == true)
+ {
+ uapi_take_to_wake(1);
+ }
+ else
+ {
- uapi_take_to_wake(2);
++ uapi_take_to_wake(0);
+ }
}
-}
#ifdef __cplusplus
#if __cplusplus
}
{
display_api->turn_on_screen();
}
+ // 设置屏幕亮5000
+ display_api->set_screen_set_keepon_timeout(5000);
}
+ /*系统声音设置*/
+ void uapi_systemVolumeSet(int16_t sounding)
+ {
+ SystemVolumeSet(sounding);
+ }
+
+ //通话音量设置
+ void uapi_callVolumeSet(int16_t sounding)
+ {
+ CallVolumeSet(sounding);
+ }
+
#include "bts_le_gap.h"
-
-
// extern void wstp_spp_cmd_server_create(const char *spp_uuid, const char *name, uint8_t name_len);
// extern void wstp_spp_cmd_server_accept(uint32_t server_id);
// extern errcode_t enable_bt_stack(void);