56 lines
1.9 KiB
C
56 lines
1.9 KiB
C
/**************************************************************************************************
|
|
* Copyright (c) Fenda Technologies Co., Ltd. 2020-2021. All rights reserved.
|
|
* Description: 多语言服务接口函数
|
|
* Author: sean.wangxiaochao
|
|
* Create: 2021-01-04
|
|
************************************************************************************************/
|
|
|
|
|
|
#ifndef _USER_MULTI_LANGUAGE_SERVER_H_
|
|
#define _USER_MULTI_LANGUAGE_SERVER_H_
|
|
|
|
#include "stdint.h"
|
|
#include "ble_protocol.h"
|
|
|
|
// 4.25.1 APP 切换语言
|
|
enum {
|
|
MULTI_LANGUAGE_TYPE = 0x01,
|
|
MULTI_COUNTRY_LANGUAGE_TYPE = 0x02,
|
|
MULTI_COUNTRY_TYPE = 0x03,
|
|
};
|
|
|
|
// 4.25.2 询问设备语言包是否可以下发
|
|
enum {
|
|
MULTI_LANGUAGE_FILE_SEND_ASK_TYPE = 0x01,
|
|
MULTI_LANGUAGE_FILE_ID_TYPE = 0x02,
|
|
MULTI_LANGUAGE_SEND_RESULT_TYPE = 0x03,
|
|
};
|
|
//4.25.3获取设备支持的语言列表与已有的语言
|
|
enum {
|
|
MULTI_LANGUAGE_LIST_TYPE = 0x01,
|
|
MULTI_LANGUAGE_INFO_TYPE = 0xFE,
|
|
MULTI_LANGUAGE_SUPPORT_TYPE = 0x02,
|
|
MULTI_LANGUAGE_EXITING_TYPE = 0x03,
|
|
};
|
|
|
|
void BLE_multiLanguageSwitch(uint8_t *in_data, uint16_t in_len, uint8_t *out_data, uint16_t *out_len);
|
|
|
|
void BLE_requestIfSendMultiLanguageFile(uint8_t *in_data, uint16_t in_len, uint8_t *out_data, uint16_t *out_len);
|
|
|
|
void BLE_requestSupportLanguageInfo(uint8_t *in_data, uint16_t in_len, uint8_t *out_data, uint16_t *out_len);
|
|
|
|
|
|
/********************************
|
|
多国语言服务命令ID
|
|
**********************************/
|
|
enum {
|
|
MULTI_LANGUAGE_SWITCH_ID = 1, //4.25.1
|
|
MULTI_LANGUAGE_SEND_ASK_ID = 2, //4.25.2
|
|
MULTI_LANGUAGE_SUPPORT_ID = 3, //4.25.3
|
|
MULTI_LANGUAGE_SERVERE_MAX_ID,
|
|
};
|
|
extern const p_func_t multiLanguageServerFunc[MULTI_LANGUAGE_SERVERE_MAX_ID];
|
|
|
|
#endif
|
|
|