11bd4fe43Sopenharmony_ci/*
21bd4fe43Sopenharmony_ci * @file hi_ver.h
31bd4fe43Sopenharmony_ci *
41bd4fe43Sopenharmony_ci * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED.
51bd4fe43Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License");
61bd4fe43Sopenharmony_ci * you may not use this file except in compliance with the License.
71bd4fe43Sopenharmony_ci * You may obtain a copy of the License at
81bd4fe43Sopenharmony_ci *
91bd4fe43Sopenharmony_ci *     http://www.apache.org/licenses/LICENSE-2.0
101bd4fe43Sopenharmony_ci *
111bd4fe43Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software
121bd4fe43Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS,
131bd4fe43Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
141bd4fe43Sopenharmony_ci * See the License for the specific language governing permissions and
151bd4fe43Sopenharmony_ci * limitations under the License.
161bd4fe43Sopenharmony_ci */
171bd4fe43Sopenharmony_ci
181bd4fe43Sopenharmony_ci/** @defgroup iot_ver Soft ver
191bd4fe43Sopenharmony_ci * @ingroup system
201bd4fe43Sopenharmony_ci */
211bd4fe43Sopenharmony_ci
221bd4fe43Sopenharmony_ci#ifndef __HI_VER_H__
231bd4fe43Sopenharmony_ci#define __HI_VER_H__
241bd4fe43Sopenharmony_ci#include <hi_types.h>
251bd4fe43Sopenharmony_ci#ifdef __cplusplus
261bd4fe43Sopenharmony_ciextern "C" {
271bd4fe43Sopenharmony_ci#endif
281bd4fe43Sopenharmony_ci
291bd4fe43Sopenharmony_ci/**
301bd4fe43Sopenharmony_ci* @ingroup  iot_ver
311bd4fe43Sopenharmony_ci* @brief  Obtains SDK version information. CNcomment:获取SDK版本信息CNend
321bd4fe43Sopenharmony_ci*
331bd4fe43Sopenharmony_ci* @par 描述:
341bd4fe43Sopenharmony_ci*         Obtains SDK version information. CNcomment:获取SDK版本信息CNend
351bd4fe43Sopenharmony_ci* @attention None
361bd4fe43Sopenharmony_ci* @retval #hi_char*     SDK version information string. CNcomment:SDK版本信息字符串CNend
371bd4fe43Sopenharmony_ci*
381bd4fe43Sopenharmony_ci* @par Dependency:
391bd4fe43Sopenharmony_ci*      @li hi_ver.h: This file describes version information APIs.CNcomment:文件用于描述系统相关接口.CNend
401bd4fe43Sopenharmony_ci* @see  None
411bd4fe43Sopenharmony_ci*/
421bd4fe43Sopenharmony_ciconst hi_char *hi_get_sdk_version(hi_void);
431bd4fe43Sopenharmony_ci
441bd4fe43Sopenharmony_ci/**
451bd4fe43Sopenharmony_ci* @ingroup  iot_ver
461bd4fe43Sopenharmony_ci* @brief  Obtains boot version in secure boot mode. CNcomment:安全启动模式下,获取BOOT版本号CNend
471bd4fe43Sopenharmony_ci*
481bd4fe43Sopenharmony_ci* @par 描述:
491bd4fe43Sopenharmony_ci*         Obtains boot version in secure boot mode. CNcomment:安全启动模式下,获取BOOT版本号CNend
501bd4fe43Sopenharmony_ci* @attention Ver always be 0 in non-secure boot mode. CNcomment: 非安全启动模式下,该版本号始终为0。CNend
511bd4fe43Sopenharmony_ci* @retval #hi_u8     boot ver num, value from 0-16, Return 0xFF means get boot ver fail.
521bd4fe43Sopenharmony_ciCNcomment:boot版本号,有效值为0-16,返回0xFF表示获取BOOT版本号失败CNend
531bd4fe43Sopenharmony_ci* @par Dependency:
541bd4fe43Sopenharmony_ci*      @li hi_ver.h: This file describes version information APIs.CNcomment:文件用于描述系统相关接口.CNend
551bd4fe43Sopenharmony_ci* @see  None
561bd4fe43Sopenharmony_ci*/
571bd4fe43Sopenharmony_cihi_u8 hi_get_boot_ver(hi_void);
581bd4fe43Sopenharmony_ci
591bd4fe43Sopenharmony_ci/**
601bd4fe43Sopenharmony_ci* @ingroup  iot_ver
611bd4fe43Sopenharmony_ci* @brief  Obtains kernel version in secure boot mode. CNcomment:安全启动模式下,获取kernel版本号CNend
621bd4fe43Sopenharmony_ci*
631bd4fe43Sopenharmony_ci* @par 描述:
641bd4fe43Sopenharmony_ci*         Obtains kernel version in secure boot mode. CNcomment:安全启动模式下,获取kernel版本号CNend
651bd4fe43Sopenharmony_ci* @attention Ver always be 0 in non-secure boot mode. CNcomment:非安全启动模式下,该版本号始终为0。CNend
661bd4fe43Sopenharmony_ci* @retval #hi_u8     kernel ver num, value from 0-48, Return 0xFF means get kernel ver fail.
671bd4fe43Sopenharmony_ciCNcomment:kernel版本号,有效值为0-48,返回0xFF表示获取kernel版本号失败CNend
681bd4fe43Sopenharmony_ci*
691bd4fe43Sopenharmony_ci* @par Dependency:
701bd4fe43Sopenharmony_ci*      @li hi_ver.h: This file describes version information APIs.CNcomment:文件用于描述系统相关接口.CNend
711bd4fe43Sopenharmony_ci* @see  None
721bd4fe43Sopenharmony_ci*/
731bd4fe43Sopenharmony_cihi_u8 hi_get_kernel_ver(hi_void);
741bd4fe43Sopenharmony_ci
751bd4fe43Sopenharmony_ci#ifdef __cplusplus
761bd4fe43Sopenharmony_ci}
771bd4fe43Sopenharmony_ci#endif
781bd4fe43Sopenharmony_ci#endif
79