Signed-off-by: hellohyh001 <huiyuehong@huawei.com>
Change-Id: I2bc1950f08460915ad37db2880af7fc1fd39176d
This commit is contained in:
hellohyh001 2023-11-27 13:23:06 +00:00
parent 738fdb55d8
commit 34f2a3383e
2 changed files with 26 additions and 5 deletions

View File

@ -14,7 +14,7 @@
import("//build/ohos.gni")
import("//build/ohos/ndk/ndk.gni")
ohos_ndk_headers("sensor_native") {
ohos_ndk_headers("sensor_ndk_header") {
dest_dir = "$ndk_headers_out_dir/sensors/sensor"
sources = [
"./native_sensor.h",
@ -22,7 +22,7 @@ ohos_ndk_headers("sensor_native") {
]
}
ohos_ndk_library("libsensor_native") {
ohos_ndk_library("libsensor_ndk") {
ndk_description_file = "./libsensor.ndk.json"
output_name = "libsensor_native"
output_extension = "z.so"

View File

@ -327,7 +327,6 @@ int32_t OH_Sensor_GetEventAccuracy(Sensor_SensorEvent* sensorEvent, Sensor_Senso
*/
int32_t OH_Sensor_GetSensorData(Sensor_SensorEvent* sensorEvent, float **data, size_t *length);
struct Sensor_SensorSubscribeId;
/**
* @brief Id
* @syscap SystemCapability.Sensors.Sensor
@ -335,6 +334,14 @@ struct Sensor_SensorSubscribeId;
*/
typedef struct Sensor_SensorSubscribeId Sensor_SensorSubscribeId;
/**
* @brief Id实例
*
* @return {@link Sensor_SensorSubscribeId} NULL.
* @since 11
*/
Sensor_SensorSubscribeId *OH_Sensor_CreateSubscribeId();
/**
* @brief
*
@ -355,7 +362,6 @@ int32_t OH_Sensor_GetSubscribeSensorType(Sensor_SensorSubscribeId* subscribeId,
*/
int32_t OH_Sensor_SetSubscribeSensorType(Sensor_SensorSubscribeId* subscribeId, const Sensor_SensorType sensorType);
struct Sensor_SubscribeAttribute;
/**
* @brief
* @syscap SystemCapability.Sensors.Sensor
@ -363,6 +369,14 @@ struct Sensor_SubscribeAttribute;
*/
typedef struct Sensor_SubscribeAttribute Sensor_SubscribeAttribute;
/**
* @brief
*
* @return {@link Sensor_SubscribeAttribute} NULL.
* @since 11
*/
Sensor_SubscribeAttribute *OH_Sensor_CreateAttribute();
/**
* @brief
*
@ -390,7 +404,6 @@ int32_t OH_Sensor_GetSamplingInterval(Sensor_SubscribeAttribute* attribute, int6
*/
typedef void (*Sensor_RecordSensorCallback)(Sensor_SensorEvent *event);
struct Sensor_SubscribeUser;
/**
* @brief
* @syscap SystemCapability.Sensors.Sensor
@ -398,6 +411,14 @@ struct Sensor_SubscribeUser;
*/
typedef struct Sensor_SubscribeUser Sensor_SubscribeUser;
/**
* @brief
*
* @return {@link Sensor_SubscribeUser} NULL.
* @since 11
*/
Sensor_SubscribeUser *OH_Sensor_CreateUser();
/**
* @brief
*