update drivers

This commit is contained in:
NuoDaJia02
2025-11-21 14:14:24 +08:00
parent 080af2f7fa
commit fac220ccf4
3480 changed files with 833545 additions and 25 deletions

View File

@@ -72,7 +72,8 @@
"typeindex": "cpp",
"typeinfo": "cpp",
"valarray": "cpp",
"variant": "cpp"
"variant": "cpp",
"filesystem": "cpp"
},
"C_Cpp_Runner.cCompilerPath": "gcc",
"C_Cpp_Runner.cppCompilerPath": "g++",

File diff suppressed because one or more lines are too long

123
aikit_tts/CMakeLists.txt Normal file
View File

@@ -0,0 +1,123 @@
cmake_minimum_required(VERSION 3.8)
project(aikit_tts)
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
add_compile_options(-Wall -Wextra -Wpedantic)
endif()
# 查找依赖
find_package(ament_cmake REQUIRED)
find_package(rclcpp REQUIRED)
find_package(std_msgs REQUIRED)
# 科大讯飞SDK路径配置 - 关键修改
set(XUNFEI_SDK_LIB_DIRS
${CMAKE_CURRENT_SOURCE_DIR}/libs
)
# -------------------------- 新增:资源路径配置 --------------------------
# 1. 定义资源源路径相对当前CMakeLists.txt的路径即resources/tts
set(TTS_RESOURCE_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR}/resources/tts)
# 2. 定义资源安装路径ROS 2标准路径share/包名/tts
# 安装后实际路径:/opt/ros/humble/share/aikit_tts/tts/
# 显式指定资源安装路径避免CMAKE_INSTALL_DATADIR解析异常
set(TTS_RESOURCE_INSTALL_DIR share/${PROJECT_NAME}/tts)
# -----------------------------------------------------------------------
# 添加头文件路径
include_directories(
include
${CMAKE_CURRENT_SOURCE_DIR}/include # 项目自身头文件
)
# 添加库文件路径
link_directories(
${XUNFEI_SDK_LIB_DIRS}
)
# 打印库路径用于调试
foreach(LIB_DIR ${XUNFEI_SDK_LIB_DIRS})
if(EXISTS "${LIB_DIR}/ebd1bade4_v1025_aee.so")
message(STATUS "找到ebd1bade4_v1025_aee.so: ${LIB_DIR}/ebd1bade4_v1025_aee.so")
endif()
if(EXISTS "${LIB_DIR}/libaikit.so")
message(STATUS "找到libaikit.so: ${LIB_DIR}/libaikit.so")
endif()
endforeach()
# 编译节点
add_executable(aikit_tts_node
src/aikit_tts_node.cpp
)
# 依赖项链接
ament_target_dependencies(aikit_tts_node
rclcpp
std_msgs
)
# -------------------------- 新增:传递资源路径给程序 --------------------------
# 通过宏定义TTS_RESOURCE_PATH把安装路径传给cpp代码末尾加/方便拼接文件名)
target_compile_definitions(aikit_tts_node
PRIVATE
TTS_RESOURCE_PATH="${TTS_RESOURCE_INSTALL_DIR}/"
)
# -----------------------------------------------------------------------
# 链接库
target_link_libraries(aikit_tts_node
-L${XUNFEI_SDK_LIB_DIRS} # 显式指定库路径
aikit # 科大讯飞主库
dl pthread m rt asound
)
# 安装可执行文件
install(TARGETS
aikit_tts_node
DESTINATION lib/${PROJECT_NAME}
)
# 安装SDK库文件到系统能找到的地方
install(DIRECTORY ${XUNFEI_SDK_LIB_DIRS}/
DESTINATION lib
FILES_MATCHING PATTERN "*.so*"
)
# -------------------------- 新增:安装资源文件 --------------------------
# 把resources/tts下的.dat和.irf文件安装到前面定义的TTS_RESOURCE_INSTALL_DIR
# 安装资源文件(修改后)
install(
DIRECTORY ${TTS_RESOURCE_SRC_DIR}/
# 拼接安装根目录,最终路径是 install/share/aikit_tts/tts/
DESTINATION ${CMAKE_INSTALL_PREFIX}/${TTS_RESOURCE_INSTALL_DIR}
FILES_MATCHING
PATTERN "*.dat"
PATTERN "*.irf"
)
# -----------------------------------------------------------------------
# 安装头文件
install(DIRECTORY include/
DESTINATION include
)
# 安装config和launch目录原有配置
if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/config)
install(DIRECTORY config/
DESTINATION share/${PROJECT_NAME}/config
)
endif()
if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/launch)
install(DIRECTORY launch/
DESTINATION share/${PROJECT_NAME}/launch
)
endif()
ament_export_include_directories(include)
ament_export_dependencies(rclcpp std_msgs)
ament_package()

View File

Binary file not shown.

View File

@@ -0,0 +1,337 @@
//
// Created by xkzhang9 on 2020/10/16.
//
#ifndef AIKIT_BIZ_API_H
#define AIKIT_BIZ_API_H
#include "aikit_biz_type.h"
#include "aikit_biz_builder.h"
namespace AIKIT {
/**
* SDK初始化函数用以初始化整个SDK
* 初始化相关配置参数通过AIKIT_Congigurator配置
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_Init();
/**[deprecated]
* SDK初始化函数用以初始化整个SDK
* @param param SDK配置参数
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_Init(AIKIT_InitParam* param);
/**
* SDK逆初始化函数用以释放SDK所占资源
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_UnInit();
/**
* 注册回调函数用以返回执行结果
* @param onOutput 能力实际输出回调
* @param onEvent 能力执行事件回调
* @param onError 能力执行错误回调
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_RegisterCallback(AIKIT_Callbacks cbs);
/**
* 注册回调函数用以返回执行结果
* @param ability [in] 能力唯一标识
* @param onOutput 能力实际输出回调
* @param onEvent 能力执行事件回调
* @param onError 能力执行错误回调
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_RegisterAbilityCallback(const char* ability, AIKIT_Callbacks cbs);
/**
* 初始化能力引擎
* @param ability [in] 能力唯一标识
* @param param [in] 初始化参数
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_EngineInit(const char* ability, AIKIT_BizParam* param);
/**
* 能力引擎逆初始化,释放能力及对应引擎占用所有资源
* @param ability [in] 能力唯一标识
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_EngineUnInit(const char* ability);
/**
* 个性化数据预处理
* @param ability [in] 能力唯一标识
* @param srcData [in] 原始数据输入
* @param data [out] 结果数据输出
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_PreProcess(const char* ability, AIKIT_CustomData* srcData, AIKIT_CustomData** data);
/**
* 离线个性化数据加载
* @param ability 能力唯一标识
* @param data 个性化数据
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_LoadData(const char* ability, AIKIT_CustomData* data);
/**
* 在线个性化数据上传
* @param ability 能力唯一标识
* @param params 个性化参数
* @param data 个性化数据
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_LoadDataAsync(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* data, void* usrContext, AIKIT_HANDLE** outHandle);
/**
* 个性化数据查询
* @param ability 能力唯一标识
* @param data 个性化数据
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_QueryData(const char* ability, AIKIT_CustomData* data);
/**
* @brief 可见即可说AIUI定制接口
* @param ability 能力唯一标识
* @param params 个性化参数
* @param data 个性化数据
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_LoadDataSpeakableAsync(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* data, void* usrContext, AIKIT_HANDLE** outHandle);
/**
* 个性化数据卸载
* @param ability 能力唯一标识
* @param key 个性化数据唯一标识
* @param index 个性化数据索引
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_UnLoadData(const char* ability, const char* key, int index);
/**
* 指定要使用的个性化数据集合未调用则默认使用所有AIKIT_LoadData加载的数据
* 可调用多次以使用不同key集合
* @param abilityId 能力唯一标识
* @param key 个性化数据唯一标识数组
* @param index 个性化数据索引数组
* @param count 个性化数据索引数组成员个数
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SpecifyDataSet(const char* ability, const char* key, int index[], int count);
/**
* 启动one-shot模式能力同步模式调用
* @param ability 能力唯一标识
* @param param 能力参数
* @param inputData 能力数据输入
* @param outputData 能力数据输出
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_OneShot(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* inputData, AIKIT_OutputData** outputData);
/**
* 启动one-shot模式能力异步模式调用
* @param ability 能力唯一标识d
* @param param 能力参数
* @param data 能力数据输入
* @param usrContext 上下文指针
* @param outHandle 生成的引擎会话句柄
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_OneShotAsync(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* data, void* usrContext, AIKIT_HANDLE** outHandle);
/**
* 启动会话模式能力调用实例,若引擎未初始化,则内部首先完成引擎初始化
* @param ability 能力唯一标识
* @param len ability长度
* @param param 初始化参数
* @param usrContext上下文指针
* @param outHandle 生成的引擎会话句柄
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_Start(const char* ability, AIKIT_BizParam* param, void* usrContext, AIKIT_HANDLE** outHandle);
/**
* 会话模式输入数据
* @param handle 会话实例句柄
* @param input 输入数据
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_Write(AIKIT_HANDLE* handle, AIKIT_InputData* input);
/**
* 会话模式同步读取数据
* @param handle 会话实例句柄
* @param output 输入数据
* @return 结果错误码0=成功
* @note output内存由SDK自行维护,无需主动释放
*/
AIKITAPI int32_t AIKIT_Read(AIKIT_HANDLE* handle, AIKIT_OutputData** output);
/**
* 结束会话实例
* @param handle 会话实例句柄
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_End(AIKIT_HANDLE* handle);
/**
* 释放能力占用资源,注意不会释放引擎实例
* 若要释放能力及能力所有资源需调用AIKIT_EngineUnInit()
* @param ability 能力唯一标识
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_FreeAbility(const char* ability);
/**
* 设置日志级别
* @param level 日志级别
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogLevel(int32_t level);
/**
* 设置日志输出模式
* @param mode 日志输出模式
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogMode(int32_t mode);
/**
* 输出模式为文件时,设置日志文件名称
* @param path 日志名称
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogPath(const char* path);
/**
* 获取设备ID
* @param deviceID 设备指纹输出字符串
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_GetDeviceID(const char** deviceID);
/**
* 设置授权更新间隔单位为秒默认为300秒
* AIKIT_Init前设置
* @param interval 间隔秒数
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_SetAuthCheckInterval(uint32_t interval);
/**
* 强制更新授权
* 注意注意需在AIKIT_Init调用成功后方可调用
* @param timeout 超时时间 单位为秒
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_UpdateAuth(uint32_t timeout);
/**
* 获取能力授权剩余秒数
* 能力输入参数为空时,默认返回最接近授权过期的能力剩余秒数
* 注意注意需在AIKIT_Init调用成功后方可调用
* @param leftTime 返回的能力授权剩余秒数0 表示永久授权, 负值表示已过期的秒数
* @param ability 能力id标识
* @return 返回调用结果0 = 成功, 其他值表示调用失败
*/
AIKITAPI int AIKIT_GetAuthLeftTime(int64_t& leftTime,int64_t& authEndTime, const char* ability = nullptr);
/**
* 获取SDK版本号
* @return SDK版本号
*/
AIKITAPI const char* AIKIT_GetVersion();
/**
* @brief 获取能力对应的引擎版本
*
* @param ability 能力唯一标识
* @return const* 引擎版本号
*/
AIKITAPI const char* AIKIT_GetEngineVersion(const char* ability);
/**
* 本地日志是否开启
* @param open
* @return
*/
AIKITAPI int32_t AIKIT_SetILogOpen(bool open);
/**
* 本地日志最大存储个数【1300】
* @param count
* @return
*/
AIKITAPI int32_t AIKIT_SetILogMaxCount(uint32_t count);
/**
* 设置单日志文件大小((010M】
* @param bytes
* @return
*/
AIKITAPI int32_t AIKIT_SetILogMaxSize(long long bytes);
/**
* 设置SDK相关配置
* @param key 参数名字
* @param value 参数值
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_SetConfig(const char* key, const void* value);
/**
* 设置SDK内存模式
* @param ability 能力id
* @param mode 模式,取值参见 AIKIT_MEMORY_MODE
* @return AIKITAPI
*/
AIKITAPI int32_t AIKIT_SetMemoryMode(const char* ability,int32_t mode);
/**自2.1.6版本开始已废弃接口,当前仅保留空实现接口声明
* 自2.1.6版本开始AIKIT_OneShot响应数据由SDK内部自己维护无需用户维护
* 同步接口响应数据缓存释放接口
* @param outputData 由同步接口AIKIT_OneShot获取的响应结果数据
*/
AIKITAPI int32_t AIKIT_Free(AIKIT_OutputData** outputData);
/**自2.1.6版本开始已废弃接口由AIKIT_FreeAbility替代
* 释放能力占用资源
* @param ability 能力唯一标识
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_GC(const char* ability);
/**
* 设置日志级别,模式,以及保存路径,旧版日志接口,不推荐使用
* @param level 日志级别
* @param mode 日志输出模式
* @param level 输出模式为文件时的文件名称
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogInfo(int32_t level, int32_t mode, const char* path);
/**
* 获取能力授权剩余秒数
* 能力输入参数为空时,默认返回最接近授权过期的能力剩余秒数
* 注意注意需在AEE_Init调用成功后方可调用
* @param leftTime 返回的能力授权剩余秒数0 表示永久授权, 负值表示已过期的秒数
* @param ability 能力id标识
* @return 返回调用结果0 = 成功, 其他值表示调用失败
*/
AIKITAPI int AIKIT_GetAuthLeftTime(int64_t& leftTime, const char* ability = nullptr);
} // namespace AIKIT
#endif //AIKIT_BIZ_API_H

View File

@@ -0,0 +1,437 @@
//
// Created by chaoxu8 on 2021/07/01.
//
#ifndef AIKIT_BIZ_API_C_H
#define AIKIT_BIZ_API_C_H
#ifndef __cplusplus
#include <stdbool.h>
#endif
#include "aikit_biz_type.h"
#include "../api_aee/aee_biz_api_c.h"
#ifndef AEE_BIZ_API_C_H
// 构造器类型
typedef enum BuilderType_ {
BUILDER_TYPE_PARAM, // 参数输入
BUILDER_TYPE_DATA // 数据输入
} BuilderType;
// 构造器输入数据类型
typedef enum BuilderDataType_ {
DATA_TYPE_TEXT, // 文本
DATA_TYPE_AUDIO, // 音频
DATA_TYPE_IMAGE, // 图片
DATA_TYPE_VIDEO // 视频
} BuilderDataType;
// 构造器输入数据结构体
typedef struct BuilderData_ {
int type; // 数据类型
const char* name; // 数据段名
void* data; // 数据段实体(当送入路径时,此处传入路径地址字符串指针即可;
// 当送入文件句柄时,此处传入文件句柄指针即可)
int len; // 数据段长度当送入路径或文件句柄时此处传0即可
int status; // 数据段状态参考AIKIT_DataStatus枚举
} BuilderData;
#endif
// 构造器上下文及句柄
typedef struct AIKITBuilderContext_ {
void* builderInst; // 构造器内部类句柄
BuilderType type; // 构造器类型
} AIKITBuilderContext, *AIKITBuilderHandle;
#ifdef __cplusplus
extern "C" {
#endif
/**
* @brief 初始化输入构造器
* @param type 构造器类型
* @return 构造器句柄失败返回nullptr
*/
AIKITAPI AIKITBuilderHandle AIKITBuilder_Create(BuilderType type);
typedef AIKITBuilderHandle(*AIKITBuilder_Create_Ptr)(BuilderType type);
/**
* @brief 添加整型参数
* @param handle 构造器句柄
* @param name 参数名称
* @param value 参数值
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddInt(AIKITBuilderHandle handle, const char *key, int value);
typedef int(*AIKITBuilder_AddInt_Ptr)(AIKITBuilderHandle handle, const char *key, int value);
/**
* @brief 添加字符串型参数
* @param handle 构造器句柄
* @param name 参数名称
* @param str 参数值
* @param len 字符串长度
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddString(AIKITBuilderHandle handle, const char *key, const char *value, int len);
typedef int(*AIKITBuilder_AddString_Ptr)(AIKITBuilderHandle handle, const char *key, const char *value, int len);
/**
* @brief 添加布尔型参数
* @param handle 构造器句柄
* @param name 参数名称
* @param value 参数值
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddBool(AIKITBuilderHandle handle, const char *key, bool value);
typedef int(*AIKITBuilder_AddBool_Ptr)(AIKITBuilderHandle handle, const char *key, bool value);
/**
* @brief 添加浮点型参数
* @param handle 构造器句柄
* @param name 参数名称
* @param value 参数值
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddDouble(AIKITBuilderHandle handle, const char *key, double value);
typedef int(*AIKITBuilder_AddDouble_Ptr)(AIKITBuilderHandle handle, const char *key, double value);
/**
* @brief 添加输入数据
* @param handle 构造器句柄
* @param data 数据结构体实例
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddBuf(AIKITBuilderHandle handle, BuilderData *data);
typedef int(*AIKITBuilder_AddBuf_Ptr)(AIKITBuilderHandle handle, BuilderData *data);
/**
* @brief 添加输入数据(以路径方式)
* @param handle 构造器句柄
* @param data 数据结构体实例
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddPath(AIKITBuilderHandle handle, BuilderData *data);
typedef int(*AIKITBuilder_AddPath_Ptr)(AIKITBuilderHandle handle, BuilderData *data);
/**
* @brief 添加输入数据(以文件对象方式)
* @param handle 构造器句柄
* @param data 数据结构体实例
* @return 结果错误码0=成功
*/
AIKITAPI int AIKITBuilder_AddFile(AIKITBuilderHandle handle, BuilderData *data);
typedef int(*AIKITBuilder_AddFile_Ptr)(AIKITBuilderHandle handle, BuilderData *data);
/**
* @brief 构建输入参数
* @param handle 构造器句柄
* @return 参数结构化指针失败返回nullptr
*/
AIKITAPI AIKIT_BizParam* AIKITBuilder_BuildParam(AIKITBuilderHandle handle);
typedef AIKIT_BizParam*(*AIKITBuilder_BuildParam_Ptr)(AIKITBuilderHandle handle);
/**
* @brief 构建输入数据
* @param handle 构造器句柄
* @return 数据结构化指针失败返回nullptr
*/
AIKITAPI AIKIT_InputData* AIKITBuilder_BuildData(AIKITBuilderHandle handle);
typedef AIKIT_InputData*(*AIKITBuilder_BuildData_Ptr)(AIKITBuilderHandle handle);
/**
* @brief 清空输入构造器
* @param handle 构造器句柄
* @return 无
*/
AIKITAPI void AIKITBuilder_Clear(AIKITBuilderHandle handle);
typedef void(*AIKITBuilder_Clear_Ptr)(AIKITBuilderHandle handle);
/**
* @brief 销毁输入构造器
* @param handle 构造器句柄
* @return 无
*/
AIKITAPI void AIKITBuilder_Destroy(AIKITBuilderHandle handle);
typedef void(*AIKITBuilder_Destroy_Ptr)(AIKITBuilderHandle handle);
/**
* SDK初始化函数用以初始化整个SDK
* @param param SDK配置参数
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_Init(AIKIT_InitParam* param);
typedef int32_t(*AIKIT_Init_Ptr)(AIKIT_InitParam* param);
/**
* SDK逆初始化函数用以释放SDK所占资源
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_UnInit();
typedef int32_t(*AIKIT_UnInit_Ptr)();
/**
* 注册回调函数用以返回执行结果
* @param onOutput 能力实际输出回调
* @param onEvent 能力执行事件回调
* @param onError 能力执行错误回调
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_RegisterCallback(AIKIT_Callbacks cbs);
typedef int32_t(*AIKIT_RegisterCallback_Ptr)(AIKIT_Callbacks cbs);
/**
* 注册回调函数用以返回执行结果
* @param ability [in] 能力唯一标识
* @param onOutput 能力实际输出回调
* @param onEvent 能力执行事件回调
* @param onError 能力执行错误回调
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_RegisterAbilityCallback(const char* ability, AIKIT_Callbacks cbs);
typedef int32_t(*AIKIT_RegisterAbilityCallback_Ptr)(const char* ability, AIKIT_Callbacks cbs);
/**
* 初始化能力引擎
* @param ability [in] 能力唯一标识
* @param param [in] 初始化参数
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_EngineInit(const char* ability, AIKIT_BizParam* param);
typedef int32_t(*AIKIT_EngineInit_Ptr)(const char* ability, AIKIT_BizParam* param);
/**
* 能力引擎逆初始化
* @param ability [in] 能力唯一标识
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_EngineUnInit(const char* ability);
typedef int32_t(*AIKIT_EngineUnInit_Ptr)(const char* ability);
/**
* 个性化数据预处理
* @param ability [in] 能力唯一标识
* @param srcData [in] 原始数据输入
* @param data [out] 结果数据输出
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_PreProcess(const char* ability, AIKIT_CustomData* srcData, AIKIT_CustomData** data);
typedef int32_t(*AIKIT_PreProcess_Ptr)(const char* ability, AIKIT_CustomData* srcData, AIKIT_CustomData** data);
/**
* 个性化数据加载
* @param ability 能力唯一标识
* @param data 个性化数据
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_LoadData(const char* ability, AIKIT_CustomData* data);
typedef int32_t(*AIKIT_LoadData_Ptr)(const char* ability, AIKIT_CustomData* data);
/**
* 个性化数据加载
* @param ability 能力唯一标识
* @param key 个性化数据唯一标识
* @param index 个性化数据索引
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_UnLoadData(const char* ability, const char* key, int index);
typedef int32_t(*AIKIT_UnLoadData_Ptr)(const char* ability, const char* key, int index);
/**
* 指定要使用的个性化数据集合未调用则默认使用所有AIKIT_LoadData加载的数据
* 可调用多次以使用不同key集合
* @param abilityId 能力唯一标识
* @param key 个性化数据唯一标识数组
* @param index 个性化数据索引数组
* @param count 个性化数据索引数组成员个数
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SpecifyDataSet(const char* ability, const char* key, int index[], int count);
typedef int32_t(*AIKIT_SpecifyDataSet_Ptr)(const char* ability, const char* key, int index[], int count);
/**
* 启动one-shot模式能力同步模式调用
* @param ability 能力唯一标识
* @param param 能力参数
* @param inputData 能力数据输入
* @param outputData 能力数据输出
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_OneShot(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* inputData, AIKIT_OutputData** outputData);
typedef int32_t(*AIKIT_OneShot_Ptr)(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* inputData, AIKIT_OutputData** outputData);
/**
* 启动one-shot模式能力异步模式调用
* @param ability 能力唯一标识d
* @param param 能力参数
* @param data 能力数据输入
* @param usrContext 上下文指针
* @param outHandle 生成的引擎会话句柄
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_OneShotAsync(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* data, void* usrContext, AIKIT_HANDLE** outHandle);
typedef int32_t(*AIKIT_OneShotAsync_Ptr)(const char* ability, AIKIT_BizParam* params, AIKIT_InputData* data, void* usrContext, AIKIT_HANDLE** outHandle);
/**
* 启动会话模式能力调用实例,若引擎未初始化,则内部首先完成引擎初始化
* @param ability 能力唯一标识
* @param len ability长度
* @param param 初始化参数
* @param usrContext上下文指针
* @param outHandle 生成的引擎会话句柄
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_Start(const char* ability, AIKIT_BizParam* param, void* usrContext, AIKIT_HANDLE** outHandle);
typedef int32_t(*AIKIT_Start_Ptr)(const char* ability, AIKIT_BizParam* param, void* usrContext, AIKIT_HANDLE** outHandle);
/**
* 会话模式输入数据
* @param handle 会话实例句柄
* @param input 输入数据
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_Write(AIKIT_HANDLE* handle, AIKIT_InputData* input);
typedef int32_t(*AIKIT_Write_Ptr)(AIKIT_HANDLE* handle, AIKIT_InputData* input);
/**
* 会话模式同步读取数据
* @param handle 会话实例句柄
* @param output 输入数据
* @return 结果错误码0=成功
* @note output内存由SDK自行维护,无需主动释放
*/
AIKITAPI int32_t AIKIT_Read(AIKIT_HANDLE* handle, AIKIT_OutputData** output);
typedef int32_t(*AIKIT_Read_Ptr)(AIKIT_HANDLE* handle, AIKIT_OutputData** output);
/**
* 结束会话实例
* @param handle 会话实例句柄
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_End(AIKIT_HANDLE* handle);
typedef int32_t(*AIKIT_End_Ptr)(AIKIT_HANDLE* handle);
/**
* 释放能力占用资源
* @param ability 能力唯一标识
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_FreeAbility(const char* ability);
typedef int32_t(*AIKIT_FreeAbility_Ptr)(const char* ability);
/**
* 设置日志级别
* @param level 日志级别
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogLevel(int32_t level);
typedef int32_t(*AIKIT_SetLogLevel_Ptr)(int32_t level);
/**
* 设置日志输出模式
* @param mode 日志输出模式
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogMode(int32_t mode);
typedef int32_t(*AIKIT_SetLogMode_Ptr)(int32_t mode);
/**
* 输出模式为文件时,设置日志文件名称
* @param path 日志名称
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogPath(const char* path);
typedef int32_t(*AIKIT_SetLogPath_Ptr)(const char* path);
/**
* 获取设备ID
* @param deviceID 设备指纹输出字符串
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_GetDeviceID(const char** deviceID);
typedef int32_t(*AIKIT_GetDeviceID_Ptr)(const char** deviceID);
/**
* 设置授权更新间隔单位为秒默认为300秒
* AIKIT_Init前设置
* @param interval 间隔秒数
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_SetAuthCheckInterval(uint32_t interval);
typedef int32_t(*AIKIT_SetAuthCheckInterval_Ptr)(uint32_t interval);
/**
* 获取SDK版本号
* @return SDK版本号
*/
AIKITAPI const char* AIKIT_GetVersion();
typedef const char*(*AIKIT_GetVersion_Ptr)();
/**
* @brief 获取能力对应的引擎版本
*
* @param ability 能力唯一标识
* @return const* 引擎版本号
*/
AIKITAPI const char* AIKIT_GetEngineVersion(const char* ability);
typedef const char*(*AIKIT_GetEngineVersion_Ptr)(const char* ability);
/**
* 本地日志是否开启
* @param open
* @return
*/
AIKITAPI int32_t AIKIT_SetILogOpen(bool open);
typedef int32_t(*AIKIT_SetILogOpenPtr)(bool open);
/**
* 本地日志最大存储个数【1300】
* @param count
* @return
*/
AIKITAPI int32_t AIKIT_SetILogMaxCount(uint32_t count);
typedef int32_t(*AIKIT_SetILogMaxCountPtr)(uint32_t count);
/**
* 设置单日志文件大小((010M】
* @param bytes
* @return
*/
AIKITAPI int32_t AIKIT_SetILogMaxSize(long long bytes);
typedef int32_t(*AIKIT_SetILogMaxSizePtr)(long long bytes);
/**
* 设置SDK相关配置
* @param key 参数名字
* @param value 参数值
* @return 结果错误码0=成功
*/
AIKITAPI int32_t AIKIT_SetConfig(const char* key, const void* value);
typedef int32_t(*AIKIT_SetConfigPtr)(const char* key, const void* value);
/**
* 设置SDK内存模式
* @param ability 能力id
* @param mode 模式,取值参见 AIKIT_MEMORY_MODE
* @return AIKITAPI
*/
AIKITAPI int32_t AIKIT_SetMemoryMode(const char* ability,int32_t mode);
typedef int32_t(*AIKIT_SetMemoryModePtr)(const char* ability,int32_t mode);
/**
* 设置日志级别,模式,以及保存路径,旧版日志接口,不推荐使用
* @param level 日志级别
* @param mode 日志输出模式
* @param level 输出模式为文件时的文件名称
* @return 错误码 0=成功,其他表示失败
*/
AIKITAPI int32_t AIKIT_SetLogInfo(int32_t level, int32_t mode, const char* path);
typedef int32_t(*AIKIT_SetLogInfo_Ptr)(int32_t level, int32_t mode, const char* path);
#ifdef __cplusplus
}
#endif
#endif // AIKIT_BIZ_API_C_H

View File

@@ -0,0 +1,299 @@
#ifndef AIKIT_BIZ_BUILDER_H
#define AIKIT_BIZ_BUILDER_H
#include "aikit_biz_type.h"
#include "aikit_biz_obsolete_builder.h"
namespace AIKIT {
/**
* 参数构造类
*/
class AIKITAPI AIKIT_ParamBuilder {
public:
static AIKIT_ParamBuilder* create();
static void destroy(AIKIT_ParamBuilder* builder);
virtual ~AIKIT_ParamBuilder();
//当需要为能力会话设置header字段时需调用此接口
//后续调用param设置的kv对将全部追加到header字段
virtual AIKIT_ParamBuilder* header() = 0;
virtual AIKIT_ParamBuilder* header(const char* key, const char* data, uint32_t dataLen) = 0;
virtual AIKIT_ParamBuilder* header(const char* key, int value) = 0;
virtual AIKIT_ParamBuilder* header(const char* key, double value) = 0;
virtual AIKIT_ParamBuilder* header(const char* key, bool value) = 0;
//当需要设置能力会话功能参数时,需调用此接口
//后续调用param设置的kv对将全部追加到能力功能参数字段
virtual AIKIT_ParamBuilder* service(const char* serviceID) = 0;
virtual AIKIT_ParamBuilder* service(const char* serviceID, AIKIT_ParamBuilder* value) = 0;
virtual AIKIT_ParamBuilder* param(const char* key, const char* data, uint32_t dataLen) = 0;
virtual AIKIT_ParamBuilder* param(const char* key, int value) = 0;
virtual AIKIT_ParamBuilder* param(const char* key, double value) = 0;
virtual AIKIT_ParamBuilder* param(const char* key, bool value) = 0;
//输出控制参数对设置
virtual AIKIT_ParamBuilder* param(const char* key, AIKIT_ParamBuilder* value) = 0;
virtual AIKIT_BizParam* build() = 0;
virtual void clear() = 0;
};
/**
* @brief 数据构造类基类
*
*/
class AIKITAPI AiData {
public:
template <class T, class O>
class AIKITAPI AiDataHolder {
public:
virtual T* status(int status) = 0;
virtual T* begin() = 0;
virtual T* cont() = 0;
virtual T* end() = 0;
virtual T* once() = 0;
virtual T* data(const char* value,int dataLen) = 0;
virtual T* path(const char* path) = 0;
virtual T* file(const FILE* file) = 0;
virtual O* valid() = 0;
};
virtual ~AiData() = 0;
};
/**
* 文本数据构造类
* encoding 文本编码格式设置 默认值:"utf8" 常见取值:"utf8" "gbk" "gb2312"
* compress 文本压缩格式设置 默认值:"raw" 常见取职:"raw" "gzip"
* format 文本内容格式设置 默认值:"plain" 常见取值:"plain" "json" "xml"
*/
class AIKITAPI AiText : public AiData {
public:
class AiTextHolder : public AiDataHolder<AiTextHolder,AiText> {
public:
virtual AiTextHolder* encoding(const char* encoding) = 0;
virtual AiTextHolder* compress(const char* compress) = 0;
virtual AiTextHolder* format(const char* format) = 0;
};
static AiTextHolder* get(const char* key);
virtual ~AiText() = 0;
public:
static constexpr char* const ENCODING_UTF8 = (char*)"utf8";
static constexpr char* const ENCODING_GBK = (char*)"gbk";
static constexpr char* const ENCODING_GB2312 = (char*)"gb2312";
static constexpr char* const ENCODING_DEF = ENCODING_UTF8;
static constexpr char* const COMPRESS_RAW = (char*)"raw";
static constexpr char* const COMPRESS_GZIP = (char*)"gzip";
static constexpr char* const COMPRESS_DEF = COMPRESS_RAW;
static constexpr char* const FORMAT_PLAIN = (char*)"plain";
static constexpr char* const FORMAT_JSON = (char*)"json";
static constexpr char* const FORMAT_XML = (char*)"xml";
static constexpr char* const FORMAT_DEF = FORMAT_PLAIN;
};
/**
* 音频数据构造类
* encoding 音频编码格式设置 默认值:"speex-wb" 常见取值:"lame" "speex" "speex-wb" "opus" "opus-wb" "mp3" "wav" "amr"
* sampleRate 音频采样率设置 默认值:16000 常见取值:16000 8000
* channels 音频声道数设置 默认值:1 常见取值:1 2
* bitDepth 音频数据位深设置 默认值:16 常见取值:[16,8]
*/
class AIKITAPI AiAudio : public AiData {
public :
class AiAudioHolder : public AiDataHolder<AiAudioHolder,AiAudio> {
public:
virtual AiAudioHolder* encoding(const char* encoding) = 0;
virtual AiAudioHolder* sampleRate(int sampleRate) = 0;
virtual AiAudioHolder* channels(int channels) = 0;
virtual AiAudioHolder* bitDepth(int bitDepth) = 0;
};
static AiAudioHolder* get(const char* key);
virtual ~AiAudio() = 0;
public:
static constexpr char* const ENCODING_PCM = (char*)"pcm";
static constexpr char* const ENCODING_RAW = (char*)"raw";
static constexpr char* const ENCODING_ICO = (char*)"ico";
static constexpr char* const ENCODING_SPEEX = (char*)"speex";
static constexpr char* const ENCODING_SPEEX_WB = (char*)"speex-wb";
static constexpr char* const ENCODING_LAME = (char*)"lame";
static constexpr char* const ENCODING_OPUS = (char*)"opus";
static constexpr char* const ENCODING_OPUS_WB = (char*)"opus-wb";
static constexpr char* const ENCODING_WAV = (char*)"wav";
static constexpr char* const ENCODING_AMR = (char*)"amr";
static constexpr char* const ENCODING_AMR_WB = (char*)"amr-wb";
static constexpr char* const ENCODING_MP3 = (char*)"mp3";
static constexpr char* const ENCODING_CDA = (char*)"cda";
static constexpr char* const ENCODING_WAVE = (char*)"wave";
static constexpr char* const ENCODING_AIFF = (char*)"aiff";
static constexpr char* const ENCODING_MPEG = (char*)"mpeg";
static constexpr char* const ENCODING_MID = (char*)"mid";
static constexpr char* const ENCODING_WMA = (char*)"wma";
static constexpr char* const ENCODING_RA = (char*)"ra";
static constexpr char* const ENCODING_RM = (char*)"rm";
static constexpr char* const ENCODING_RMX = (char*)"rmx";
static constexpr char* const ENCODING_VQF = (char*)"vqf";
static constexpr char* const ENCODING_OGG = (char*)"ogg";
static constexpr char* const ENCODING_DEF = ENCODING_SPEEX_WB;
static const int SAMPLE_RATE_8K = 8000;
static const int SAMPLE_RATE_16K = 16000;
static const int SAMPLE_RATE_DEF = SAMPLE_RATE_16K;
static const int CHANNELS_1 = 1;
static const int CHANNELS_2 = 2;
static const int CHANNELS_DEF = CHANNELS_1;
static const int BIT_DEPTH_8 = 8;
static const int BIT_DEPTH_16 = 16;
static const int BIT_DEPTH_DEF = BIT_DEPTH_16;
};
/**
* 图片数据构造类
* encoding 图片编码格式设置 默认值:"jpg" 常见取值:"raw" "rgb" "bgr" "yuv" "jpg" "jpeg" "png" "bmp"
* width 图片宽度设置 默认值:null 常见取值:根据具体图片文件各不相同
* height 图片高度设置 默认值:null 常见取值:根据具体图片文件各不相同
* dims 图片深度设置 默认值:null 常见取值:根据具体图片文件各不相同
*/
class AIKITAPI AiImage : public AiData {
public:
class AiImageHolder : public AiDataHolder<AiImageHolder,AiImage> {
public:
virtual AiImageHolder* encoding(const char* encoding) = 0;
virtual AiImageHolder* width(int width) = 0;
virtual AiImageHolder* height(int height) = 0;
virtual AiImageHolder* dims(int dims) = 0;
};
static AiImageHolder* get(const char* key);
virtual ~AiImage() = 0;
public:
static constexpr char* const ENCODING_RAW = (char*)"raw";
static constexpr char* const ENCODING_JPG = (char*)"jpg";
static constexpr char* const ENCODING_JPEG = (char*)"jpeg";
static constexpr char* const ENCODING_PNG = (char*)"png";
static constexpr char* const ENCODING_APNG = (char*)"apng";
static constexpr char* const ENCODING_BMP = (char*)"bmp";
static constexpr char* const ENCODING_WEBP = (char*)"webp";
static constexpr char* const ENCODING_TIFF = (char*)"tiff";
static constexpr char* const ENCODING_RGB565 = (char*)"rgb565";
static constexpr char* const ENCODING_RGB888 = (char*)"rgb888";
static constexpr char* const ENCODING_BGR565 = (char*)"bgr565";
static constexpr char* const ENCODING_BGR888 = (char*)"bgr888";
static constexpr char* const ENCODING_YUV12 = (char*)"yuv12";
static constexpr char* const ENCODING_YUV21 = (char*)"yuv21";
static constexpr char* const ENCODING_YUV420 = (char*)"yuv420";
static constexpr char* const ENCODING_YUV422 = (char*)"yuv422";
static constexpr char* const ENCODING_PSD = (char*)"psd";
static constexpr char* const ENCODING_PCD = (char*)"pcd";
static constexpr char* const ENCODING_DEF = ENCODING_JPG;
};
/**
* 视频数据构造类
* encoding 视频编码设置 默认值:"h264" 常见取值:"avi" "rmvb" "flv" "h26x" "mpeg"
* width 视频宽度设置 默认值:null 常见取值:根据具体视频文件各不相同
* height 视频高度设置 默认值:null 常见取值:根据具体视频文件各不相同
* frameRate 视频帧率设置 默认值:null 常见取值:根据具体视频文件各不相同
*/
class AIKITAPI AiVideo : public AiData {
public:
class AiVideoHolder : public AiDataHolder<AiVideoHolder,AiVideo> {
public:
virtual AiVideoHolder* encoding(const char* key) = 0;
virtual AiVideoHolder* width(int width) = 0;
virtual AiVideoHolder* height(int height) = 0;
virtual AiVideoHolder* frameRate(int frameRate) = 0;
};
static AiVideoHolder* get(const char* key);
virtual ~AiVideo() = 0;
public:
static constexpr char* const ENCODING_H264 = (char*)"h264";
static constexpr char* const ENCODING_H265 = (char*)"h265";
static constexpr char* const ENCODING_AVI = (char*)"avi";
static constexpr char* const ENCODING_NAVI = (char*)"navi";
static constexpr char* const ENCODING_MP4 = (char*)"mp4";
static constexpr char* const ENCODING_RM = (char*)"rm";
static constexpr char* const ENCODING_RMVB = (char*)"rmvb";
static constexpr char* const ENCODING_MKV = (char*)"mkv";
static constexpr char* const ENCODING_FLV = (char*)"flv";
static constexpr char* const ENCODING_F4V = (char*)"f4v";
static constexpr char* const ENCODING_MPG = (char*)"mpg";
static constexpr char* const ENCODING_MLV = (char*)"mlv";
static constexpr char* const ENCODING_MPE = (char*)"mpe";
static constexpr char* const ENCODING_MPEG = (char*)"mpeg";
static constexpr char* const ENCODING_DAT = (char*)"dat";
static constexpr char* const ENCODING_m2v = (char*)"m2v";
static constexpr char* const ENCODING_VOB = (char*)"vob";
static constexpr char* const ENCODING_ASF = (char*)"asf";
static constexpr char* const ENCODING_MOV = (char*)"mov";
static constexpr char* const ENCODING_WMV = (char*)"wmv";
static constexpr char* const ENCODING_3GP = (char*)"3gp";
static constexpr char* const ENCODING_DEF = ENCODING_H264;
};
/**
* 输入构造类
*/
class AIKITAPI AIKIT_DataBuilder : public AIKIT_DataBuilderObsolete {
public:
static AIKIT_DataBuilder* create();
static void destroy(AIKIT_DataBuilder* builder);
virtual ~AIKIT_DataBuilder();
virtual AIKIT_DataBuilder* payload(AiData* data) = 0;
virtual AIKIT_InputData* build() = 0;
virtual void clear() = 0;
};
/**
* 自定义数据构造器
*/
class AIKITAPI AIKIT_CustomBuilder {
public:
static AIKIT_CustomBuilder* create();
static void destroy(AIKIT_CustomBuilder* builder);
virtual ~AIKIT_CustomBuilder();
virtual AIKIT_CustomBuilder* text(const char* key, const char* data, uint32_t dataLen, int32_t index) = 0;
virtual AIKIT_CustomBuilder* textPath(const char* key, const char* path, int32_t index) = 0;
virtual AIKIT_CustomBuilder* textFile(const char* key, const FILE* file, int32_t index) = 0;
virtual AIKIT_CustomBuilder* audio(const char* key, const char* data, uint32_t dataLen, int32_t index) = 0;
virtual AIKIT_CustomBuilder* audioPath(const char* key, const char* path, int32_t index) = 0;
virtual AIKIT_CustomBuilder* audioFile(const char* key, const FILE* file, int32_t index) = 0;
virtual AIKIT_CustomBuilder* image(const char* key, const char* data, uint32_t dataLen, int32_t index) = 0;
virtual AIKIT_CustomBuilder* imagePath(const char* key, const char* path, int32_t index) = 0;
virtual AIKIT_CustomBuilder* imageFile(const char* key, const FILE* file, int32_t index) = 0;
virtual AIKIT_CustomBuilder* video(const char* key, const char* data, uint32_t dataLen, int32_t index) = 0;
virtual AIKIT_CustomBuilder* videoPath(const char* key, const char* path, int32_t index) = 0;
virtual AIKIT_CustomBuilder* videoFile(const char* key, const FILE* file, int32_t index) = 0;
virtual AIKIT_CustomData* build() = 0;
virtual void clear() = 0;
};
/**
* 参数和输入统一构造类
*/
class AIKITAPI AIKIT_Builder {
public:
static AIKIT_BizParam* build(AIKIT_ParamBuilder* param);
static AIKIT_InputData* build(AIKIT_DataBuilder* data);
static AIKIT_CustomData* build(AIKIT_CustomBuilder* custom);
};
} // namespace AIKIT
#endif

View File

@@ -0,0 +1,158 @@
#ifndef AIKIT_BIZ_CONFIG_H
#define AIKIT_BIZ_CONFIG_H
#include <iostream>
#include "aikit_biz_type.h"
namespace AIKIT {
class ConfigBuilder;
class AppBuilder;
class AuthBuilder;
class LogBuilder;
class CodecBuilder;
class AIKITAPI AIKIT_Configurator {
public:
static ConfigBuilder& builder();
};
class AIKITAPI ConfigBuilder {
public:
/**
* @brief 用户app信息配置
*/
AppBuilder& app();
/**
* @brief 授权相关配置
*/
AuthBuilder& auth();
/**
* @brief 日志相关配置
*/
LogBuilder& log();
/**
* @brief 音视频编解码相关配置
*/
CodecBuilder& codec();
};
class AIKITAPI AppBuilder : public ConfigBuilder {
public:
/**
* @brief 配置应用id
*/
AppBuilder& appID(const char* appID);
/**
* @brief 配置应用key
*/
AppBuilder& apiKey(const char* apiKey);
/**
* @brief 配置应用secret
*/
AppBuilder& apiSecret(const char* apiSecret);
/**
* @brief 配置sdk工作目录需可读可写权限
*/
AppBuilder& workDir(const char* workDir);
/**
* @brief 配置只读资源存放目录, 需可读权限
*/
AppBuilder& resDir(const char* resDir);
/**
* @brief 配置文件路径,包括文件名
*/
AppBuilder& cfgFile(const char* cfgFile);
};
class AIKITAPI AuthBuilder : public ConfigBuilder {
public:
/**
* @brief 配置授权方式 0=设备级授权1=应用级授权
*/
AuthBuilder& authType(int authType);
/**
* @brief 配置离线激活方式的授权文件路径,为空时需联网进行首次在线激活
*/
AuthBuilder& licenseFile(const char* licenseFile);
/**
* @brief 配置授权渠道Id
*/
AuthBuilder& channelID(const char* channelID);
/**
* @brief 配置用户自定义设备标识
*/
AuthBuilder& UDID(const char* UDID);
/**
* @brief 配置授权离线能力,如需配置多个能力,可用";"分隔开, 如"xxx;xxx"
*/
AuthBuilder& ability(const char* ability);
/**
* @brief 配置单个在线能力id及对应请求地址如需配置多个能力可多次调用
* url格式参考https://cn-huadong-1.xf-yun.com/v1/private/xxx:443
*/
AuthBuilder& abilityURL(const char* ability, const char* url);
};
/**
* @brief 配置SDK日志信息
*/
class AIKITAPI LogBuilder : public ConfigBuilder {
public:
/**
* @brief 配置日志等级
*/
LogBuilder& logLevel(int32_t level);
/**
* @brief 配置日志输出模式
*/
LogBuilder& logMode(int32_t mode);
/**
* @brief 配置日志文件保存文件
*/
LogBuilder& logPath(const char* path);
};
/**
* @brief 配置SDK音视频编解码方式
*/
class AIKITAPI CodecBuilder : public ConfigBuilder {
public:
/**
* @brief 配置全局音频编码选项
*/
CodecBuilder& audioEncoding(const char* encodingType);
/**
* @brief 配置能力级音频编码选项
*/
CodecBuilder& audioEncoding(const char* abilityID, const char* encodingType);
/**
* @brief 配置全局音频解码选项
*/
CodecBuilder& audioDecoding(const char* encodingType);
/**
* @brief 配置能力级音频解码选项
*/
CodecBuilder& audioDecoding(const char* abilityID, const char* encodingType);
};
} // end of namespace AIKIT
#endif

View File

@@ -0,0 +1,35 @@
#ifndef AIKIT_BIZ_OBSOLETE_BUILDER_H
#define AIKIT_BIZ_OBSOLETE_BUILDER_H
#include "aikit_biz_type.h"
namespace AIKIT {
class AIKIT_ParamBuilder;
class AIKITAPI AIKIT_DataBuilderObsolete {
public:
//设置SDK输入数据格式描述参数
attribute_deprecated virtual AIKIT_DataBuilderObsolete* desc(const char* key, AIKIT_ParamBuilder* builder) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* text(const char* key, const char* data, uint32_t dataLen, uint32_t dataStatus) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* textPath(const char* key, const char* path) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* textFile(const char* key, const FILE* file) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* audio(const char* key, const char* data, uint32_t dataLen, uint32_t dataStatus) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* audioPath(const char* key, const char* path) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* audioFile(const char* key, const FILE* file) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* image(const char* key, const char* data, uint32_t dataLen, uint32_t dataStatus) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* imagePath(const char* key, const char* path) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* imageFile(const char* key, const FILE* file) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* video(const char* key, const char* data, uint32_t dataLen, uint32_t dataStatus) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* videoPath(const char* key, const char* path) = 0;
attribute_deprecated virtual AIKIT_DataBuilderObsolete* videoFile(const char* key, const FILE* file) = 0;
};
} // namespace AIKIT
#endif

View File

@@ -0,0 +1,105 @@
#ifndef __AIKIT_BIZ_TYPE_H__
#define __AIKIT_BIZ_TYPE_H__
#include <stdio.h>
#include "aikit_type.h"
/**
* AIKIT API type
*/
#if defined(_MSC_VER) /* Microsoft Visual C++ */
# if !defined(AIKITAPI)
# if defined(AIKIT_EXPORT)
# define AIKITAPI __declspec(dllexport)
# else
# define AIKITAPI __declspec(dllimport)
# endif
# endif
#elif defined(__BORLANDC__) /* Borland C++ */
# if !defined(AIKITAPI)
# define AIKITAPI __stdcall
# endif
#elif defined(__WATCOMC__) /* Watcom C++ */
# if !defined(AIKITAPI)
# define AIKITAPI __stdcall
# endif
#else /* Any other including Unix */
# if !defined(AIKITAPI)
# if defined(AIKIT_EXPORT)
# define AIKITAPI __attribute__ ((visibility("default")))
# else
# define AIKITAPI
# endif
# endif
#endif
#if defined(_MSC_VER)
# if !defined(attribute_deprecated)
# define attribute_deprecated __declspec(deprecated)
# endif
#else
# if !defined(attribute_deprecated)
# define attribute_deprecated __attribute__((deprecated))
# endif
#endif
#ifndef int32_t
typedef int int32_t;
#endif
#ifndef uint32_t
typedef unsigned int uint32_t;
#endif
typedef AIKIT_BaseParam AIKIT_BizParam;
typedef AIKIT_BaseParamPtr AIKIT_BizParamPtr;
typedef AIKIT_BaseData AIKIT_BizData;
typedef AIKIT_BaseDataPtr AIKIT_BizDataPtr;
typedef AIKIT_BizData AIKIT_InputData;
typedef struct _AIKIT_BaseDataList {
AIKIT_BaseData *node; // 链表节点
int32_t count; // 链表节点个数
int32_t totalLen; // 链表节点所占内存空间count*(sizeof(AIKIT_BaseData)+strlen(node->key)+node->len)
} AIKIT_BaseDataList, *AIKIT_BaseDataListPtr; // 配置对复用该结构定义
typedef struct _AIKIT_BaseParamList {
AIKIT_BaseParam *node; // 链表节点
int32_t count; // 链表节点个数
int32_t totalLen; // 链表节点所占内存空间count*(sizeof(AIKIT_BaseParam)+strlen(node->key)+node->len)
} AIKIT_BaseParamList, *AIKIT_BaseParamListPtr; // 配置对复用该结构定义
typedef AIKIT_BaseDataList AIKIT_OutputData;
typedef AIKIT_BaseParamList AIKIT_OutputEvent;
typedef struct {
void* usrContext;
const char* abilityID;
size_t handleID;
} AIKIT_HANDLE;
typedef void (*AIKIT_OnOutput)(AIKIT_HANDLE* handle, const AIKIT_OutputData* output);
typedef void (*AIKIT_OnEvent)(AIKIT_HANDLE* handle, AIKIT_EVENT eventType, const AIKIT_OutputEvent* eventValue);
typedef void (*AIKIT_OnError)(AIKIT_HANDLE* handle, int32_t err, const char* desc);
typedef struct {
AIKIT_OnOutput outputCB; //輸出回调
AIKIT_OnEvent eventCB; //事件回调
AIKIT_OnError errorCB; //错误回调
} AIKIT_Callbacks;
typedef struct {
int authType; // 授权方式0=设备级授权1=应用级授权
const char* appID; // 应用id
const char* apiKey; // 应用key
const char* apiSecret; // 应用secret
const char* workDir; // sdk工作目录需可读可写权限
const char* resDir; // 只读资源存放目录,需可读权限
const char* licenseFile; // 离线激活方式的授权文件存放路径,为空时需联网进行首次在线激活
const char* batchID; // 授权批次
const char* UDID; // 用户自定义设备标识
const char* cfgFile; // 配置文件路径,包括文件名
} AIKIT_InitParam;
#endif // __AIKIT_BIZ_TYPE_H__

View File

@@ -0,0 +1,12 @@
#ifndef AIKIT_COMMON_H
#define AIKIT_COMMON_H
typedef enum AIKIT_DATA_PTR_TYPE_E {
AIKIT_DATA_PTR_MEM = 0, // 数据内存指针
AIKIT_DATA_PTR_FILE = 1, // 数据文件指针FILE指针
AIKIT_DATA_PTR_PATH = 2 // 数据文件路径指针
} AIKIT_DATA_PTR_TYPE;
#endif //AIKIT_COMMON_H

View File

@@ -0,0 +1,35 @@
/*
* @Description:
* @version:
* @Author: xkzhang9
* @Date: 2020-10-28 10:20:45
* @LastEditors: rfge
* @LastEditTime: 2020-12-28 11:14:20
*/
#ifndef AIKIT_CONSTANT_H
#define AIKIT_CONSTANT_H
typedef enum {
LOG_STDOUT = 0,
LOG_LOGCAT,
LOG_FILE,
} AIKIT_LOG_MODE;
typedef enum {
LOG_LVL_VERBOSE,
LOG_LVL_DEBUG,
LOG_LVL_INFO,
LOG_LVL_WARN,
LOG_LVL_ERROR,
LOG_LVL_CRITICAL,
LOG_LVL_OFF = 100,
} AIKIT_LOG_LEVEL;
typedef enum {
MEMORY_FULL_MODE,
MEMORY_FRIENDLY_MODE
} AIKIT_MEMORY_MODE;
#endif //AIKIT_CONSTANT_H

View File

@@ -0,0 +1,161 @@
/*
* @Description:
* @version:
* @Author: rfge
* @Date: 2020-11-01 17:56:53
* @LastEditors: rfge
* @LastEditTime: 2020-12-14 14:26:44
*/
//
// Created by xkzhang9 on 2020/6/10.
//
#ifndef AIKIT_ERR_H
#define AIKIT_ERR_H
typedef enum {
AIKIT_ERR_AUTH = 18000, // 授权部分
AIKIT_ERR_RES = AIKIT_ERR_AUTH + 100, // 资源部分
AIKIT_ERR_ENG = AIKIT_ERR_AUTH + 200, // 引擎部分
AIKIT_ERR_SDK = AIKIT_ERR_AUTH + 300, // SDK部分
AIKIT_ERR_SYS = AIKIT_ERR_AUTH + 400, // 系统部分
AIKIT_ERR_PARAM = AIKIT_ERR_AUTH + 500, // 参数部分
AIKIT_ERR_PROTOCOL = AIKIT_ERR_AUTH + 600, // 协议部分
AIKIT_ERR_CLOUD = AIKIT_ERR_AUTH + 700, // 云端错误
AIKIT_ERR_LOCAL_NET= AIKIT_ERR_AUTH + 800, //本地网络网络
AIKIT_ERR_VMS = AIKIT_ERR_AUTH + 900, // 虚拟人错误
AIKIT_ERR_SPARK = AIKIT_ERR_AUTH + 950, // spark大模型错误
AIKIT_ERR_OTHER = 0xFF00 // 其他
} AIKIT_ERR_SECTION;
typedef enum {
AIKIT_ERR_SUCCESS = 0, // 操作成功
AIKIT_ERR_GENERAL_FAILED = 1, // 一般错误
AIKIT_ERR_AUTH_LICENSE_NOT_FOUND = AIKIT_ERR_AUTH + 0, // 18000 本地license文件不存在
AIKIT_ERR_AUTH_LICENSE_FILE_INVALID = AIKIT_ERR_AUTH + 1, // 18001 授权文件内容非法
AIKIT_ERR_AUTH_LICENSE_PARSE_FAILED = AIKIT_ERR_AUTH + 2, // 18002 授权文件解析失败
AIKIT_ERR_AUTH_PAYLOAD_DEFECT = AIKIT_ERR_AUTH + 3, // 18003 payload内容缺失
AIKIT_ERR_AUTH_SIGN_DEFECT = AIKIT_ERR_AUTH + 4, // 18004 signature内容缺失
AIKIT_ERR_AUTH_EXPIRED = AIKIT_ERR_AUTH + 5, // 18005 授权已过期
AIKIT_ERR_AUTH_TIME_ERROR = AIKIT_ERR_AUTH + 6, // 18006 授权时间错误比正常时间慢30分钟以上
AIKIT_ERR_AUTH_APP_NOT_MATCH = AIKIT_ERR_AUTH + 7, // 18007 授权应用不匹配apiKey、apiSecret
AIKIT_ERR_AUTH_LICENSE_EXPIRED = AIKIT_ERR_AUTH + 8, // 18008 授权文件激活过期
AIKIT_ERR_AUTH_NULL_APP_PTR = AIKIT_ERR_AUTH + 9, // 18009 授权app信息指针为空
AIKIT_ERR_AUTH_PLATFORM_NOT_MATCH = AIKIT_ERR_AUTH + 10, // 18010 离线授权激活文件指定平台与设备平台不匹配
AIKIT_ERR_AUTH_ARCH_NOT_MATCH = AIKIT_ERR_AUTH + 11, // 18011 离线授权激活文件指定架构与设备cpu架构不匹配
AIKIT_ERR_AUTH_WRONG_LICENSE_NUM = AIKIT_ERR_AUTH + 12, // 18012 离线授权激活文件中包含License个数异常
AIKIT_ERR_AUTH_DEVICE_NOT_FOUND = AIKIT_ERR_AUTH + 13, // 18013 离线授权激活文件中未找到当前设备
AIKIT_ERR_AUTH_LEVEL_NOT_VALID = AIKIT_ERR_AUTH + 14, // 18014 离线授权激活文件中设备指纹安全等级非法
AIKIT_ERR_AUTH_HARDWARE_FAILED = AIKIT_ERR_AUTH + 15, // 18015 硬件授权验证失败
AIKIT_ERR_AUTH_OFFLINE_PROT_INVALID = AIKIT_ERR_AUTH + 16, // 18016 离线授权激活文件内容非法
AIKIT_ERR_AUTH_HEADER_INVALID = AIKIT_ERR_AUTH + 17, // 18017 离线授权激活文件中协议头非法
AIKIT_ERR_AUTH_PART_COUNT_INVALID = AIKIT_ERR_AUTH + 18, // 18018 离线授权激活文件中指纹组成项个数为0
AIKIT_ERR_AUTH_RESOURCE_EXPIREd = AIKIT_ERR_AUTH + 19, // 18019 资源已过期
AIKIT_ERR_RES_VERIFY_FAILED = AIKIT_ERR_RES + 0, // 18100 资源鉴权失败
AIKIT_ERR_RES_INVALID_HEADER= AIKIT_ERR_RES + 1, // 18101 资源格式解析失败
AIKIT_ERR_RES_NOT_MATCH = AIKIT_ERR_RES + 2, // 18102 资源(与引擎)不匹配
AIKIT_ERR_RES_NULL_PTR = AIKIT_ERR_RES + 3, // 18103 资源参数不存在指针为NULL
AIKIT_ERR_RES_OPEN_FAILED = AIKIT_ERR_RES + 4, // 18104 资源路径打开失败
AIKIT_ERR_RES_LOAD_FAILED = AIKIT_ERR_RES + 5, // 18105 资源加载失败workDir内未找到对应资源
AIKIT_ERR_RES_UNLOAD_FAILED = AIKIT_ERR_RES + 6, // 18106 资源卸载失败, 卸载的资源未加载过
AIKIT_ERR_ENG_VERIFY_FAILED = AIKIT_ERR_ENG + 0, // 18200 引擎鉴权失败
AIKIT_ERR_ENG_LOAD_FAILED = AIKIT_ERR_ENG + 1, // 18201 引擎动态加载失败
AIKIT_ERR_ENG_NOT_INITED = AIKIT_ERR_ENG + 2, // 18202 引擎未初始化
AIKIT_ERR_ENG_API_NOT_SUPPORT = AIKIT_ERR_ENG + 3, // 18203 引擎不支持该接口调用
AIKIT_ERR_ENG_NULL_CREATE_PTR = AIKIT_ERR_ENG + 4, // 18204 引擎craete函数指针为空
AIKIT_ERR_SDK_INVALID = AIKIT_ERR_SDK + 0, // 18300 sdk不可用
AIKIT_ERR_SDK_NOT_INITED = AIKIT_ERR_SDK + 1, // 18301 sdk没有初始化
AIKIT_ERR_SDK_INIT_FAILED = AIKIT_ERR_SDK + 2, // 18302 sdk初始化失败
AIKIT_ERR_SDK_ALREADY_INIT = AIKIT_ERR_SDK + 3, // 18303 sdk已经初始化
AIKIT_ERR_SDK_INVALID_PARAM = AIKIT_ERR_SDK + 4, // 18304 sdk不合法参数
AIKIT_ERR_SDK_NULL_SESSION_HANDLE = AIKIT_ERR_SDK + 5, // 18305 sdk会话handle为空
AIKIT_ERR_SDK_SESSION_NOT_FOUND = AIKIT_ERR_SDK + 6, // 18306 sdk会话未找到
AIKIT_ERR_SDK_SESSION_ALREADY_END = AIKIT_ERR_SDK + 7, // 18307 sdk会话重复终止
AIKIT_ERR_SDK_TIMEOUT = AIKIT_ERR_SDK + 8, // 18308 超时错误
AIKIT_ERR_SDK_INITING = AIKIT_ERR_SDK + 9, // 18309 sdk正在初始化中
AIKIT_ERR_SDK_SESSEION_ALREAY_START = AIKIT_ERR_SDK + 10, // 18310 sdk会话重复开启
AIKIT_ERR_SDK_CONCURRENT_OVERFLOW = AIKIT_ERR_SDK + 11, // 18311 sdk同一能力并发路数超出最大限制
AIKIT_ERR_SYS_WORK_DIR_ILLEGAL = AIKIT_ERR_SYS + 0, // 18400 工作目录无写权限
AIKIT_ERR_SYS_DEVICE_UNKNOWN = AIKIT_ERR_SYS + 1, // 18401 设备指纹获取失败,设备未知
AIKIT_ERR_SYS_FILE_OPEN_FAILED = AIKIT_ERR_SYS + 2, // 18402 文件打开失败
AIKIT_ERR_SYS_MEM_ALLOC_FAILED = AIKIT_ERR_SYS + 3, // 18403 内存分配失败
AIKIT_ERR_SYS_DEVICE_COMPARE_FAILED = AIKIT_ERR_SYS + 4, // 18404 设备指纹比较失败
AIKIT_ERR_SYS_WORK_DIR_NOT_EXIST = AIKIT_ERR_SYS + 5, // 18405 工作目录不存在
AIKIT_ERR_PARAM_NOT_FOUND = AIKIT_ERR_PARAM + 0, // 18500 未找到该参数key
AIKIT_ERR_PARAM_OVERFLOW = AIKIT_ERR_PARAM + 1, // 18501 参数范围溢出,不满足约束条件
AIKIT_ERR_PARAM_NULL_INIT_PARAM_PTR = AIKIT_ERR_PARAM + 2, // 18502 sdk初始化参数为空
AIKIT_ERR_PARAM_NULL_APPID_PTR = AIKIT_ERR_PARAM + 3, // 18503 sdk初始化参数中appid为空
AIKIT_ERR_PARAM_NULL_APIKEY_PTR = AIKIT_ERR_PARAM + 4, // 18504 sdk初始化参数中apiKey为空
AIKIT_ERR_PARAM_NULL_APISECRET_PTR = AIKIT_ERR_PARAM + 5, // 18505 sdk初始化参数中apiSecret为空
AIKIT_ERR_PARAM_NULL_ABILITY_PTR = AIKIT_ERR_PARAM + 6, // 18506 ability参数为空
AIKIT_ERR_PARAM_NULL_INPUT_PTR = AIKIT_ERR_PARAM + 7, // 18507 input参数为空
AIKIT_ERR_PARAM_DATA_KEY_NOT_EXIST = AIKIT_ERR_PARAM + 8, // 18508 输入数据参数Key不存在
AIKIT_ERR_PARAM_REQUIRED_MISSED = AIKIT_ERR_PARAM + 9, // 18509 必填参数缺失
AIKIT_ERR_PARAM_NULL_OUTPUT_PTR = AIKIT_ERR_PARAM + 10, // 18510 output参数缺失
AIKIT_ERR_CODEC_NOT_SUPPORT = AIKIT_ERR_PARAM + 20, // 18520 不支持的编解码类型
AIKIT_ERR_CODEC_NULL_PTR = AIKIT_ERR_PARAM + 21, // 18521 编解码handle指针为空
AIKIT_ERR_CODEC_MODULE_MISSED = AIKIT_ERR_PARAM + 22, // 18522 编解码模块条件编译未打开
AIKIT_ERR_CODEC_ENCODE_FAIL = AIKIT_ERR_PARAM + 23, // 18523 编码错误
AIKIT_ERR_CODEC_DECODE_FAIL = AIKIT_ERR_PARAM + 24, // 18524 解码错误
AIKIT_ERR_VAD_RESPONSE_TIMEOUT = AIKIT_ERR_PARAM + 30, // VAD静音超时
AIKIT_ERR_PROTOCOL_TIMESTAMP_MISSING = AIKIT_ERR_PROTOCOL + 0, // 18600 协议中时间戳字段缺失
AIKIT_ERR_PROTOCOL_ABILITY_NOT_FOUND = AIKIT_ERR_PROTOCOL + 1, // 18601 协议中未找到该能力ID
AIKIT_ERR_PROTOCOL_RESOURCE_NOT_FOUND = AIKIT_ERR_PROTOCOL + 2, // 18602 协议中未找到该资源ID
AIKIT_ERR_PROTOCOL_ENGINE_NOT_FOUND = AIKIT_ERR_PROTOCOL + 3, // 18603 协议中未找到该引擎ID
AIKIT_ERR_PROTOCOL_ZERO_ENGINE_NUM = AIKIT_ERR_PROTOCOL + 4, // 18604 协议中引擎个数为0
AIKIT_ERR_PROTOCOL_NOT_LOADED = AIKIT_ERR_PROTOCOL + 5, // 18605 协议未被初始化解析
AIKIT_ERR_PROTOCOL_INTERFACE_TYPE_NOT_MATCH = AIKIT_ERR_PROTOCOL + 6, // 18606 协议能力接口类型不匹配
AIKIT_ERR_PROTOCOL_TEMP_VERIFY_FAILED = AIKIT_ERR_PROTOCOL + 7, // 18607 预置协议解析失败
AIKIT_ERR_CLOUD_GENERAL_FAILED = AIKIT_ERR_CLOUD + 0, // 18700 通用网络错误
AIKIT_ERR_CLOUD_CONNECT_FAILED = AIKIT_ERR_CLOUD + 1, // 18701 网路不通
AIKIT_ERR_CLOUD_403 = AIKIT_ERR_CLOUD + 2, // 18702 网关检查不过
AIKIT_ERR_CLOUD_WRONG_RSP_FORMAT = AIKIT_ERR_CLOUD + 3, // 18703 云端响应格式不对
AIKIT_ERR_CLOUD_APP_NOT_FOUND = AIKIT_ERR_CLOUD + 4, // 18704 应用未注册
AIKIT_ERR_CLOUD_APP_CHECK_FAILED = AIKIT_ERR_CLOUD + 5, // 18705 应用apiKey&&apiSecret校验失败
AIKIT_ERR_CLOUD_WRONG_ARCHITECT = AIKIT_ERR_CLOUD + 6, // 18706 引擎不支持的平台架构
AIKIT_ERR_CLOUD_AUTH_EXPIRED = AIKIT_ERR_CLOUD + 7, // 18707 授权已过期
AIKIT_ERR_CLOUD_AUTH_FULL = AIKIT_ERR_CLOUD + 8, // 18708 授权数量已满
AIKIT_ERR_CLOUD_ABILITY_NOT_FOUND = AIKIT_ERR_CLOUD + 9, // 18709 未找到该app绑定的能力
AIKIT_ERR_CLOUD_RESOURCE_NOT_FOUND = AIKIT_ERR_CLOUD + 10, // 18710 未找到该app绑定的能力资源
AIKIT_ERR_CLOUD_JSON_PARSE_FAILED = AIKIT_ERR_CLOUD + 11, // 18711 JSON操作失败
AIKIT_ERR_CLOUD_404 = AIKIT_ERR_CLOUD + 12, // 18712 http 404错误
AIKIT_ERR_CLOUD_LEVEL_NOT_MATCH = AIKIT_ERR_CLOUD + 13, // 18713 设备指纹安全等级不匹配
AIKIT_ERR_CLOUD_401 = AIKIT_ERR_CLOUD + 14, // 18714 用户没有访问权限,需要进行身份认证
AIKIT_ERR_CLOUD_SDK_NOT_FOUND = AIKIT_ERR_CLOUD + 15, // 18715 未找到该SDK ID
AIKIT_ERR_CLOUD_ABILITYS_NOT_FOUND = AIKIT_ERR_CLOUD + 16, // 18716 未找到该组合能力集合
AIKIT_ERR_CLOUD_ABILITY_NOT_ENOUGH = AIKIT_ERR_CLOUD + 17, // 18717 SDK组合能力授权不足
AIKIT_ERR_CLOUD_APP_SIG_INVALID = AIKIT_ERR_CLOUD + 18, // 18718 无效授权应用签名
AIKIT_ERR_CLOUD_APP_SIG_NOT_UNIQUE = AIKIT_ERR_CLOUD + 19, // 18719 应用签名不唯一
AIKIT_ERR_CLOUD_SCHEMA_INVALID = AIKIT_ERR_CLOUD + 20, // 18720 能力schema不可用
AIKIT_ERR_CLOUD_TEMPLATE_NOT_FOUND = AIKIT_ERR_CLOUD + 21, // 18721 竞争授权: 未找到能力集模板
AIKIT_ERR_CLOUD_ABILITY_NOT_IN_TEMPLATE = AIKIT_ERR_CLOUD + 22, // 18722 竞争授权: 能力不在模板能力集模板中
AIKIT_ERR_LOCAL_NET_CONNECT_FAILED = AIKIT_ERR_LOCAL_NET + 1, // 18801 连接建立出错
AIKIT_ERR_LOCAL_NET_RES_WAIT_TIMEOUT = AIKIT_ERR_LOCAL_NET + 2, // 18802 结果等待超时
AIKIT_ERR_LOCAL_NET_CONNECT_ERROR = AIKIT_ERR_LOCAL_NET + 3, // 18803 连接状态异常
AIKIT_ERR_VMS_START_ERROR = AIKIT_ERR_VMS + 1, // 18901虚拟人启动错误
AIKIT_ERR_VMS_STOP_ERROR = AIKIT_ERR_VMS + 2, // 18902虚拟人结束错误
AIKIT_ERR_VMS_DRIVE_ERROR = AIKIT_ERR_VMS + 3, // 18903虚拟人驱动错误
AIKIT_ERR_VMS_HEARTBEAT_ERROR = AIKIT_ERR_VMS + 4, // 18904虚拟人心跳报错
AIKIT_ERR_VMS_TIMEOUT = AIKIT_ERR_VMS + 5, // 18905虚拟人服务超时
AIKIT_ERR_VMS_OTHER_ERROR = AIKIT_ERR_VMS + 6, // 18906虚拟人通用报错
AIKIT_ERR_SPARK_REQUEST_UNORDERED = AIKIT_ERR_SPARK + 1, // 18951 同一流式大模型会话,禁止并发交互请求
AIKIT_ERR_SPARK_TEXT_INVALID = AIKIT_ERR_SPARK + 2 // 18952 输入文本格式或内容非法
} AIKIT_ERR;
typedef enum { AIKIT_ERR_TYPE_AUTH = 0, AIKIT_ERR_TYPE_HTTP = 1 } AIKIT_ERR_TYPE;
#endif //AIKIT_ERR_H

View File

@@ -0,0 +1,90 @@
#ifndef AIKIT_SPARK_H
#define AIKIT_SPARK_H
#include "aikit_biz_api.h"
namespace AIKIT {
class AIKITAPI ChatParam {
public:
static ChatParam* builder();
virtual ~ChatParam();
/**
* @brief 配置授权的用户id用于关联用户交互的上下文
*/
virtual ChatParam* uid(const char* uid) = 0;
/**
* @brief 配置chat领域信息
*/
virtual ChatParam* domain(const char* domain) = 0;
/**
* @brief 配置内容审核策略
*/
virtual ChatParam* auditing(const char* auditing) = 0;
/**
* @brief 配置关联会话chat id标识需要保障⽤户下唯⼀
*/
virtual ChatParam* chatID(const char* chatID) = 0;
/**
* @brief 配置核采样阈值默认值0.5,向上调整可以增加结果的随机程度
*/
virtual ChatParam* temperature(const float& temperature) = 0;
/**
* @brief 配置从k个候选中随机选择⼀个⾮等概率默认值4取值范围1-99
*/
virtual ChatParam* topK(const int& topK) = 0;
/**
* @brief 配置回答的tokens的最大长度默认值2048
*/
virtual ChatParam* maxToken(const int& maxToken) = 0;
/**
* @brief 配置chat服务域名地址
*/
virtual ChatParam* url(const char* url) = 0;
/**
* @brief 配置chat扩展功能参数
*/
virtual ChatParam* param(const char* key, const char* value) = 0;
virtual ChatParam* param(const char* key, int value) = 0;
virtual ChatParam* param(const char* key, double value) = 0;
virtual ChatParam* param(const char* key, bool value) = 0;
};
using AIChat_Handle = AIKIT_HANDLE;
typedef void (*onChatOutput)(AIChat_Handle* handle, const char* role, const char* content, const int& index);
typedef void (*onChatToken)(AIChat_Handle* handle, const int& completionTokens, const int& promptTokens, const int& totalTokens);
typedef void (*onChatError)(AIChat_Handle* handle, const int& err, const char* errDesc);
typedef struct {
onChatOutput outputCB; //输出回调
onChatToken tokenCB; //token计算信息回调
onChatError errorCB; //错误回调
} AIKIT_ChatCBS;
AIKITAPI int32_t AIKIT_ChatCallback(const AIKIT_ChatCBS& cbs);
//异步chat
AIKITAPI int32_t AIKIT_AsyncChat(const ChatParam* params, const char* inputText, void* usrContext);
AIKITAPI int32_t AIKIT_Start(const ChatParam* params, void* usrContext, AIChat_Handle** outHandle);
AIKITAPI int32_t AIKIT_Write(AIChat_Handle* handle, const char* inputText);
//
//AIKITAPI int32_t AIKIT_End(AIChat_Handle* handle);
} // end of namespace AIKIT
#endif

View File

@@ -0,0 +1,107 @@
#ifndef __AIKIT_TYPE_H__
#define __AIKIT_TYPE_H__
#include <stddef.h>
#include <stdint.h>
#include "aikit_common.h"
#if defined(_MSC_VER) /* Microsoft Visual C++ */
#pragma pack(push, 8)
#elif defined(__BORLANDC__) /* Borland C++ */
#pragma option -a8
#elif defined(__WATCOMC__) /* Watcom C++ */
#pragma pack(push, 8)
#else /* Any other including Unix */
#endif
typedef enum _AIKIT_VarType {
AIKIT_VarTypeString = 0, // 字符串型
AIKIT_VarTypeInt = 1, // 整型
AIKIT_VarTypeDouble = 2, // 实型
AIKIT_VarTypeBool = 3, // 布尔类型
AIKIT_VarTypeParamPtr = 4, // 子参数类型
AIKIT_VarTypeUnknown = -1 //
} AIKIT_VarType;
typedef enum _AIKIT_DataStatus {
AIKIT_DataBegin = 0, // 首数据
AIKIT_DataContinue = 1, // 中间数据
AIKIT_DataEnd = 2, // 尾数据
AIKIT_DataOnce = 3, // 非会话单次输入输出
} AIKIT_DataStatus;
typedef enum _AIKIT_DataType {
AIKIT_DataText = 0, // 文本数据
AIKIT_DataAudio = 1, // 音频数据
AIKIT_DataImage = 2, // 图像数据
AIKIT_DataVideo = 3, // 视频数据
// AIKIT_DataPer = 4, // 个性化数据
} AIKIT_DataType;
typedef enum {
AIKIT_Event_UnKnown = 0,
AIKIT_Event_Start = 1, // 引擎计算开始事件
AIKIT_Event_End = 2, // 引擎计算结束事件
AIKIT_Event_Timeout = 3, // 引擎计算超时事件
AIKIT_Event_Progress = 4, // 引擎计算进度事件
// 在线能力连接状态事件
AIKIT_Event_Null = 10, // 空连接状态
AIKIT_Event_Init, // 初始状态
AIKIT_Event_Connecting, // 正在连接
AIKIT_Event_ConnTimeout, // 连接超时
AIKIT_Event_Failed, // 连接失败
AIKIT_Event_Connected, // 已经连接
AIKIT_Event_Error, // 收发出错,意味着断开连接
AIKIT_Event_Disconnected, // 断开连接,一般指心跳超时,连接无错误
AIKIT_Event_Closing, // 正在关闭连接
AIKIT_Event_Closed, // 已经关闭连接
AIKIT_Event_Responding, // 网络连接正在响应
AIKIT_Event_ResponseTimeout, // 网络连接响应超时
// VAD事件
AIKIT_Event_VadBegin = 30, // VAD开始
AIKIT_Event_VadEnd // VAD结束
} AIKIT_EVENT;
typedef struct _AIKIT_BaseParam {
struct _AIKIT_BaseParam *next; // 链表指针
const char *key; // 数据标识
void *value; // 数据实体
void* reserved; // 预留字段
int32_t len; // 数据长度
int32_t type; // 变量类型取值参见AIKIT_VarType
} AIKIT_BaseParam, *AIKIT_BaseParamPtr; // 配置对复用该结构定义
typedef struct _AIKIT_BaseData {
struct _AIKIT_BaseData *next; // 链表指针
AIKIT_BaseParam *desc; // 数据描述,包含每个数据(audio/video/text/image)的所有特征参数数据(sample_rate,channels,data等)
const char *key; // 数据标识
void *value; // 数据实体
void* reserved; // 预留字段
int32_t len; // 数据长度
int32_t type; // 数据类型取值参见AIKIT_DataType
int32_t status; // 数据状态取值参见AIKIT_DataStatus
int32_t from; // 数据来源取值参见AIKIT_DATA_PTR_TYPE
} AIKIT_BaseData, *AIKIT_BaseDataPtr;
typedef struct _AIKIT_CustomData {
struct _AIKIT_CustomData* next; // 链表指针
const char* key; // 数据标识
void* value; // 数据内容
void* reserved; // 预留字段
int32_t index; // 数据索引,用户可自定义设置
int32_t len; // 数据长度type非DATA_PTR_FILE时本字段有效
int32_t from; // 数据内容的类型取值参见枚举AIKIT_DATA_PTR_TYPE
} AIKIT_CustomData, *AIKIT_CustomDataPtr;
/* Reset the structure packing alignments for different compilers. */
#if defined(_MSC_VER) /* Microsoft Visual C++ */
#pragma pack(pop)
#elif defined(__BORLANDC__) /* Borland C++ */
#pragma option -a.
#elif defined(__WATCOMC__) /* Watcom C++ */
#pragma pack(pop)
#endif
#endif

View File

@@ -0,0 +1,16 @@
from launch import LaunchDescription
from launch_ros.actions import Node
def generate_launch_description():
return LaunchDescription([
Node(
package='aikit_tts',
executable='aikit_tts_node',
name='aikit_tts_node',
parameters=[
{'app_id': '268545c7'},
{'api_key': '9e90faba614489a90252f823127f8348'},
{'api_secret': 'M2U5YjJhYjJlMDYzY2Y2ZDhjNjNiZDJl'}
]
)
])

Binary file not shown.

BIN
aikit_tts/libs/libaikit.so Normal file

Binary file not shown.

0
aikit_tts/output.pcm Normal file
View File

20
aikit_tts/package.xml Normal file
View File

@@ -0,0 +1,20 @@
<?xml version="1.0"?>
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>aikit_tts</name>
<version>0.0.0</version>
<description>ROS 2 package for AIKIT TTS</description>
<maintainer email="your@email.com">Your Name</maintainer>
<license>Apache-2.0</license>
<!-- 编译工具依赖 -->
<buildtool_depend>ament_cmake</buildtool_depend>
<!-- 核心依赖depend 同时包含编译和运行时依赖) -->
<depend>rclcpp</depend>
<depend>std_msgs</depend>
<export>
<build_type>ament_cmake</build_type>
</export>
</package>

View File

@@ -0,0 +1,170 @@
#include <fstream>
#include <assert.h>
#include <cstring>
#include <atomic>
#include <unistd.h>
#include <rclcpp/rclcpp.hpp>
#include <std_msgs/msg/string.hpp>
#include "aikit_biz_api.h"
#include "aikit_constant.h"
#include "aikit_biz_config.h"
using namespace std;
using namespace AIKIT;
// 全局变量(可改为类成员变量更规范)
FILE *fin = nullptr;
static const char *ABILITY = "e2e44feff";
static std::atomic_bool ttsFinished(false);
rclcpp::Node::SharedPtr g_node = nullptr;
// 回调函数保持不变(输出、事件、错误处理)
void OnOutput(AIKIT_HANDLE* handle, const AIKIT_OutputData* output){
RCLCPP_INFO(g_node->get_logger(), "OnOutput abilityID: %s", handle->abilityID);
RCLCPP_INFO(g_node->get_logger(), "OnOutput key: %s", output->node->key);
if((output->node->value) && (fin != nullptr))
{
fwrite(output->node->value, sizeof(char), output->node->len, fin);
}
}
void OnEvent(AIKIT_HANDLE* handle, AIKIT_EVENT eventType, const AIKIT_OutputEvent* eventValue){
RCLCPP_INFO(g_node->get_logger(), "OnEvent: %d", eventType);
if(eventType == AIKIT_Event_End){
ttsFinished = true;
}
}
void OnError(AIKIT_HANDLE* handle, int32_t err, const char* desc){
RCLCPP_ERROR(g_node->get_logger(), "OnError: %d, desc: %s", err, desc);
}
// 语音合成函数(改为接收字符串参数)
void text_to_speech(const string& text) {
AIKIT_ParamBuilder* paramBuilder = nullptr;
AIKIT_DataBuilder* dataBuilder = nullptr;
AIKIT_HANDLE* handle = nullptr;
AiText* aiText_raw = nullptr;
int ret = 0;
ttsFinished = false;
// -------------------------- 关键调整把tts_params移到goto之前 --------------------------
// 定义TTS参数JSON移到前面避免goto跳过初始化
const char* tts_params = R"({
"vcn": "xiaoyan",
"language": "zh-CN",
"textEncoding": "UTF-8",
"speed": 50,
"pitch": 50,
"volume": 50
})";
// ---------------------------------------------------------------------------------------
// 打开输出文件路径可改为ROS参数配置
fin = fopen("output.pcm", "w+");
if (fin == nullptr){
RCLCPP_ERROR(g_node->get_logger(), "Failed to open output.pcm");
goto exit; // 此时goto不会跨越任何变量初始化
}
// 配置TTS参数
paramBuilder = AIKIT_ParamBuilder::create();
// 将JSON参数作为顶层"params"字段传入SDK能直接解析
paramBuilder->param("params", tts_params, strlen(tts_params));
// 启动AI服务
ret = AIKIT_Start(ABILITY, AIKIT_Builder::build(paramBuilder), nullptr, &handle);
RCLCPP_INFO(g_node->get_logger(), "AIKIT_Start ret: %d", ret);
if(ret != 0) goto exit;
// 发送文本数据
dataBuilder = AIKIT_DataBuilder::create();
aiText_raw = AiText::get("text")->data(text.c_str(), text.length())->valid();
dataBuilder->payload(aiText_raw);
ret = AIKIT_Write(handle, AIKIT_Builder::build(dataBuilder));
RCLCPP_INFO(g_node->get_logger(), "AIKIT_Write ret: %d", ret);
if(ret != 0) goto exit;
// 等待合成完成
while(ttsFinished != true && rclcpp::ok()){
usleep(1000);
}
AIKIT_End(handle); // 释放会话资源
exit:
if(paramBuilder) { delete paramBuilder; paramBuilder = nullptr; }
if(dataBuilder) { delete dataBuilder; dataBuilder = nullptr; }
if(fin) { fclose(fin); fin = nullptr; }
}
// 订阅文本消息的回调函数
void text_callback(const std_msgs::msg::String::SharedPtr msg) {
RCLCPP_INFO(g_node->get_logger(), "Received text: %s", msg->data.c_str());
text_to_speech(msg->data); // 调用TTS合成
}
// ROS 2节点初始化集成AIKIT初始化
class AikitTtsNode : public rclcpp::Node {
public:
AikitTtsNode() : Node("aikit_tts_node") {
// 从参数服务器获取科大讯飞密钥建议在launch文件中配置
this->declare_parameter("app_id", "268545c7");
this->declare_parameter("api_key", "9e90faba614489a90252f823127f8348");
this->declare_parameter("api_secret", "M2U5YjJhYjJlMDYzY2Y2ZDhjNjNiZDJl");
std::string app_id, api_key, api_secret;
app_id = "268545c7";
api_key = "9e90faba614489a90252f823127f8348";
api_secret = "M2U5YjJhYjJlMDYzY2Y2ZDhjNjNiZDJl";
// 初始化AIKIT
AIKIT_Configurator::builder()
.app()
.appID(app_id.c_str())
.apiKey(api_key.c_str())
.apiSecret(api_secret.c_str())
.workDir("./") // 工作目录如果资源还找不到可改为TTS_RESOURCE_PATH
.auth()
.authType(0)
.log()
.logLevel(LOG_LVL_INFO)
.logPath("./");
int ret = AIKIT_Init();
if(ret != 0) {
RCLCPP_FATAL(this->get_logger(), "AIKIT_Init failed: %d", ret);
rclcpp::shutdown();
}
// 注册回调并创建订阅者
AIKIT_Callbacks cbs = {OnOutput, OnEvent, OnError};
AIKIT_RegisterAbilityCallback(ABILITY, cbs);
subscriber_ = this->create_subscription<std_msgs::msg::String>(
"tts_text", 10, text_callback);
RCLCPP_INFO(this->get_logger(), "Aikit TTS node initialized");
}
~AikitTtsNode() {
AIKIT_UnInit(); // 释放AIKIT资源
}
private:
rclcpp::Subscription<std_msgs::msg::String>::SharedPtr subscriber_;
};
int main(int argc, char *argv[]) {
rclcpp::init(argc, argv);
auto node = std::make_shared<AikitTtsNode>();
g_node = node; // 供回调函数使用
rclcpp::spin(node);
rclcpp::shutdown();
return 0;
}

View File

@@ -44,6 +44,10 @@ install(TARGETS ethercat_node
DESTINATION lib/${PROJECT_NAME})
install(DIRECTORY include/
DESTINATION include)
install(DIRECTORY launch
DESTINATION share/${PROJECT_NAME}/
)
# 测试程序
# add_executable(ethercat_topic_test src/ethercat_topic_test.cpp)
# ament_target_dependencies(ethercat_topic_test rclcpp std_msgs)

View File

@@ -4,7 +4,7 @@
#include <cstdint>
#include <algorithm>
constexpr int NUM_SLAVES = 2; //定义电机数量
constexpr int NUM_SLAVES = 1; //定义电机数量
//运行模式
enum class OpMode : int8_t {

View File

@@ -0,0 +1,24 @@
from launch import LaunchDescription
from launch_ros.actions import Node
from launch.actions import TimerAction
def generate_launch_description():
# realtime_env = {
# "RCUTILS_SCHEDULER_POLICY" : "SCHED_FIFO",
# "RCUTILS_THREAD_PRIORITY" : "90",
# "RCUTILS_CONSOLE_OUTPUT_FORMAT" : "{time}:[{name}]:{message}"
# }
# 创建节点启动描述
ethercat_node = Node(
package='ethercat_control', # 功能包名称
executable='ethercat_node', # 可执行文件名称
name='ethercat_node', # 节点名称(可自定义)
output='screen', # 输出到屏幕
parameters=[{"lock_memory": True, "thread_priority":90}] # 启用模拟时间
)
# 组装launch描述
return LaunchDescription([
ethercat_node
])

View File

@@ -45,7 +45,7 @@
// sudo /opt/etherlab/bin/ethercat cstruct -a 0
// ------------------- 应用参数 -------------------
#define FREQUENCY 1000 //控制周期频率1000Hz
#define FREQUENCY 125 //控制周期频率1000Hz
#define CLOCK_TO_USE CLOCK_MONOTONIC
//#define MEASURE_TIMING
@@ -638,7 +638,7 @@ static void start_rt_cyclic_thread(){
std::thread([]{
// 锁内存 & 实时优先级
mlockall(MCL_CURRENT | MCL_FUTURE); //将当前进程使用的所有内存MCL_CURRENT以及将来可能分配的所有内存MCL_FUTURE都锁定在物理 RAM 中禁止将其交换到磁盘Swap
sched_param param{}; param.sched_priority = sched_get_priority_max(SCHED_FIFO); //将当前线程的调度策略设置为 SCHED_FIFO (First-In, First-Out),并赋予最高优先级
sched_param param{}; param.sched_priority = 90 ; //sched_get_priority_max(SCHED_FIFO); //; //将当前线程的调度策略设置为 SCHED_FIFO (First-In, First-Out),并赋予最高优先级
pthread_setschedparam(pthread_self(), SCHED_FIFO, &param);
cyclic_task(); // 进入控制循环(阻塞)
}).detach();

View File

@@ -84,7 +84,7 @@ public:
std::bind(&EthercatNode::publishJointState, this));
// 打开 CSV 并写表头
open_csv_and_write_header();
// open_csv_and_write_header();
start_time_steady_ = steady_clock_.now();
RCLCPP_INFO(get_logger(), "ethercat_node ready.");
@@ -98,10 +98,10 @@ public:
// 析构时收尾
~EthercatNode() override {
if (csv_.is_open()) {
csv_.flush();
csv_.close();
}
// if (csv_.is_open()) {
// csv_.flush();
// csv_.close();
// }
}
private:
@@ -312,10 +312,10 @@ private:
csp_table_pub_->publish(msg);
// 写入 CSV首行已写表头
if (csv_.is_open()) {
csv_ << line << '\n';
if ((++csv_lines_ % 100) == 0) csv_.flush(); // 每100行刷一次盘减轻开销
}
// if (csv_.is_open()) {
// csv_ << line << '\n';
// if ((++csv_lines_ % 100) == 0) csv_.flush(); // 每100行刷一次盘减轻开销
// }
}
// 打开 CSV 并写表头
@@ -390,6 +390,25 @@ private:
int main(int argc, char** argv){
rclcpp::init(argc, argv);
// auto node = rclcpp::Node::make_shared("ethercat_node");
// int thread_priority = node->declare_parameter("thread_priority",50);
// pthread_t thread = pthread_self();
// struct sched_param param;
// param.sched_priority = thread_priority;
// int ret = pthread_setschedparam(thread,SCHED_FIFO,&param);
// if (ret != 0)
// {
// RCLCPP_ERROR(node->get_logger(),"Failed to set thread priority : %s", strerror(ret));
// }
// else
// {
// RCLCPP_INFO(node->get_logger(),"thread priority set to : %s", thread_priority);
// }
rclcpp::on_shutdown([]{
ethercat_core::stop_soft();
std::this_thread::sleep_for(std::chrono::milliseconds(50));

View File

@@ -55,6 +55,7 @@ class JoyControlNode(Node):
self.get_logger().info('game pad node initialized')
def joy_callback(self, msg):
print("joy_callback: ")
# 处理按键
for i in range(len(msg.buttons)):
if msg.buttons[i] != self.previous_buttons[i]:

View File

@@ -40,7 +40,7 @@ void QuaternionToRPYDeg(double qw, double qx, double qy, double qz, double &roll
pitch = pitch * 180.0 / 3.1415926;
yaw = yaw * 180.0 / 3.1415926;
// rpy_file<<roll<<","<<pitch<<","<<yaw<<std::endl;
std::cout << "Roll: " << roll << ", Pitch: " << pitch << ", Yaw: " << yaw << std::endl;
// std::cout << "Roll: " << roll << ", Pitch: " << pitch << ", Yaw: " << yaw << std::endl;
}
int main(int argc, char **argv)
@@ -89,5 +89,5 @@ int main(int argc, char **argv)
rclcpp::spin(node);
rclcpp::shutdown();
rpy_file.close();
// rpy_file.close();
}

View File

@@ -82,7 +82,7 @@ class LedCommand(Node):
rgb = [val, 0, val,0] * num_ic
elif rgb_data=='white':#紫色
rgb = [val, val, val,0] * num_ic
print(rgb)
# print(rgb)
self.driver.send_frame(rgb)
return
for i in range(start_id,end_id,xnum):
@@ -104,7 +104,7 @@ class LedCommand(Node):
rgb = [val, 0, val,0] * num_ic
elif rgb_data=='white':#紫色
rgb = [val, val, val,0] * num_ic
print(rgb)
# print(rgb)
self.driver.send_frame(rgb)
if self.update==1:
self.update=0

View File

@@ -49,13 +49,13 @@ int main(int argc,char* argv[]){
rs485_driver_.bm_set_mode(2,4);
rs485_driver_.bm_set_enable(2,2);
rs485_driver_.bm_set_param(1,77,40);
rs485_driver_.bm_set_param(1,78,10);
rs485_driver_.bm_set_param(1,79,10);
rs485_driver_.bm_set_param(1,77,51);
rs485_driver_.bm_set_param(1,78,8);
rs485_driver_.bm_set_param(1,79,8);
//rs485_driver_.bm_set_param(1,28,4);
rs485_driver_.bm_set_param(2,77,40);
rs485_driver_.bm_set_param(2,78,10);
rs485_driver_.bm_set_param(2,79,10);
rs485_driver_.bm_set_param(2,77,51);
rs485_driver_.bm_set_param(2,78,8);
rs485_driver_.bm_set_param(2,79,8);
//rs485_driver_.mt_set_pos(1,-5);
//init
/////rs485_driver_.bm_set_mode(1,3);//位置模式
@@ -91,7 +91,7 @@ int main(int argc,char* argv[]){
//读取电机位置
rclcpp::TimerBase::SharedPtr timer_=node->create_wall_timer(std::chrono::milliseconds(2000), [=]() {
static int pub_cnt=0;
log_printf("query motor pos");
// log_printf("query motor pos");
interfaces::msg::MotorPos motor_pos;
float angle1=rs485_driver_.bm_get_pos(1);
float angle2=rs485_driver_.bm_get_pos(2);
@@ -119,7 +119,7 @@ int main(int argc,char* argv[]){
motor_pub->publish(motor_pos);
//std::cout<<"pub msg["<<pub_cnt<<"]:"<<angle1<<","<<angle2<<std::endl;
log_printf("pub pos:%.1f,%.1f",angle1,angle2);
// log_printf("pub pos:%.1f,%.1f",angle1,angle2);
}
pub_cnt+=1;
#if 0

View File

@@ -0,0 +1,7 @@
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Changelog for package openzen_driver
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1.2.0 (2021-04-20)
------------------
* init version

View File

@@ -0,0 +1,49 @@
cmake_minimum_required(VERSION 3.5)
project(openzen_driver)
if(NOT CMAKE_CXX_STANDARD)
set(CMAKE_CXX_STANDARD 17)
endif()
find_package(ament_cmake REQUIRED)
find_package(rclcpp REQUIRED)
find_package(std_msgs REQUIRED)
find_package(sensor_msgs REQUIRED)
find_package(std_srvs REQUIRED)
option(OPENZEN_ROS_BINARY_LIBRARIES "Download binary dependencies" OFF)
SET(ZEN_BLUETOOTH OFF CACHE BOOL "Don't build bluetooth")
SET(ZEN_TESTS OFF CACHE BOOL "Don't build tests")
SET(ZEN_EXAMPLES OFF CACHE BOOL "Don't build examples")
SET(ZEN_USE_BINARY_LIBRARIES ${OPENZEN_ROS_BINARY_LIBRARIES} CACHE BOOL "Don't download binary dependencies (windows only)")
add_subdirectory(openzen)
## Build
add_executable(openzen_node
src/OpenZenNode.cpp
)
target_link_libraries(openzen_node
OpenZen
)
ament_target_dependencies(openzen_node
rclcpp
std_msgs
std_srvs
sensor_msgs)
install(TARGETS openzen_node
DESTINATION lib/${PROJECT_NAME})
install(DIRECTORY launch
DESTINATION share/${PROJECT_NAME}/)
if (BUILD_TESTING)
# launch_test is documented here:
# https://github.com/ros2/launch/tree/master/launch_testing
find_package(launch_testing_ament_cmake)
add_launch_test(test/openzen_test.launch.py)
endif()
ament_package()

16
openzen_dev/LICENSE Normal file
View File

@@ -0,0 +1,16 @@
Copyright 2020 LP-Research Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
associated documentation files (the "Software"), to deal in the Software without restriction,
including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the Software is furnished to
do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or
substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

91
openzen_dev/README.md Normal file
View File

@@ -0,0 +1,91 @@
# OpenZen Node for ROS 2
This software allows to forward sensor data from sensor connected via OpenZen to ROS version 2.
OpenZen is a library for high performance sensor data streaming and processing and supports multiple sensor models: <https://bitbucket.org/lpresearch/openzen/>
## Requirements
### Serial Port Access Rights
After this call, you should logout and login with this user to ensure the changed permissions are in effect.
To allow access to sensors connected via USB, you need to ensure that the user running the ROS sensor node
has access to the /dev/ttyUSB devices. You can do this by adding the user to the dialout group.
```
sudo adduser <username> dialout
```
## Compilation
To compile this driver in your ROS2 setup, follow these steps:
```
mkdir -p ros_ws/src
cd ros_ws/src
git clone --recurse-submodules https://bitbucket.org/lpresearch/openzenros2.git
# get your ROS2 environment going
source /opt/ros/foxy/setup.bash
cd ..
colcon build
source ./install/setup.bash
```
## Running the Driver
You can now run the OpenZen ROS2 driver with this command in the window
you used to compile the software:
```
ros2 run openzen_driver openzen_node --ros-args --remap __ns:=/openzen
```
By default, it will connect to the first available sensor. If you want to connect to
a specific sensor, you can use the serial name of the sensor as parameter, for example:
```
ros2 run openzen_driver openzen_node --ros-args --remap __ns:=/openzen -p sensor_name:="LPMSCU2000573"
```
If your sensor is configured for a different baud rate, you can use the baudrate parameter to
give a specfic baud rate setting:
```
ros2 run openzen_driver openzen_node --ros-args --remap __ns:=/openzen -p sensor_name:="LPMSCU2000573" -p baudrate:=115200
```
Now you can print the IMU values from ROS with:
```
ros2 topic echo /openzen/data
```
To output the values of a GPS unit (if available) use this command:
```
ros2 topic echo /openzen/nav
```
Or plot some values (for example linear acceleration) with
```
ros2 run rqt_plot rqt_plot /openzen/data/angular_velocity
```
We have prepared a sample launch file openzen_lpms.launch to demonstrate data acquisition and plotting using openzen_sensor_node:
```
ros2 launch openzen_driver openzen_lpms.launch.py
```
To change to autocalibration setting via the command line:
```
ros2 service call /enable_gyro_autocalibration std_srvs/SetBool "{data: true}"
```
To trigger an gyroscope calibration:
```
ros2 service call /calibrate_gyroscope std_srvs/Trigger
```

View File

@@ -0,0 +1,23 @@
from launch import LaunchDescription
from launch_ros.actions import Node
def generate_launch_description():
return LaunchDescription([
Node(
package='openzen_driver',
namespace='openzen',
executable='openzen_node',
name='lpms_node'
),
# Note: topic tools not ported to ROS2 yet, so no easy conversion
# from quaternion to euler available (https://github.com/ros2/ros2/issues/857)
Node(
package="rqt_plot",
executable="rqt_plot",
name="ig1_data_plotter",
namespace="openzen",
arguments=["/openzen/data/angular_velocity"]
)
])

6
openzen_dev/openzen/.gitignore vendored Normal file
View File

@@ -0,0 +1,6 @@
.vs/
.vscode/
build/
out/
examples/ExampleCSharp/OpenZenCSharp/obj/
CMakeSettings.json

27
openzen_dev/openzen/.gitmodules vendored Normal file
View File

@@ -0,0 +1,27 @@
[submodule "external/gsl"]
path = external/gsl
url = https://github.com/Microsoft/GSL.git
[submodule "external/expected-lite"]
path = external/expected-lite
url = https://github.com/martinmoene/expected-lite.git
[submodule "external/spdlog"]
path = external/spdlog
url = https://github.com/gabime/spdlog.git
[submodule "external/googletest"]
path = external/googletest
url = https://github.com/google/googletest.git
[submodule "external/asio"]
path = external/asio
url = https://github.com/chriskohlhoff/asio.git
[submodule "external/cereal"]
path = external/cereal
url = https://github.com/USCiLab/cereal.git
[submodule "external/libzmq"]
path = external/libzmq
url = https://github.com/zeromq/libzmq.git
[submodule "external/cppzmq"]
path = external/cppzmq
url = https://github.com/zeromq/cppzmq.git
[submodule "external/pybind11"]
path = external/pybind11
url = https://github.com/pybind/pybind11.git

View File

@@ -0,0 +1,70 @@
# Changelog
Changes and additions to OpenZen will be documented in this file.
## master
- added 16-bit data format parsing for IG1-protocol and unit tests for parsing code
- updated cereal to prevent CMake warning
- fixed sampling rate settings for IG1
- improved documentations and examples
- added configuration to hide private symbols from spdlog in the OpenZen shared file
## Version 1.2 - 2020/11/11
- This release breaks the ABI compatibitly with previous OpenZen releases. If you want to use this version of
OpenZen you have to recompile old projects with the C/C++ headers of this version.
- ZenEventType replaces the ZenSensorEvent, ZenImuEvent and ZenGnssEvent enums. Now the field ZenEvent::eventType
directly uses the ZenEventType and a comparison can be perfromed to check which type of event is provided:
```
if (event.eventType == ZenEventType_ImuData) {
// access event.data.imuData.g for gyro data
}
```
- ZenHeaveMotionData struct in ZenImuData has been replaced by the member heaveMotion.
- Gyroscope sensor data in ZenImuData.g and ZenImuData.gRaw will now be always in degrees/s and
the euler angles in ZenImuData.r will always be in degrees. Even if the hardware sensor (feature in IG1 firmware)
is set to output in radians, OpenZen will ensure the values are converted to degrees/s and degrees when
ouputting the values via the OpenZen API.
- added frameCount field to the ZenGnssData structure
- changed python bindings to a more convenient wrapper code
- updated documentation with supported sensor models and explanation on the sensor output values
- Properly handling a possible Bluetooth exception
- Improved stability on initial sensor connection
## Version 1.1.3 - 2020/09/03
- added support for IG1 RS485
- fixed bug with shutting down serial communication on Linux/Mac
- refactored sensor data parsing code
- added CMake unity build option for faster builds
- added feature to compore sensor handles in C++ API
- added support for 800 Hz IMU firmware
- fixed bug in computation of timestamp
- fixed typo in CAN Bus baudrate assignment
- fixed typo in CAN Bus baudrate assignment
- move binary and proprierary libraries to independent repository
and made the download optional
## Version 1.1.2 - 2020/06/04
- turn static linking on for ARM build
## Version 1.1.1 - 2020/06/04
- Added Python 3.8 for Windows release
- Improved documentation for Python support
- Added Python example script to the release build which works out-of-the box
## Version 1.1.0 - 2020/05/04
- Added C# and C++ example to the Window release
- Removed Qt Bluetooth and accessing Bluetooth API directly on Win/Linux/Mac
- Added Python API support and example
- Added support for MacOS
- Improved Copyright documentation
- Improved documentation
## Version 1.0.0 - 2020/02/10
- Initial Release of OpenZen

View File

@@ -0,0 +1,750 @@
cmake_minimum_required(VERSION 3.10)
if (APPLE)
# enable_language(OBJCXX) misidentifies .mm files as C++ when doing a Unity build,
# so we have to use this if().
project(OpenZen VERSION 1.0.0 LANGUAGES C;CXX;OBJCXX)
else()
project(OpenZen VERSION 1.0.0 LANGUAGES C;CXX)
endif()
option(ZEN_MSVC_RUNTIME_STATIC "Link the MSVC runtime statically, useful for library releases" OFF)
# Global compile options which also affect the externals
if (MSVC)
# make sure we link with the static runtime libraries
# and have no dependencies on VC++ studio DLLs during runtime
# We don't have any C++ exposed, so the C++ compatibility
# to the host program of the DLL is not required
# according to
# https://gitlab.kitware.com/cmake/community/-/wikis/FAQ#how-can-i-build-my-msvc-application-with-a-static-runtime
if (ZEN_MSVC_RUNTIME_STATIC)
foreach(flag_var
CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE
CMAKE_CXX_FLAGS_MINSIZEREL CMAKE_CXX_FLAGS_RELWITHDEBINFO)
if(${flag_var} MATCHES "/MD")
string(REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}")
endif(${flag_var} MATCHES "/MD")
endforeach(flag_var)
endif()
# select windows 7 as base version
# https://docs.microsoft.com/en-us/cpp/porting/modifying-winver-and-win32-winnt?view=vs-2019
add_definitions(-D_WIN32_WINNT=0x0601)
add_definitions(-D_WINVER=0x0601)
endif()
if (CMAKE_COMPILER_IS_GNUCC AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.0)
message(FATAL_ERROR "GCC Version 7.0 or newer is needed to compile OpenZen")
endif()
set (ZEN_BLUETOOTH_DEFAULT ON)
## check if libbluetooth is available on non-Apple Unix
if(UNIX AND NOT APPLE)
find_library(LIBBLUETOOTH_LIBRARY
NAMES bluetooth)
if (NOT LIBBLUETOOTH_LIBRARY)
set(ZEN_BLUETOOTH_DEFAULT OFF)
message("Please install libbluetooth-dev for bluetooth support")
if (ZEN_BLUETOOTH)
# give a fatal error message if Bluetooth support was requested
# by cmake parameters but we cannot fullfil it
message(FATAL_ERROR "libbluetooth-dev required to compile with Bluetooth support")
endif()
endif()
endif()
# Please note: The static OpenZen build does not support library installation (aka "make install")
# as the private dependencies cannot be resolved by CMake
# see https://gitlab.kitware.com/cmake/cmake/issues/17357 for example
option(ZEN_USE_STATIC_LIBS "Whether to compile OpenZen as a static library" OFF)
option(ZEN_STATIC_LINK_LIBCXX "Option to statically link libstdc++ to be portable to older systems (Linux only)" OFF)
# linux needs libbluetooth-dev to be able to compile, so disable it by default
option(ZEN_BLUETOOTH "Compile OpenZen with bluetooth support" ${ZEN_BLUETOOTH_DEFAULT})
option(ZEN_PCAN "Compile OpenZen Peak CAN USB adapter support" OFF)
option(ZEN_BLUETOOTH_BLE "Compile OpenZen with bluetooth low-energy support, needs Qt installed" OFF)
option(ZEN_NETWORK "Compile OpenZen with support for network streaming of measurement data" OFF)
option(ZEN_CSHARP "Compile C# bindings for OpenZen" ON)
option(ZEN_PYTHON "Compile Python bindings for OpenZen" OFF)
option(ZEN_TESTS "Compile with OpenZen tests" ON)
option(ZEN_EXAMPLES "Compile with OpenZen examples" ON)
option(ZEN_USE_BINARY_LIBRARIES "If set to true, binaries libraries are downloaded during the build" ON)
# This is used for automated tests. We use C++17, but when built as parts of other projects, cmake can
set(ZEN_INTERNAL_CXX_VERSION 17 CACHE STRING "For compatibility testing, specifies the C++ version to use for building the OpenZen library, doesn't affect its interface (which is always C). Needs at least 17, i.e. C++17")
# Enable this line and set it to the correct Qt installation path if you want to compile
# with bluetooth support on Windows
#set(CMAKE_PREFIX_PATH "C://Qt//5.12.3//msvc2017_64//")
#----------------------------------------------------------------
# Packages
#----------------------------------------------------------------
# Find includes in corresponding build include_directories
set(CMAKE_INCLUDE_CURRENT_DIR ON)
add_subdirectory(external)
# contains additional C/C++ precompiler defines
# which might be set depending on the selected compile options
set(zen_optional_compile_definitions_private)
set(zen_optional_compile_options)
set(zen_optional_libs)
# set the correct log level
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
# this will enable the SPDLOG_DEBUG macros for the build
list (APPEND zen_optional_compile_definitions_private
SPDLOG_ACTIVE_LEVEL=1
)
endif()
if (ZEN_BLUETOOTH_BLE)
# Instruct CMake to run moc automatically when needed
set(CMAKE_AUTOMOC ON)
find_package(Qt5Bluetooth REQUIRED)
endif()
set(zen_includes
include/OpenZen.h
include/OpenZenCAPI.h
include/ZenTypes.h
)
set(zen_sources
src/InternalTypes.h
src/ISensorProperties.cpp
src/ISensorProperties.h
src/OpenZen.cpp
src/Sensor.cpp
src/Sensor.h
src/SensorClient.cpp
src/SensorClient.h
src/SensorConfig.h
src/SensorComponent.h
src/SensorManager.cpp
src/SensorManager.h
src/SensorProperties.cpp
src/SensorProperties.h
src/LpMatrix.cpp
src/LpMatrix.h
)
# source files which only get compiled into the
# library and not into the unit tests
set(zen_library_only_sources)
if(ZEN_PYTHON)
list (APPEND zen_library_only_sources
src/bindings/OpenZenPython.cpp
)
list (APPEND zen_optional_libs pybind11)
endif()
if(ZEN_CSHARP)
if(CMAKE_SIZEOF_VOID_P EQUAL 8) # 64-bit
set(SWIG_FLAGS "-DSWIGWORDSIZE64")
else() # 32-bit
set(SWIG_FLAGS "-DSWIGWORDSIZE32")
endif()
list (APPEND zen_sources
## run
# swig -csharp -small -c++ -debug-typedef -DSWIGWORDSIZE64 -o OpenZenCSharp/OpenZen_wrap_csharp.cxx -outdir OpenZenCSharp OpenZen.i
# in the bindings folder to generate
bindings/OpenZenCSharp/OpenZen_wrap_csharp.cxx
)
endif()
set(zen_optional_test_sources)
set(processors_sources
src/processors/DataProcessor.h
)
set(communication_sources
src/communication/ConnectionNegotiator.cpp
src/communication/ConnectionNegotiator.h
src/communication/Modbus.cpp
src/communication/Modbus.h
src/communication/ModbusCommunicator.cpp
src/communication/ModbusCommunicator.h
src/communication/SyncedModbusCommunicator.cpp
src/communication/SyncedModbusCommunicator.h
)
set(components_sources
src/components/ComponentFactoryManager.cpp
src/components/ComponentFactoryManager.h
src/components/IComponentFactory.h
src/components/ImuComponent.cpp
src/components/ImuComponent.h
src/components/ImuIg1Component.cpp
src/components/ImuIg1Component.h
src/components/GnssComponent.cpp
src/components/GnssComponent.h
src/components/SensorParsingUtil.h
)
set(components_factories_sources
src/components/factories/ImuComponentFactory.cpp
src/components/factories/ImuComponentFactory.h
src/components/factories/GnssComponentFactory.cpp
src/components/factories/GnssComponentFactory.h
)
set(io_sources
src/io/IIoInterface.h
src/io/IIoSystem.h
src/io/IoManager.cpp
src/io/IoManager.h
)
set(io_interfaces_sources
src/io/interfaces/TestSensorInterface.cpp
src/io/interfaces/TestSensorInterface.h
)
set(io_systems_sources
src/io/systems/TestSensorSystem.cpp
src/io/systems/TestSensorSystem.h
)
set(properties_sources
src/properties/BaseSensorPropertiesV0.h
src/properties/BaseSensorPropertiesV1.h
src/properties/CorePropertyRulesV1.h
src/properties/ImuPropertyRulesV1.h
src/properties/ImuPropertyRulesV2.h
src/properties/ImuSensorPropertiesV0.h
src/properties/ImuSensorPropertiesV1.h
src/properties/LegacyCoreProperties.cpp
src/properties/LegacyCoreProperties.h
src/properties/Ig1CoreProperties.cpp
src/properties/Ig1CoreProperties.h
src/properties/LegacyImuProperties.cpp
src/properties/LegacyImuProperties.h
src/properties/Ig1ImuProperties.cpp
src/properties/Ig1ImuProperties.h
src/properties/Ig1GnssProperties.cpp
src/properties/Ig1GnssProperties.h
)
set(utility_sources
src/utility/Finally.h
src/utility/IPlatformDll.h
src/utility/LockingQueue.h
src/utility/Ownership.h
src/utility/ReferenceCmp.h
src/utility/StringView.h
src/utility/ThreadFence.h
src/utility/gnss/RTCM3NetworkSource.h
src/utility/gnss/RTCM3NetworkSource.cpp
src/utility/gnss/RTCM3SerialSource.h
src/utility/gnss/RTCM3SerialSource.cpp
src/utility/gnss/RTCM3Parser.h
)
if(ZEN_PCAN)
set(io_can_sources
src/io/can/CanManager.cpp
src/io/can/CanManager.h
src/io/can/ICanChannel.h
)
set(io_interfaces_sources
src/io/interfaces/CanInterface.cpp
src/io/interfaces/CanInterface.h
)
endif()
if(ZEN_BLUETOOTH_BLE)
set(io_ble_sources
src/io/ble/BleDeviceFinder.cpp
src/io/ble/BleDeviceFinder.h
src/io/ble/BleDeviceHandler.cpp
src/io/ble/BleDeviceHandler.h
)
list (APPEND io_systems_sources
src/io/systems/BleSystem.cpp
src/io/systems/BleSystem.h
)
list (APPEND io_interfaces_sources
src/io/interfaces/BleInterface.cpp
src/io/interfaces/BleInterface.h
)
list (APPEND zen_optional_libs
Qt5::Bluetooth
)
list (APPEND zen_optional_compile_definitions_private
ZEN_BLUETOOTH_BLE
)
endif()
if(ZEN_BLUETOOTH)
set(io_bluetooth_sources
src/utility/bluetooth-serial-port/BluetoothException.h
src/utility/bluetooth-serial-port/BTSerialPortBinding.h
src/utility/bluetooth-serial-port/DeviceINQ.h
src/utility/bluetooth-serial-port/Enums.h
src/utility/bluetooth-serial-port/Enums.cc
src/io/bluetooth/BluetoothDeviceFinder.cpp
src/io/bluetooth/BluetoothDeviceFinder.h
src/io/bluetooth/BluetoothDeviceHandler.cpp
src/io/bluetooth/BluetoothDeviceHandler.h
)
if(WIN32) # windows
list (APPEND io_bluetooth_sources
src/utility/bluetooth-serial-port/windows/BluetoothHelpers.cc
src/utility/bluetooth-serial-port/windows/BTSerialPortBinding.cc
src/utility/bluetooth-serial-port/windows/DeviceINQ.cc
)
list (APPEND zen_optional_libs
ws2_32
bthprops
)
elseif(APPLE) # MacOSX
list (APPEND io_bluetooth_sources
src/utility/bluetooth-serial-port/osx/BluetoothDeviceResources.mm
src/utility/bluetooth-serial-port/osx/BluetoothWorker.mm
src/utility/bluetooth-serial-port/osx/BTSerialPortBinding.mm
src/utility/bluetooth-serial-port/osx/DeviceINQ.mm
src/utility/bluetooth-serial-port/osx/pipe.c
)
find_library(FOUNDATION Foundation)
find_library(IOBLUETOOTH IOBluetooth)
list (APPEND zen_optional_libs
${FOUNDATION}
${IOBLUETOOTH}
-fobjc-arc
)
add_executable(btScan src/utility/bluetooth-serial-port/osx/btScan.mm)
target_link_libraries(btScan ${FOUNDATION} ${IOBLUETOOTH})
# Use a non-ancient C++ version for compilation ...
target_compile_features(btScan PRIVATE cxx_variadic_templates)
else() # Linux
list (APPEND io_bluetooth_sources
src/utility/bluetooth-serial-port/linux/BTSerialPortBinding.cc
src/utility/bluetooth-serial-port/linux/DeviceINQ.cc
)
list (APPEND zen_optional_libs
bluetooth
)
endif()
list (APPEND io_systems_sources
src/io/systems/BluetoothSystem.cpp
src/io/systems/BluetoothSystem.h
)
list (APPEND io_interfaces_sources
src/io/interfaces/BluetoothInterface.cpp
src/io/interfaces/BluetoothInterface.h
)
list (APPEND zen_optional_compile_definitions_private
ZEN_BLUETOOTH
)
endif()
if(ZEN_NETWORK)
set(io_zeromq_sources
src/io/interfaces/ZeroMQInterface.h
src/io/interfaces/ZeroMQInterface.cpp
)
list (APPEND io_systems_sources
src/io/systems/ZeroMQSystem.h
src/io/systems/ZeroMQSystem.cpp
)
list (APPEND zen_optional_test_sources
src/test/streaming/ZeroMQStreamingTest.cpp
)
list (APPEND processors_sources
src/processors/ZmqDataProcessor.h
src/processors/ZmqDataProcessor.cpp
)
list (APPEND zen_optional_libs
libzmq-static
cppzmq
)
list (APPEND zen_optional_compile_definitions_private
ZEN_NETWORK
)
else()
set(io_zeromq_sources)
endif()
if(WIN32)
set(io_interfaces_sources ${io_interfaces_sources}
src/io/interfaces/windows/WindowsDeviceInterface.cpp
src/io/interfaces/windows/WindowsDeviceInterface.h
)
set(io_systems_sources ${io_systems_sources}
src/io/systems/windows/EnumerateSerialPorts.cpp
src/io/systems/windows/EnumerateSerialPorts.h
src/io/systems/windows/WindowsDeviceSystem.cpp
src/io/systems/windows/WindowsDeviceSystem.h
)
set(utility_sources ${utility_sources}
src/utility/windows/FindThisModule.cpp
src/utility/windows/FindThisModule.h
src/utility/windows/WindowsDll.cpp
src/utility/windows/WindowsDll.h
)
# add drivers which need binary libraries
if (ZEN_USE_BINARY_LIBRARIES)
if(ZEN_PCAN)
list(APPEND io_can_sources
src/io/can/PcanBasicChannel.cpp
src/io/can/PcanBasicChannel.h
)
list (APPEND io_systems_sources
src/io/systems/PcanBasicSystem.cpp
src/io/systems/PcanBasicSystem.h
)
endif()
list (APPEND io_interfaces_sources
src/io/interfaces/SiUsbInterface.cpp
src/io/interfaces/SiUsbInterface.h
src/io/interfaces/FtdiUsbInterface.cpp
src/io/interfaces/FtdiUsbInterface.h
)
list (APPEND io_systems_sources
src/io/systems/SiUsbSystem.cpp
src/io/systems/SiUsbSystem.h
src/io/systems/FtdiUsbSystem.cpp
src/io/systems/FtdiUsbSystem.h
)
list (APPEND zen_optional_compile_definitions_private
ZEN_USE_BINARY_LIBRARIES
)
endif()
elseif(UNIX AND NOT APPLE)
set(io_interfaces_sources ${io_interfaces_sources}
src/io/interfaces/posix/PosixDeviceInterface.cpp
src/io/interfaces/posix/PosixDeviceInterface.h
)
set(io_systems_sources ${io_systems_sources}
src/io/systems/linux/LinuxDeviceSystem.cpp
src/io/systems/linux/LinuxDeviceSystem.h
)
set(utility_sources ${utility_sources}
src/utility/posix/PosixDll.cpp
src/utility/posix/PosixDll.h
)
elseif(APPLE)
set(io_interfaces_sources ${io_interfaces_sources}
src/io/interfaces/posix/PosixDeviceInterface.cpp
src/io/interfaces/posix/PosixDeviceInterface.h
)
set(io_systems_sources ${io_systems_sources}
src/io/systems/mac/MacDeviceSystem.cpp
src/io/systems/mac/MacDeviceSystem.h
)
set(utility_sources ${utility_sources}
src/utility/posix/PosixDll.cpp
src/utility/posix/PosixDll.h
)
else()
message(FATAL_ERROR "OS not supported.")
endif()
set(zen_all_sources
${zen_includes}
${zen_sources}
${processors_sources}
${communication_sources}
${components_sources}
${components_factories_sources}
${io_sources}
${io_ble_sources}
${io_bluetooth_sources}
${io_zeromq_sources}
${io_can_sources}
${io_interfaces_sources}
${io_systems_sources}
${properties_sources}
${utility_sources}
)
if(ZEN_USE_STATIC_LIBS)
add_library(OpenZen STATIC ${zen_all_sources} ${zen_library_only_sources})
else()
add_library(OpenZen SHARED ${zen_all_sources} ${zen_library_only_sources})
# hide all non-exported symbols in the build
set_target_properties(OpenZen PROPERTIES CXX_VISIBILITY_PRESET hidden)
set_target_properties(OpenZen PROPERTIES VISIBILITY_INLINES_HIDDEN ON)
# this is not done for libzmq now, because it uses an old CMake policy
# which cannot be changed for subdirectories, so ZMQ symbols will be
# public (CMP0063)
endif()
target_compile_definitions(OpenZen
PRIVATE
${zen_optional_compile_definitions_private}
)
# publish the static usage flag of OpenZen to all libraries linking to us
if (ZEN_USE_STATIC_LIBS)
target_compile_definitions(OpenZen PUBLIC ZEN_API_STATIC)
else()
target_compile_definitions(OpenZen PRIVATE ZEN_API_EXPORT)
endif()
target_compile_features(OpenZen
PRIVATE
"cxx_std_${ZEN_INTERNAL_CXX_VERSION}"
)
set_property(TARGET OpenZen PROPERTY CXX_EXTENSIONS FALSE)
if (NOT MSVC)
list (APPEND zen_optional_compile_options
-Wall -Wextra -pedantic
)
# add linker options to statically compile in libstdc++
# this makes the library portable to older Linux versions
if (ZEN_STATIC_LINK_LIBCXX)
list (APPEND zen_optional_libs
-static-libstdc++
-static-libgcc
)
endif()
endif()
# manage compile options for the targets
if (CMAKE_COMPILER_IS_GNUCC)
# this warning is unreliable accross GCC releases
# https://gcc.gnu.org/pipermail/gcc-bugs/2019-January/648130.html
list (APPEND zen_optional_compile_options
-Wno-redundant-move
)
endif()
target_compile_options(OpenZen
PRIVATE
${zen_optional_compile_options})
set(zen_include_dirs_public
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:include>
)
set(zen_include_dirs_private
${CMAKE_CURRENT_SOURCE_DIR}/src
$<TARGET_PROPERTY:GSL,INTERFACE_INCLUDE_DIRECTORIES>
$<TARGET_PROPERTY:openzen_asio,INTERFACE_INCLUDE_DIRECTORIES>
$<TARGET_PROPERTY:cereal,INTERFACE_INCLUDE_DIRECTORIES>
$<TARGET_PROPERTY:nonstd::expected-lite,INTERFACE_INCLUDE_DIRECTORIES>
)
if (ZEN_USE_BINARY_LIBRARIES)
set(zen_include_dirs_private ${zen_include_dirs_private}
$<$<PLATFORM_ID:Windows>:$<TARGET_PROPERTY:pcanbasic,INTERFACE_INCLUDE_DIRECTORIES>>
$<$<PLATFORM_ID:Windows>:$<TARGET_PROPERTY:siusb,INTERFACE_INCLUDE_DIRECTORIES>>
$<$<PLATFORM_ID:Windows>:$<TARGET_PROPERTY:ftdi,INTERFACE_INCLUDE_DIRECTORIES>>
)
endif()
target_include_directories(OpenZen
PUBLIC
${zen_include_dirs_public}
PRIVATE
${zen_include_dirs_private}
)
include(FindThreads)
set (zen_libs
$<$<PLATFORM_ID:Linux>:atomic>
$<$<PLATFORM_ID:Linux>:dl>
$<$<PLATFORM_ID:Linux>:rt>
$<$<PLATFORM_ID:Linux>:stdc++fs>
Threads::Threads
spdlog
${zen_optional_libs}
)
target_link_libraries(OpenZen
PRIVATE
${zen_libs}
)
if (ZEN_PYTHON)
if(WIN32)
# copy file to be used as python module in Windows
add_custom_command(TARGET OpenZen POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:OpenZen> ${CMAKE_CURRENT_BINARY_DIR}/openzen.pyd
)
endif()
if(UNIX)
# copy file to be used as python module in Linux/Mac
add_custom_command(TARGET OpenZen POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:OpenZen> ${CMAKE_CURRENT_BINARY_DIR}/openzen.so
)
endif()
endif()
if (ZEN_TESTS)
# Unit test binary for OpenZen
#
# This will build the OpenZen source files into a binary
# and compile the unit test code. The DLL version of OpenZen cannot be used
# because the most of the symbols we want to test are not visible with the
# Windows DLL default visibility.
add_executable(OpenZenTests
${zen_all_sources}
${zen_optional_test_sources}
src/test/ModbusTest.cpp
src/test/communication/ConnectionNegotiatorTest.cpp
src/test/components/GnssComponentTest.cpp
src/test/components/ImuIg1ComponentTest.cpp
src/test/streaming/SerializationTest.cpp
src/test/OpenZenTests.cpp)
target_include_directories(OpenZenTests
PUBLIC
${zen_include_dirs_public}
PRIVATE
${zen_include_dirs_private}
)
target_link_libraries(OpenZenTests
PRIVATE
gtest
${zen_libs}
)
target_compile_features(OpenZenTests
PRIVATE
cxx_std_17
)
# always compile the unit test binary without any function exports
target_compile_definitions(OpenZenTests
PRIVATE
ZEN_API_STATIC
${zen_optional_compile_definitions_private}
)
target_compile_options(OpenZenTests
PRIVATE
${zen_optional_compile_options})
endif()
if (ZEN_EXAMPLES)
# build example code
add_subdirectory(examples)
endif()
# configuration for CMake package installation
set_property(TARGET OpenZen PROPERTY PUBLIC_HEADER
include/OpenZen.h
include/OpenZenCAPI.h
include/ZenTypes.h
)
install(TARGETS OpenZen EXPORT OpenZenTarget
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib
RUNTIME DESTINATION bin
PUBLIC_HEADER DESTINATION include
)
find_package(spdlog REQUIRED)
# even private static targts need to be exported to justify the
# dependencies for static builds.
# see https://gitlab.kitware.com/cmake/cmake/-/issues/17357
if (ZEN_USE_STATIC_LIBS)
if (ZEN_PYTHON)
install(TARGETS pybind11 EXPORT OpenZenTarget)
endif()
if (ZEN_NETWORK)
install(TARGETS cppzmq EXPORT OpenZenTarget)
endif()
endif()
if(WIN32 AND ZEN_USE_BINARY_LIBRARIES)
get_target_property(FTDI_DLL ftdi IMPORTED_LOCATION)
get_target_property(SIUSB_DLL siusb IMPORTED_LOCATION)
get_target_property(PCANBASIC_DLL pcanbasic IMPORTED_LOCATION)
install(FILES ${FTDI_DLL} ${SIUSB_DLL} ${PCANBASIC_DLL} DESTINATION bin)
endif()
include(CMakePackageConfigHelpers)
write_basic_package_version_file(
"${CMAKE_CURRENT_BINARY_DIR}/OpenZenConfigVersion.cmake"
VERSION ${OpenZen_VERSION}
COMPATIBILITY AnyNewerVersion
)
export(EXPORT OpenZenTarget
FILE "${CMAKE_CURRENT_BINARY_DIR}/OpenZenConfigTargets.cmake"
NAMESPACE OpenZen::
)
configure_file(cmake/OpenZenConfig.cmake
"${CMAKE_CURRENT_BINARY_DIR}/OpenZenConfig.cmake"
COPYONLY
)
set(ConfigPackageLocation lib/cmake/OpenZen)
install(EXPORT OpenZenTarget
FILE
OpenZenTargets.cmake
NAMESPACE
OpenZen::
DESTINATION
${ConfigPackageLocation}
)
install(
FILES
cmake/OpenZenConfig.cmake
"${CMAKE_CURRENT_BINARY_DIR}/OpenZenConfigVersion.cmake"
DESTINATION
${ConfigPackageLocation}
COMPONENT
Devel
)

777
openzen_dev/openzen/LICENSE Normal file
View File

@@ -0,0 +1,777 @@
Copyright 2019 LP-Research Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
associated documentation files (the "Software"), to deal in the Software without restriction,
including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the Software is furnished to
do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or
substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
This software uses the following external libraries:
============================================================================
Qt5 (https://www.qt.io/) uses the GNU LESSER GENERAL PUBLIC LICENSE license:
============================================================================
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
===========================================================================
ASIO Library (https://think-async.com/Asio/)
Boost Software License - Version 1.0 - August 17th, 2003
===========================================================================
Permission is hereby granted, free of charge, to any person or organization
obtaining a copy of the software and accompanying documentation covered by
this license (the "Software") to use, reproduce, display, distribute,
execute, and transmit the Software, and to prepare derivative works of the
Software, and to permit third-parties to whom the Software is furnished to
do so, all subject to the following:
The copyright notices in the Software and this entire statement, including
the above license grant, this restriction and the following disclaimer,
must be included in all copies of the Software, in whole or in part, and
all derivative works of the Software, unless such copies or derivative
works are solely in the form of machine-executable object code generated by
a source language processor.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
============================================================================
Cereal (https://uscilab.github.io/cereal/)
3-Clause BSD License
============================================================================
Copyright (c) 2014, Randolph Voorhies, Shane Grant
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
* Neither the name of cereal nor the
names of its contributors may be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL RANDOLPH VOORHIES OR SHANE GRANT BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
===============================================================================
cppzmq (https://github.com/zeromq/cppzmq)
MIT License
===============================================================================
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.
===============================================================================
expected-lite (https://github.com/martinmoene/expected-lite)
Boost Software License - Version 1.0 - August 17th, 2003
===============================================================================
Permission is hereby granted, free of charge, to any person or organization
obtaining a copy of the software and accompanying documentation covered by
this license (the "Software") to use, reproduce, display, distribute,
execute, and transmit the Software, and to prepare derivative works of the
Software, and to permit third-parties to whom the Software is furnished to
do so, all subject to the following:
The copyright notices in the Software and this entire statement, including
the above license grant, this restriction and the following disclaimer,
must be included in all copies of the Software, in whole or in part, and
all derivative works of the Software, unless such copies or derivative
works are solely in the form of machine-executable object code generated by
a source language processor.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
===============================================================================
fmt (https://github.com/fmtlib/fmt)
===============================================================================
Copyright (c) 2012 - present, Victor Zverovich
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
===============================================================================
Google Test (https://github.com/google/googletest)
BSD 3-Clause "New" or "Revised" License
===============================================================================
Copyright 2008, Google Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following disclaimer
in the documentation and/or other materials provided with the
distribution.
* Neither the name of Google Inc. nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
==============================================================================
GSL (https://github.com/microsoft/GSL)
MIT License
==============================================================================
Copyright (c) 2015 Microsoft Corporation. All rights reserved.
This code is licensed under the MIT License (MIT).
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
==============================================================================
libzmq (https://github.com/zeromq/libzmq)
GNU Lesser General Public License (LGPL) Version 3
==============================================================================
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
--------------------------------------------------------------------------------
SPECIAL EXCEPTION GRANTED BY COPYRIGHT HOLDERS
As a special exception, copyright holders give you permission to link this
library with independent modules to produce an executable, regardless of
the license terms of these independent modules, and to copy and distribute
the resulting executable under terms of your choice, provided that you also
meet, for each linked independent module, the terms and conditions of
the license of that module. An independent module is a module which is not
derived from or based on this library. If you modify this library, you must
extend this exception to your version of the library.
Note: this exception relieves you of any obligations under sections 4 and 5
of this license, and section 6 of the GNU General Public License.
==============================================================================
JSON for Modern C++ (https://github.com/nlohmann/json)
MIT License
==============================================================================
Copyright (c) 2013-2018 Niels Lohmann
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
spdlog (https://github.com/gabime/spdlog)
The MIT License (MIT)
Copyright (c) 2016 Gabi Melman.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
==============================================================================
Bluetooth serial port communication for Node.js
(https://github.com/Agamnentzar/bluetooth-serial-port)
BSD-2 Clause License
==============================================================================
Copyright (c) 2014, Agamnentzar
Copyright (c) 2012-2013, Eelco Cramer
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Other licenses used are:
* [pipe.c](https://github.com/wowus/pipe) - MIT License
* [pipe.h](https://github.com/wowus/pipe) - MIT License
==============================================================================
pybind11
(https://github.com/pybind/pybind11)
BSD style license
==============================================================================
Copyright (c) 2016 Wenzel Jakob <wenzel.jakob@epfl.ch>, All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of the copyright holder nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Please also refer to the file .github/CONTRIBUTING.md, which clarifies licensing of
external contributions to this project including patches, pull requests, etc.
=======
#######################
Optional Compoments
#######################
If OpenZen is compiled with the flag ZEN_USE_BINARY_LIBRARIES=ON, the following
libraries are downloaded from the external repository
https://bitbucket.org/lpresearch/openzenbinarylibraries
and copied to the build folder.
==============================================================================
FTDI Driver
Custom license which allows distribution for usage with FTDI hardware components
==============================================================================
Driver Licence Terms
The software you can download from this web site ("the Software") is provided by Future Technology
Devices International Limited ("FTDI") subject to the licence terms set out at
http://www.ftdichip.com/FTDriverLicenceTerms.htm ("the Licence Terms"). You must read the
Licence Terms before downloading the Software. By installing or using the Software you agree
to the Licence Terms. If you do not agree to the Licence Terms then do not download or use the
Software.
Without prejudice to the Licence Terms, here is a summary of some of the key terms of the Licence
Terms (and in the event of any conflict between this summary and the Licence Terms then the text
of the Licence Terms will prevail).
The licence only allows use of the Software with, and the Software will only work with Genuine FTDI
Components (as defined in the Licence Terms). Use of the Software as a driver for a component that
is not a Genuine FTDI Component MAY IRRETRIEVABLY DAMAGE THAT COMPONENT. It is your responsibility
to make sure that all chips you use the Software as a driver for are Genuine FTDI Components. If in
doubt then contact FTDI. The Software is provided "as is''.
There are no warranties (or similar) in relation to the quality of the Software. There are exclusions
of FTDI liability for certain types of loss such as: special loss or damage; incidental loss or damage;
indirect or consequential loss or damage; loss of income; loss of business; loss of profits; loss of
revenue; loss of contracts; business interruption; loss of the use of money or anticipated savings;
loss of information; loss of opportunity; loss of goodwill or reputation; and/or loss of, damage to
or corruption of data. There is a monetary cap on FTDI's liability. If a custom vendor ID and/or
product ID or description string are used, it is the responsibility of the product manufacturer to
maintain any changes and subsequent WHQL re-certification as a result of making these changes.
==============================================================================
PEAK PCAN API
Custom license which allows distribution for usage with PEAK-System hardware components
==============================================================================
Please read the End User License Agreement of the company PEAK-System Technik GmbH at:
https://www.peak-system.com/quick/eula
PEAK-System Technik GmbH grants the right to the customer to use the files in
this software package as long as this is done in connection with original
hardware by PEAK-System or OEM hardware coming from PEAK-System. It is NOT
allowed to use any of these files (even not parts) with third-party hardware.
If you are not sure whether you have acquired an appropriate license with the
used hardware, please contact our technical support team (support@peak-system.com).
==============================================================================
SiLas USB Express driver
This driver is covered by the SiLabs Royalty-free distribution license according to
https://www.silabs.com/documents/public/data-sheets/CP2102-9.pdf

View File

@@ -0,0 +1,127 @@
# OpenZen
High performance sensor data streaming and processing
## [Full documentation here](https://lp-research.atlassian.net/wiki/spaces/LKB/pages/2005630977/OpenZen+Documentations)
![OpenZen Unity plugin connected to a LPMS-CU2 sensor and live visualization of sensor orientation](https://lpresearch.bitbucket.io/openzen_resources/OpenZenUnityDemo.gif)
OpenZen Unity plugin connected to a LPMS-CU2 sensor and live visualization of sensor orientation.
## Overview
OpenZen is a framework that allows access to Sensor Hardware from multiple vendors without requiring understanding of the target hardware or communication layer by providing a homogeneous API to application developers and a communication protocol to hardware developers.
Currently, OpenZen has full support for communication over Bluetooth and USB (using the Silabs driver), as well as support for Bluetooth Low-Energy, CAN (using the PCAN Basic driver) and USB (using the Ftdi driver). At the moment OpenZen has only been used with IMU and GPS sensors, but is easily extensible to any type of sensor or range of properties.
Where possible we favour open standards, but as OpenZen finds its origin in [OpenMAT](https://bitbucket.org/lpresearch/openmat-2-os/) it needs to provide backwards compatibility for all sensors that originally worked with its *LpSensor* library. As such, OpenZen still contains some custom protocols which will be phased out over time. Legacy protocols are generally referred to with the v0 indicator.
You can find the full documentation for OpenZen here: <https://lpresearch.bitbucket.io/openzen/>
## Download Pre-Compiled Library
You can download the newest pre-compiled version of OpenZen for your platform here:
<https://bitbucket.org/lpresearch/openzen/downloads/>
At this time, we provide a binary release for
- Windows x64-bit (support CSharp, Python and Bluetooth),
- Ubuntu 16.04 (and newer) x64-bit,
- ARM64-bit.
Please contact us, if you need a binary release for a platform that is not provided yet.
## Build OpenZen from Source
OpenZen uses CMake (3.11 or higher) as build system, and has been built and tested on Windows (Microsoft Visual Studio 2017 and 2019) and Ubuntu (gcc7). As OpenZen is written in C++17, an up-to-date compiler is required. The following steps guide you through setting up OpenZen in Windows and Linux.
### Windows
1. Install MSVC build tools, or the Visual Studio IDE (requires C++17 support)
2. Install CMake, or a GUI (e.g. Visual Studio) that incorporates CMake
3. Clone the OpenZen repository: `git clone --recurse-submodules https://bitbucket.org/lpresearch/openzen.git`
Now you can open and compile OpenZen with Visual Studio. When starting Visual Studio, use the top menu and do File -> Open -> Folder... and select the OpenZen directory.
### Linux
1. Install gcc7 (requires C++17 support) or newer: `sudo apt-get install gcc-7`
2. Install CMake (requires version 3.11 or newer)
3. Clone the OpenZen repository: `git clone --recurse-submodules https://bitbucket.org/lpresearch/openzen.git`
4. (for Linux) Install additional libraries depending on your use case. More [details](https://lpresearch.bitbucket.io/openzen/latest/setup.html#linux).
5. Create a build folder and run cmake:
```
cd openzen
mkdir build && cd build
cmake ..
```
6. Compile and run the *OpenZenExample*:
```
make -j4
examples/OpenZenExample
```
An example of how to use the OpenZen API is included with the repository. If you are looking for more information on how to use the API, visit the documentation on the [Wiki](https://lpresearch.bitbucket.io/openzen/latest/getting_started.html).
## Available Build Options
These build options can be supplied to the cmake command to customize your OpenZen build. For example
```
cmake -DZEN_BLUETOOTH=OFF -DZEN_PYTHON=ON ..
```
| Name | Default | Description |
|------------------------|---------|---------------------------------------------------------------------------------|
| ZEN_USE_STATIC_LIBS | OFF | Compile OpenZen as a static library |
| ZEN_STATIC_LINK_LIBCXX | OFF | Option to statically link libstdc++ to be portable to older systems (Linux only)|
| ZEN_BLUETOOTH | ON | Compile with bluetooth support ([details](https://lpresearch.bitbucket.io/openzen/latest/setup.html#linux)) |
| ZEN_BLUETOOTH_BLE | OFF | Compile with bluetooth low-energy support, needs Qt installed ([details](https://lpresearch.bitbucket.io/openzen/latest/setup.html#linux)) |
| ZEN_NETWORK | OFF | Compile with support for network streaming of measurement data |
| ZEN_CSHARP | ON | Compile C# bindings for OpenZen |
| ZEN_PYTHON | OFF | Compile Python bindings for OpenZen |
| ZEN_TESTS | ON | Compile with OpenZen tests |
| ZEN_EXAMPLES | ON | Compile with OpenZen examples |
**Note:** The existing C# binding is for 64-bit machine. If you wish to run our sample C# project on a 32-bit machine, please execute the following code in the `bindings` folder BEFORE building OpenZen:
```
swig -csharp -small -c++ -debug-typedef -DSWIGWORDSIZE32 -o OpenZenCSharp/OpenZen_wrap_csharp.cxx -outdir OpenZenCSharp OpenZen.i
```
## Deployment
If you want to compile OpenZen and use the binary library on other systems, you can use CMake for that too. To build a standlone version of OpenZen, you can use the following command:
```
cmake -DCMAKE_BUILD_TYPE=Release -DZEN_STATIC_LINK_LIBCXX=On -DZEN_BLUETOOTH=OFF -DCMAKE_INSTALL_PREFIX=../OpenZenRelease/ ..
make -j4 install
```
This will compile OpenZen without Bluetooth support (if you don't need it). Furthermore, it will statically link libstdc++ which increase the size of the library bigger but makes it more portable.
After calling `make install`, the folder `OpenZenRelease` will contain the binary library, the required interface header files and CMake configuration file to easily integrate the library into your project.
Please see this [CMake file](https://bitbucket.org/lpresearch/openzen/src/master/standalone_example/CMakeLists.txt) for an example how to use OpenZen as an external, binary-only package in your build.
## Note on Licensing
OpenZen is licensed under a simple MIT-type license and thus is free to use and modify for all purposes. Please be aware
that OpenZen relies on the Qt library for Bluetooth BLE functionality and thus Qt's license conditions may apply to the resulting
binary.
## Contributing
We welcome any contributions to OpenZen through pull requests. The most up-to-date builds are on the Master branch, so we prefer to take pull requests there. There is no official coding standard, but we ask you to at least adhere to the following guidelines:
* Use spaces instead of tabs
* Put braces on a new line
* Use upper camel case for class names: `FooBar`
* Use camel case for function names: `fooBar()`
* Use camel case for variable names: `fooBar`
* Prepend `m_` to member variables: `m_fooBar`
* Prepend `g_` to global variables: `g_fooBar`
In general, we ask you to prefer legible code with descriptive variable names over comments, but to not shy away from using commands where necessary. Apart from this you are free to write code the way you like it. It is however left to the code reviewers judgement whether your pull request complies with the standards of OpenZen.
Currently, OpenZen is required to be compileable on Ubuntu 18.04 (CMake 3.10 and GCC 7.4.0) and Microsoft Visual Studio 2017. So don't introduce any
C++ or CMake features which are not supported by these build tools.

View File

@@ -0,0 +1,11 @@
#!/bin/bash
for i in $(find src/ -name "*.h" -or -name "*.cpp")
do
if ! grep -q Copyright $i
then
echo "Will add copyright notice to $i"
cat license_header.txt $i >$i.new && mv $i.new $i
fi
done

View File

@@ -0,0 +1,18 @@
%include "carrays.i"
// generate the helper class to convert float c arrays (which are treated as float *)
// to proper arrays
// run
// swig.exe -csharp -small -c++ -debug-typedef -DSWIGWORDSIZE64 -o OpenZenCSharp/OpenZen_wrap_csharp.cxx -outdir OpenZenCSharp OpenZen.i
// to export for Csharp
%array_class(float, OpenZenFloatArray);
%include "stdint.i"
%module OpenZen
%{
#include "../include/ZenTypes.h"
#include "../include/OpenZenCAPI.h"
%}
%include "../include/ZenTypes.h"
%include "../include/OpenZenCAPI.h"

View File

@@ -0,0 +1,59 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum EZenGnssProperty {
ZenGnssProperty_Invalid = 0,
ZenGnssProperty_OutputNavPvtiTOW,
ZenGnssProperty_OutputNavPvtYear,
ZenGnssProperty_OutputNavPvtMonth,
ZenGnssProperty_OutputNavPvtDay,
ZenGnssProperty_OutputNavPvtHour,
ZenGnssProperty_OutputNavPvtMinute,
ZenGnssProperty_OutputNavPvtSecond,
ZenGnssProperty_OutputNavPvtValid,
ZenGnssProperty_OutputNavPvttAcc,
ZenGnssProperty_OutputNavPvtNano,
ZenGnssProperty_OutputNavPvtFixType,
ZenGnssProperty_OutputNavPvtFlags,
ZenGnssProperty_OutputNavPvtFlags2,
ZenGnssProperty_OutputNavPvtNumSV,
ZenGnssProperty_OutputNavPvtLongitude,
ZenGnssProperty_OutputNavPvtLatitude,
ZenGnssProperty_OutputNavPvtHeight,
ZenGnssProperty_OutputNavPvthMSL,
ZenGnssProperty_OutputNavPvthAcc,
ZenGnssProperty_OutputNavPvtvAcc,
ZenGnssProperty_OutputNavPvtVelN,
ZenGnssProperty_OutputNavPvtVelE,
ZenGnssProperty_OutputNavPvtVelD,
ZenGnssProperty_OutputNavPvtgSpeed,
ZenGnssProperty_OutputNavPvtHeadMot,
ZenGnssProperty_OutputNavPvtsAcc,
ZenGnssProperty_OutputNavPvtHeadAcc,
ZenGnssProperty_OutputNavPvtpDOP,
ZenGnssProperty_OutputNavPvtHeadVeh,
ZenGnssProperty_OutputNavAttiTOW,
ZenGnssProperty_OutputNavAttVersion,
ZenGnssProperty_OutputNavAttRoll,
ZenGnssProperty_OutputNavAttPitch,
ZenGnssProperty_OutputNavAttHeading,
ZenGnssProperty_OutputNavAttAccRoll,
ZenGnssProperty_OutputNavAttAccPitch,
ZenGnssProperty_OutputNavAttAccHeading,
ZenGnssProperty_OutputEsfStatusiTOW,
ZenGnssProperty_OutputEsfStatusVersion,
ZenGnssProperty_OutputEsfStatusInitStatus1,
ZenGnssProperty_OutputEsfStatusInitStatus2,
ZenGnssProperty_OutputEsfStatusFusionMode,
ZenGnssProperty_OutputEsfStatusNumSens,
ZenGnssProperty_OutputEsfStatusSensStatus,
ZenGnssProperty_Max
}

View File

@@ -0,0 +1,78 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum EZenImuProperty {
ZenImuProperty_Invalid = 0,
ZenImuProperty_StreamData = 1000,
ZenImuProperty_SamplingRate,
ZenImuProperty_SupportedSamplingRates,
ZenImuProperty_PollSensorData,
ZenImuProperty_CalibrateGyro,
ZenImuProperty_ResetOrientationOffset,
ZenImuProperty_CentricCompensationRate,
ZenImuProperty_LinearCompensationRate,
ZenImuProperty_FieldRadius,
ZenImuProperty_FilterMode,
ZenImuProperty_SupportedFilterModes,
ZenImuProperty_FilterPreset,
ZenImuProperty_OrientationOffsetMode,
ZenImuProperty_AccAlignment,
ZenImuProperty_AccBias,
ZenImuProperty_AccRange,
ZenImuProperty_AccSupportedRanges,
ZenImuProperty_GyrAlignment,
ZenImuProperty_GyrBias,
ZenImuProperty_GyrStaticBias,
ZenImuProperty_GyrRange,
ZenImuProperty_GyrSupportedRanges,
ZenImuProperty_GyrUseAutoCalibration,
ZenImuProperty_GyrUseThreshold,
ZenImuProperty_MagAlignment,
ZenImuProperty_MagBias,
ZenImuProperty_MagRange,
ZenImuProperty_MagSupportedRanges,
ZenImuProperty_MagReference,
ZenImuProperty_MagHardIronOffset,
ZenImuProperty_MagSoftIronMatrix,
ZenImuProperty_OutputLowPrecision,
ZenImuProperty_OutputRawAcc,
ZenImuProperty_OutputRawGyr,
ZenImuProperty_OutputRawMag,
ZenImuProperty_OutputEuler,
ZenImuProperty_OutputQuat,
ZenImuProperty_OutputAngularVel,
ZenImuProperty_OutputLinearAcc,
ZenImuProperty_OutputHeaveMotion,
ZenImuProperty_OutputAltitude,
ZenImuProperty_OutputPressure,
ZenImuProperty_OutputTemperature,
ZenImuProperty_OutputAccCalibrated,
ZenImuProperty_OutputRawGyr0,
ZenImuProperty_OutputRawGyr1,
ZenImuProperty_OutputGyr0BiasCalib,
ZenImuProperty_OutputGyr1BiasCalib,
ZenImuProperty_OutputGyr0AlignCalib,
ZenImuProperty_OutputGyr1AlignCalib,
ZenImuProperty_OutputMagCalib,
ZenImuProperty_DegRadOutput,
ZenImuProperty_CanChannelMode,
ZenImuProperty_CanPointMode,
ZenImuProperty_CanStartId,
ZenImuProperty_CanBaudrate,
ZenImuProperty_CanMapping,
ZenImuProperty_CanHeartbeat,
ZenImuProperty_UartBaudRate,
ZenImuProperty_UartFormat,
ZenImuProperty_StartSensorSync,
ZenImuProperty_StopSensorSync,
ZenImuProperty_Id,
ZenImuProperty_Max
}

View File

@@ -0,0 +1,31 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum EZenSensorProperty {
ZenSensorProperty_Invalid = 0,
ZenSensorProperty_DeviceName = 1000,
ZenSensorProperty_FirmwareInfo,
ZenSensorProperty_FirmwareVersion,
ZenSensorProperty_SerialNumber,
ZenSensorProperty_RestoreFactorySettings,
ZenSensorProperty_StoreSettingsInFlash,
ZenSensorProperty_BatteryCharging,
ZenSensorProperty_BatteryLevel,
ZenSensorProperty_BatteryVoltage,
ZenSensorProperty_BaudRate,
ZenSensorProperty_SupportedBaudRates,
ZenSensorProperty_DataMode,
ZenSensorProperty_TimeOffset,
ZenSensorProperty_SensorModel,
ZenSensorProperty_SensorSpecific_Start = 10000,
ZenSensorProperty_SensorSpecific_End = 19999,
ZenSensorProperty_Max
}

View File

@@ -0,0 +1,319 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class OpenZen {
public static string g_zenSensorType_Imu {
get {
string ret = OpenZenPINVOKE.g_zenSensorType_Imu_get();
return ret;
}
}
public static string g_zenSensorType_Gnss {
get {
string ret = OpenZenPINVOKE.g_zenSensorType_Gnss_get();
return ret;
}
}
public static ZenError ZenInit(ZenClientHandle_t outHandle) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenInit(ZenClientHandle_t.getCPtr(outHandle));
return ret;
}
public static ZenError ZenShutdown(ZenClientHandle_t handle) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenShutdown(ZenClientHandle_t.getCPtr(handle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSetLogLevel(ZenLogLevel logLevel) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSetLogLevel((int)logLevel);
return ret;
}
public static ZenError ZenListSensorsAsync(ZenClientHandle_t handle) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenListSensorsAsync(ZenClientHandle_t.getCPtr(handle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenSensorInitError ZenObtainSensor(ZenClientHandle_t clientHandle, ZenSensorDesc desc, ZenSensorHandle_t outSensorHandle) {
ZenSensorInitError ret = (ZenSensorInitError)OpenZenPINVOKE.ZenObtainSensor(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorDesc.getCPtr(desc), ZenSensorHandle_t.getCPtr(outSensorHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenSensorInitError ZenObtainSensorByName(ZenClientHandle_t clientHandle, string ioType, string sensorIdentifier, uint baudRate, ZenSensorHandle_t outSensorHandle) {
ZenSensorInitError ret = (ZenSensorInitError)OpenZenPINVOKE.ZenObtainSensorByName(ZenClientHandle_t.getCPtr(clientHandle), ioType, sensorIdentifier, baudRate, ZenSensorHandle_t.getCPtr(outSensorHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenReleaseSensor(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenReleaseSensor(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenPollNextEvent(ZenClientHandle_t handle, ZenEvent outEvent) {
bool ret = OpenZenPINVOKE.ZenPollNextEvent(ZenClientHandle_t.getCPtr(handle), ZenEvent.getCPtr(outEvent));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenWaitForNextEvent(ZenClientHandle_t handle, ZenEvent outEvent) {
bool ret = OpenZenPINVOKE.ZenWaitForNextEvent(ZenClientHandle_t.getCPtr(handle), ZenEvent.getCPtr(outEvent));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenPublishEvents(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, string endpoint) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenPublishEvents(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), endpoint);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponents(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, string type, SWIGTYPE_p_p_ZenComponentHandle outComponentHandles, SWIGTYPE_p_size_t outLength) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponents(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), type, SWIGTYPE_p_p_ZenComponentHandle.getCPtr(outComponentHandles), SWIGTYPE_p_size_t.getCPtr(outLength));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentsByNumber(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, string type, uint number, ZenComponentHandle_t outComponentHandle) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentsByNumber(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), type, number, ZenComponentHandle_t.getCPtr(outComponentHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static string ZenSensorIoType(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle) {
string ret = OpenZenPINVOKE.ZenSensorIoType(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static string ZenSensorName(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle) {
string ret = OpenZenPINVOKE.ZenSensorName(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorEquals(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenSensorDesc desc) {
bool ret = OpenZenPINVOKE.ZenSensorEquals(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenSensorDesc.getCPtr(desc));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenAsyncStatus ZenSensorUpdateFirmwareAsync(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, SWIGTYPE_p_unsigned_char buffer, uint bufferSize) {
ZenAsyncStatus ret = (ZenAsyncStatus)OpenZenPINVOKE.ZenSensorUpdateFirmwareAsync(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), SWIGTYPE_p_unsigned_char.getCPtr(buffer), bufferSize);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenAsyncStatus ZenSensorUpdateIAPAsync(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, SWIGTYPE_p_unsigned_char buffer, uint bufferSize) {
ZenAsyncStatus ret = (ZenAsyncStatus)OpenZenPINVOKE.ZenSensorUpdateIAPAsync(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), SWIGTYPE_p_unsigned_char.getCPtr(buffer), bufferSize);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorExecuteProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorExecuteProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorGetArrayProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, ZenPropertyType type, SWIGTYPE_p_void buffer, SWIGTYPE_p_size_t bufferSize) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorGetArrayProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, (int)type, SWIGTYPE_p_void.getCPtr(buffer), SWIGTYPE_p_size_t.getCPtr(bufferSize));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorGetBoolProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, SWIGTYPE_p_bool outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorGetBoolProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, SWIGTYPE_p_bool.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorGetFloatProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, SWIGTYPE_p_float outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorGetFloatProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, SWIGTYPE_p_float.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorGetInt32Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, SWIGTYPE_p_int outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorGetInt32Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, SWIGTYPE_p_int.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorGetUInt64Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, SWIGTYPE_p_unsigned_long outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorGetUInt64Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, SWIGTYPE_p_unsigned_long.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorSetArrayProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, ZenPropertyType type, SWIGTYPE_p_void buffer, uint bufferSize) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorSetArrayProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, (int)type, SWIGTYPE_p_void.getCPtr(buffer), bufferSize);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorSetBoolProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, bool value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorSetBoolProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorSetFloatProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, float value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorSetFloatProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorSetInt32Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, int value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorSetInt32Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorSetUInt64Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property, uint value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorSetUInt64Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorIsArrayProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property) {
bool ret = OpenZenPINVOKE.ZenSensorIsArrayProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorIsConstantProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property) {
bool ret = OpenZenPINVOKE.ZenSensorIsConstantProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorIsExecutableProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property) {
bool ret = OpenZenPINVOKE.ZenSensorIsExecutableProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenPropertyType ZenSensorPropertyType(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, int property) {
ZenPropertyType ret = (ZenPropertyType)OpenZenPINVOKE.ZenSensorPropertyType(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static string ZenSensorComponentType(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle) {
string ret = OpenZenPINVOKE.ZenSensorComponentType(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentExecuteProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentExecuteProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentGetArrayProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, ZenPropertyType type, SWIGTYPE_p_void buffer, SWIGTYPE_p_size_t bufferSize) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentGetArrayProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, (int)type, SWIGTYPE_p_void.getCPtr(buffer), SWIGTYPE_p_size_t.getCPtr(bufferSize));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentGetBoolProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, SWIGTYPE_p_bool outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentGetBoolProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, SWIGTYPE_p_bool.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentGetFloatProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, SWIGTYPE_p_float outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentGetFloatProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, SWIGTYPE_p_float.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentGetInt32Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, SWIGTYPE_p_int outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentGetInt32Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, SWIGTYPE_p_int.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentGetUInt64Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, SWIGTYPE_p_unsigned_long outValue) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentGetUInt64Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, SWIGTYPE_p_unsigned_long.getCPtr(outValue));
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentSetArrayProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, ZenPropertyType type, SWIGTYPE_p_void buffer, uint bufferSize) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentSetArrayProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, (int)type, SWIGTYPE_p_void.getCPtr(buffer), bufferSize);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentSetBoolProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, bool value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentSetBoolProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentSetFloatProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, float value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentSetFloatProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentSetInt32Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, int value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentSetInt32Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentSetUInt64Property(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property, uint value) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentSetUInt64Property(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property, value);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorComponentIsArrayProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property) {
bool ret = OpenZenPINVOKE.ZenSensorComponentIsArrayProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorComponentIsConstantProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property) {
bool ret = OpenZenPINVOKE.ZenSensorComponentIsConstantProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static bool ZenSensorComponentIsExecutableProperty(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property) {
bool ret = OpenZenPINVOKE.ZenSensorComponentIsExecutableProperty(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenPropertyType ZenSensorComponentPropertyType(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, int property) {
ZenPropertyType ret = (ZenPropertyType)OpenZenPINVOKE.ZenSensorComponentPropertyType(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), property);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
public static ZenError ZenSensorComponentGnnsForwardRtkCorrections(ZenClientHandle_t clientHandle, ZenSensorHandle_t sensorHandle, ZenComponentHandle_t componentHandle, string rtkCorrectionSource, string hostname, uint port) {
ZenError ret = (ZenError)OpenZenPINVOKE.ZenSensorComponentGnnsForwardRtkCorrections(ZenClientHandle_t.getCPtr(clientHandle), ZenSensorHandle_t.getCPtr(sensorHandle), ZenComponentHandle_t.getCPtr(componentHandle), rtkCorrectionSource, hostname, port);
if (OpenZenPINVOKE.SWIGPendingException.Pending) throw OpenZenPINVOKE.SWIGPendingException.Retrieve();
return ret;
}
}

View File

@@ -0,0 +1,70 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class OpenZenFloatArray : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal OpenZenFloatArray(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(OpenZenFloatArray obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~OpenZenFloatArray() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_OpenZenFloatArray(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public OpenZenFloatArray(int nelements) : this(OpenZenPINVOKE.new_OpenZenFloatArray(nelements), true) {
}
public float getitem(int index) {
float ret = OpenZenPINVOKE.OpenZenFloatArray_getitem(swigCPtr, index);
return ret;
}
public void setitem(int index, float value) {
OpenZenPINVOKE.OpenZenFloatArray_setitem(swigCPtr, index, value);
}
public SWIGTYPE_p_float cast() {
global::System.IntPtr cPtr = OpenZenPINVOKE.OpenZenFloatArray_cast(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
public static OpenZenFloatArray frompointer(SWIGTYPE_p_float t) {
global::System.IntPtr cPtr = OpenZenPINVOKE.OpenZenFloatArray_frompointer(SWIGTYPE_p_float.getCPtr(t));
OpenZenFloatArray ret = (cPtr == global::System.IntPtr.Zero) ? null : new OpenZenFloatArray(cPtr, false);
return ret;
}
}

View File

@@ -0,0 +1,815 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
class OpenZenPINVOKE {
protected class SWIGExceptionHelper {
public delegate void ExceptionDelegate(string message);
public delegate void ExceptionArgumentDelegate(string message, string paramName);
static ExceptionDelegate applicationDelegate = new ExceptionDelegate(SetPendingApplicationException);
static ExceptionDelegate arithmeticDelegate = new ExceptionDelegate(SetPendingArithmeticException);
static ExceptionDelegate divideByZeroDelegate = new ExceptionDelegate(SetPendingDivideByZeroException);
static ExceptionDelegate indexOutOfRangeDelegate = new ExceptionDelegate(SetPendingIndexOutOfRangeException);
static ExceptionDelegate invalidCastDelegate = new ExceptionDelegate(SetPendingInvalidCastException);
static ExceptionDelegate invalidOperationDelegate = new ExceptionDelegate(SetPendingInvalidOperationException);
static ExceptionDelegate ioDelegate = new ExceptionDelegate(SetPendingIOException);
static ExceptionDelegate nullReferenceDelegate = new ExceptionDelegate(SetPendingNullReferenceException);
static ExceptionDelegate outOfMemoryDelegate = new ExceptionDelegate(SetPendingOutOfMemoryException);
static ExceptionDelegate overflowDelegate = new ExceptionDelegate(SetPendingOverflowException);
static ExceptionDelegate systemDelegate = new ExceptionDelegate(SetPendingSystemException);
static ExceptionArgumentDelegate argumentDelegate = new ExceptionArgumentDelegate(SetPendingArgumentException);
static ExceptionArgumentDelegate argumentNullDelegate = new ExceptionArgumentDelegate(SetPendingArgumentNullException);
static ExceptionArgumentDelegate argumentOutOfRangeDelegate = new ExceptionArgumentDelegate(SetPendingArgumentOutOfRangeException);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="SWIGRegisterExceptionCallbacks_OpenZen")]
public static extern void SWIGRegisterExceptionCallbacks_OpenZen(
ExceptionDelegate applicationDelegate,
ExceptionDelegate arithmeticDelegate,
ExceptionDelegate divideByZeroDelegate,
ExceptionDelegate indexOutOfRangeDelegate,
ExceptionDelegate invalidCastDelegate,
ExceptionDelegate invalidOperationDelegate,
ExceptionDelegate ioDelegate,
ExceptionDelegate nullReferenceDelegate,
ExceptionDelegate outOfMemoryDelegate,
ExceptionDelegate overflowDelegate,
ExceptionDelegate systemExceptionDelegate);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="SWIGRegisterExceptionArgumentCallbacks_OpenZen")]
public static extern void SWIGRegisterExceptionCallbacksArgument_OpenZen(
ExceptionArgumentDelegate argumentDelegate,
ExceptionArgumentDelegate argumentNullDelegate,
ExceptionArgumentDelegate argumentOutOfRangeDelegate);
static void SetPendingApplicationException(string message) {
SWIGPendingException.Set(new global::System.ApplicationException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingArithmeticException(string message) {
SWIGPendingException.Set(new global::System.ArithmeticException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingDivideByZeroException(string message) {
SWIGPendingException.Set(new global::System.DivideByZeroException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingIndexOutOfRangeException(string message) {
SWIGPendingException.Set(new global::System.IndexOutOfRangeException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingInvalidCastException(string message) {
SWIGPendingException.Set(new global::System.InvalidCastException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingInvalidOperationException(string message) {
SWIGPendingException.Set(new global::System.InvalidOperationException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingIOException(string message) {
SWIGPendingException.Set(new global::System.IO.IOException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingNullReferenceException(string message) {
SWIGPendingException.Set(new global::System.NullReferenceException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingOutOfMemoryException(string message) {
SWIGPendingException.Set(new global::System.OutOfMemoryException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingOverflowException(string message) {
SWIGPendingException.Set(new global::System.OverflowException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingSystemException(string message) {
SWIGPendingException.Set(new global::System.SystemException(message, SWIGPendingException.Retrieve()));
}
static void SetPendingArgumentException(string message, string paramName) {
SWIGPendingException.Set(new global::System.ArgumentException(message, paramName, SWIGPendingException.Retrieve()));
}
static void SetPendingArgumentNullException(string message, string paramName) {
global::System.Exception e = SWIGPendingException.Retrieve();
if (e != null) message = message + " Inner Exception: " + e.Message;
SWIGPendingException.Set(new global::System.ArgumentNullException(paramName, message));
}
static void SetPendingArgumentOutOfRangeException(string message, string paramName) {
global::System.Exception e = SWIGPendingException.Retrieve();
if (e != null) message = message + " Inner Exception: " + e.Message;
SWIGPendingException.Set(new global::System.ArgumentOutOfRangeException(paramName, message));
}
static SWIGExceptionHelper() {
SWIGRegisterExceptionCallbacks_OpenZen(
applicationDelegate,
arithmeticDelegate,
divideByZeroDelegate,
indexOutOfRangeDelegate,
invalidCastDelegate,
invalidOperationDelegate,
ioDelegate,
nullReferenceDelegate,
outOfMemoryDelegate,
overflowDelegate,
systemDelegate);
SWIGRegisterExceptionCallbacksArgument_OpenZen(
argumentDelegate,
argumentNullDelegate,
argumentOutOfRangeDelegate);
}
}
protected static SWIGExceptionHelper swigExceptionHelper = new SWIGExceptionHelper();
public class SWIGPendingException {
[global::System.ThreadStatic]
private static global::System.Exception pendingException = null;
private static int numExceptionsPending = 0;
private static global::System.Object exceptionsLock = null;
public static bool Pending {
get {
bool pending = false;
if (numExceptionsPending > 0)
if (pendingException != null)
pending = true;
return pending;
}
}
public static void Set(global::System.Exception e) {
if (pendingException != null)
throw new global::System.ApplicationException("FATAL: An earlier pending exception from unmanaged code was missed and thus not thrown (" + pendingException.ToString() + ")", e);
pendingException = e;
lock(exceptionsLock) {
numExceptionsPending++;
}
}
public static global::System.Exception Retrieve() {
global::System.Exception e = null;
if (numExceptionsPending > 0) {
if (pendingException != null) {
e = pendingException;
pendingException = null;
lock(exceptionsLock) {
numExceptionsPending--;
}
}
}
return e;
}
static SWIGPendingException() {
exceptionsLock = new global::System.Object();
}
}
protected class SWIGStringHelper {
public delegate string SWIGStringDelegate(string message);
static SWIGStringDelegate stringDelegate = new SWIGStringDelegate(CreateString);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="SWIGRegisterStringCallback_OpenZen")]
public static extern void SWIGRegisterStringCallback_OpenZen(SWIGStringDelegate stringDelegate);
static string CreateString(string cString) {
return cString;
}
static SWIGStringHelper() {
SWIGRegisterStringCallback_OpenZen(stringDelegate);
}
}
static protected SWIGStringHelper swigStringHelper = new SWIGStringHelper();
static OpenZenPINVOKE() {
}
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_OpenZenFloatArray")]
public static extern global::System.IntPtr new_OpenZenFloatArray(int jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_OpenZenFloatArray")]
public static extern void delete_OpenZenFloatArray(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_OpenZenFloatArray_getitem")]
public static extern float OpenZenFloatArray_getitem(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_OpenZenFloatArray_setitem")]
public static extern void OpenZenFloatArray_setitem(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2, float jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_OpenZenFloatArray_cast")]
public static extern global::System.IntPtr OpenZenFloatArray_cast(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_OpenZenFloatArray_frompointer")]
public static extern global::System.IntPtr OpenZenFloatArray_frompointer(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenClientHandle_t_handle_set")]
public static extern void ZenClientHandle_t_handle_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenClientHandle_t_handle_get")]
public static extern uint ZenClientHandle_t_handle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenClientHandle_t")]
public static extern global::System.IntPtr new_ZenClientHandle_t();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenClientHandle_t")]
public static extern void delete_ZenClientHandle_t(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorHandle_t_handle_set")]
public static extern void ZenSensorHandle_t_handle_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorHandle_t_handle_get")]
public static extern uint ZenSensorHandle_t_handle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenSensorHandle_t")]
public static extern global::System.IntPtr new_ZenSensorHandle_t();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenSensorHandle_t")]
public static extern void delete_ZenSensorHandle_t(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenComponentHandle_t_handle_set")]
public static extern void ZenComponentHandle_t_handle_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenComponentHandle_t_handle_get")]
public static extern uint ZenComponentHandle_t_handle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenComponentHandle_t")]
public static extern global::System.IntPtr new_ZenComponentHandle_t();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenComponentHandle_t")]
public static extern void delete_ZenComponentHandle_t(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_frameCount_set")]
public static extern void ZenImuData_frameCount_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_frameCount_get")]
public static extern int ZenImuData_frameCount_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_timestamp_set")]
public static extern void ZenImuData_timestamp_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_timestamp_get")]
public static extern double ZenImuData_timestamp_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_a_set")]
public static extern void ZenImuData_a_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_a_get")]
public static extern global::System.IntPtr ZenImuData_a_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g1_set")]
public static extern void ZenImuData_g1_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g1_get")]
public static extern global::System.IntPtr ZenImuData_g1_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g2_set")]
public static extern void ZenImuData_g2_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g2_get")]
public static extern global::System.IntPtr ZenImuData_g2_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g1BiasCalib_set")]
public static extern void ZenImuData_g1BiasCalib_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g1BiasCalib_get")]
public static extern global::System.IntPtr ZenImuData_g1BiasCalib_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g2BiasCalib_set")]
public static extern void ZenImuData_g2BiasCalib_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g2BiasCalib_get")]
public static extern global::System.IntPtr ZenImuData_g2BiasCalib_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_b_set")]
public static extern void ZenImuData_b_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_b_get")]
public static extern global::System.IntPtr ZenImuData_b_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_aRaw_set")]
public static extern void ZenImuData_aRaw_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_aRaw_get")]
public static extern global::System.IntPtr ZenImuData_aRaw_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g1Raw_set")]
public static extern void ZenImuData_g1Raw_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g1Raw_get")]
public static extern global::System.IntPtr ZenImuData_g1Raw_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g2Raw_set")]
public static extern void ZenImuData_g2Raw_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_g2Raw_get")]
public static extern global::System.IntPtr ZenImuData_g2Raw_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_bRaw_set")]
public static extern void ZenImuData_bRaw_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_bRaw_get")]
public static extern global::System.IntPtr ZenImuData_bRaw_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_w_set")]
public static extern void ZenImuData_w_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_w_get")]
public static extern global::System.IntPtr ZenImuData_w_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_r_set")]
public static extern void ZenImuData_r_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_r_get")]
public static extern global::System.IntPtr ZenImuData_r_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_q_set")]
public static extern void ZenImuData_q_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_q_get")]
public static extern global::System.IntPtr ZenImuData_q_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_rotationM_set")]
public static extern void ZenImuData_rotationM_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_rotationM_get")]
public static extern global::System.IntPtr ZenImuData_rotationM_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_rotOffsetM_set")]
public static extern void ZenImuData_rotOffsetM_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_rotOffsetM_get")]
public static extern global::System.IntPtr ZenImuData_rotOffsetM_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_pressure_set")]
public static extern void ZenImuData_pressure_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_pressure_get")]
public static extern float ZenImuData_pressure_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_linAcc_set")]
public static extern void ZenImuData_linAcc_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_linAcc_get")]
public static extern global::System.IntPtr ZenImuData_linAcc_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_gTemp_set")]
public static extern void ZenImuData_gTemp_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_gTemp_get")]
public static extern float ZenImuData_gTemp_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_altitude_set")]
public static extern void ZenImuData_altitude_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_altitude_get")]
public static extern float ZenImuData_altitude_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_temperature_set")]
public static extern void ZenImuData_temperature_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_temperature_get")]
public static extern float ZenImuData_temperature_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_heaveMotion_set")]
public static extern void ZenImuData_heaveMotion_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenImuData_heaveMotion_get")]
public static extern float ZenImuData_heaveMotion_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenImuData")]
public static extern global::System.IntPtr new_ZenImuData();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenImuData")]
public static extern void delete_ZenImuData(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_frameCount_set")]
public static extern void ZenGnssData_frameCount_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_frameCount_get")]
public static extern int ZenGnssData_frameCount_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_timestamp_set")]
public static extern void ZenGnssData_timestamp_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_timestamp_get")]
public static extern double ZenGnssData_timestamp_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_latitude_set")]
public static extern void ZenGnssData_latitude_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_latitude_get")]
public static extern double ZenGnssData_latitude_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_horizontalAccuracy_set")]
public static extern void ZenGnssData_horizontalAccuracy_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_horizontalAccuracy_get")]
public static extern double ZenGnssData_horizontalAccuracy_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_longitude_set")]
public static extern void ZenGnssData_longitude_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_longitude_get")]
public static extern double ZenGnssData_longitude_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_verticalAccuracy_set")]
public static extern void ZenGnssData_verticalAccuracy_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_verticalAccuracy_get")]
public static extern double ZenGnssData_verticalAccuracy_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_height_set")]
public static extern void ZenGnssData_height_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_height_get")]
public static extern double ZenGnssData_height_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_headingOfMotion_set")]
public static extern void ZenGnssData_headingOfMotion_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_headingOfMotion_get")]
public static extern double ZenGnssData_headingOfMotion_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_headingOfVehicle_set")]
public static extern void ZenGnssData_headingOfVehicle_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_headingOfVehicle_get")]
public static extern double ZenGnssData_headingOfVehicle_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_headingAccuracy_set")]
public static extern void ZenGnssData_headingAccuracy_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_headingAccuracy_get")]
public static extern double ZenGnssData_headingAccuracy_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_velocity_set")]
public static extern void ZenGnssData_velocity_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_velocity_get")]
public static extern double ZenGnssData_velocity_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_velocityAccuracy_set")]
public static extern void ZenGnssData_velocityAccuracy_set(global::System.Runtime.InteropServices.HandleRef jarg1, double jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_velocityAccuracy_get")]
public static extern double ZenGnssData_velocityAccuracy_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_fixType_set")]
public static extern void ZenGnssData_fixType_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_fixType_get")]
public static extern int ZenGnssData_fixType_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_carrierPhaseSolution_set")]
public static extern void ZenGnssData_carrierPhaseSolution_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_carrierPhaseSolution_get")]
public static extern int ZenGnssData_carrierPhaseSolution_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_numberSatellitesUsed_set")]
public static extern void ZenGnssData_numberSatellitesUsed_set(global::System.Runtime.InteropServices.HandleRef jarg1, byte jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_numberSatellitesUsed_get")]
public static extern byte ZenGnssData_numberSatellitesUsed_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_year_set")]
public static extern void ZenGnssData_year_set(global::System.Runtime.InteropServices.HandleRef jarg1, ushort jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_year_get")]
public static extern ushort ZenGnssData_year_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_month_set")]
public static extern void ZenGnssData_month_set(global::System.Runtime.InteropServices.HandleRef jarg1, byte jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_month_get")]
public static extern byte ZenGnssData_month_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_day_set")]
public static extern void ZenGnssData_day_set(global::System.Runtime.InteropServices.HandleRef jarg1, byte jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_day_get")]
public static extern byte ZenGnssData_day_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_hour_set")]
public static extern void ZenGnssData_hour_set(global::System.Runtime.InteropServices.HandleRef jarg1, byte jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_hour_get")]
public static extern byte ZenGnssData_hour_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_minute_set")]
public static extern void ZenGnssData_minute_set(global::System.Runtime.InteropServices.HandleRef jarg1, byte jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_minute_get")]
public static extern byte ZenGnssData_minute_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_second_set")]
public static extern void ZenGnssData_second_set(global::System.Runtime.InteropServices.HandleRef jarg1, byte jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_second_get")]
public static extern byte ZenGnssData_second_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_nanoSecondCorrection_set")]
public static extern void ZenGnssData_nanoSecondCorrection_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenGnssData_nanoSecondCorrection_get")]
public static extern int ZenGnssData_nanoSecondCorrection_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenGnssData")]
public static extern global::System.IntPtr new_ZenGnssData();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenGnssData")]
public static extern void delete_ZenGnssData(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_name_set")]
public static extern void ZenSensorDesc_name_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_name_get")]
public static extern string ZenSensorDesc_name_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_serialNumber_set")]
public static extern void ZenSensorDesc_serialNumber_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_serialNumber_get")]
public static extern string ZenSensorDesc_serialNumber_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_ioType_set")]
public static extern void ZenSensorDesc_ioType_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_ioType_get")]
public static extern string ZenSensorDesc_ioType_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_identifier_set")]
public static extern void ZenSensorDesc_identifier_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_identifier_get")]
public static extern string ZenSensorDesc_identifier_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_baudRate_set")]
public static extern void ZenSensorDesc_baudRate_set(global::System.Runtime.InteropServices.HandleRef jarg1, uint jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorDesc_baudRate_get")]
public static extern uint ZenSensorDesc_baudRate_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenSensorDesc")]
public static extern global::System.IntPtr new_ZenSensorDesc();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenSensorDesc")]
public static extern void delete_ZenSensorDesc(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_SensorDisconnected_error_set")]
public static extern void ZenEventData_SensorDisconnected_error_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_SensorDisconnected_error_get")]
public static extern int ZenEventData_SensorDisconnected_error_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenEventData_SensorDisconnected")]
public static extern global::System.IntPtr new_ZenEventData_SensorDisconnected();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenEventData_SensorDisconnected")]
public static extern void delete_ZenEventData_SensorDisconnected(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_SensorListingProgress_progress_set")]
public static extern void ZenEventData_SensorListingProgress_progress_set(global::System.Runtime.InteropServices.HandleRef jarg1, float jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_SensorListingProgress_progress_get")]
public static extern float ZenEventData_SensorListingProgress_progress_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_SensorListingProgress_complete_set")]
public static extern void ZenEventData_SensorListingProgress_complete_set(global::System.Runtime.InteropServices.HandleRef jarg1, char jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_SensorListingProgress_complete_get")]
public static extern char ZenEventData_SensorListingProgress_complete_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenEventData_SensorListingProgress")]
public static extern global::System.IntPtr new_ZenEventData_SensorListingProgress();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenEventData_SensorListingProgress")]
public static extern void delete_ZenEventData_SensorListingProgress(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_imuData_set")]
public static extern void ZenEventData_imuData_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_imuData_get")]
public static extern global::System.IntPtr ZenEventData_imuData_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_gnssData_set")]
public static extern void ZenEventData_gnssData_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_gnssData_get")]
public static extern global::System.IntPtr ZenEventData_gnssData_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_sensorDisconnected_set")]
public static extern void ZenEventData_sensorDisconnected_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_sensorDisconnected_get")]
public static extern global::System.IntPtr ZenEventData_sensorDisconnected_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_sensorFound_set")]
public static extern void ZenEventData_sensorFound_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_sensorFound_get")]
public static extern global::System.IntPtr ZenEventData_sensorFound_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_sensorListingProgress_set")]
public static extern void ZenEventData_sensorListingProgress_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEventData_sensorListingProgress_get")]
public static extern global::System.IntPtr ZenEventData_sensorListingProgress_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenEventData")]
public static extern global::System.IntPtr new_ZenEventData();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenEventData")]
public static extern void delete_ZenEventData(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_eventType_set")]
public static extern void ZenEvent_eventType_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_eventType_get")]
public static extern int ZenEvent_eventType_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_sensor_set")]
public static extern void ZenEvent_sensor_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_sensor_get")]
public static extern global::System.IntPtr ZenEvent_sensor_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_component_set")]
public static extern void ZenEvent_component_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_component_get")]
public static extern global::System.IntPtr ZenEvent_component_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_data_set")]
public static extern void ZenEvent_data_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenEvent_data_get")]
public static extern global::System.IntPtr ZenEvent_data_get(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_new_ZenEvent")]
public static extern global::System.IntPtr new_ZenEvent();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_delete_ZenEvent")]
public static extern void delete_ZenEvent(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_g_zenSensorType_Imu_get")]
public static extern string g_zenSensorType_Imu_get();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_g_zenSensorType_Gnss_get")]
public static extern string g_zenSensorType_Gnss_get();
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenInit")]
public static extern int ZenInit(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenShutdown")]
public static extern int ZenShutdown(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSetLogLevel")]
public static extern int ZenSetLogLevel(int jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenListSensorsAsync")]
public static extern int ZenListSensorsAsync(global::System.Runtime.InteropServices.HandleRef jarg1);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenObtainSensor")]
public static extern int ZenObtainSensor(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenObtainSensorByName")]
public static extern int ZenObtainSensorByName(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3, uint jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenReleaseSensor")]
public static extern int ZenReleaseSensor(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenPollNextEvent")]
public static extern bool ZenPollNextEvent(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenWaitForNextEvent")]
public static extern bool ZenWaitForNextEvent(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenPublishEvents")]
public static extern int ZenPublishEvents(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, string jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponents")]
public static extern int ZenSensorComponents(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, string jarg3, global::System.Runtime.InteropServices.HandleRef jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentsByNumber")]
public static extern int ZenSensorComponentsByNumber(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, string jarg3, uint jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorIoType")]
public static extern string ZenSensorIoType(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorName")]
public static extern string ZenSensorName(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorEquals")]
public static extern bool ZenSensorEquals(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorUpdateFirmwareAsync")]
public static extern int ZenSensorUpdateFirmwareAsync(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, uint jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorUpdateIAPAsync")]
public static extern int ZenSensorUpdateIAPAsync(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, uint jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorExecuteProperty")]
public static extern int ZenSensorExecuteProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorGetArrayProperty")]
public static extern int ZenSensorGetArrayProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5, global::System.Runtime.InteropServices.HandleRef jarg6);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorGetBoolProperty")]
public static extern int ZenSensorGetBoolProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, global::System.Runtime.InteropServices.HandleRef jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorGetFloatProperty")]
public static extern int ZenSensorGetFloatProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, global::System.Runtime.InteropServices.HandleRef jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorGetInt32Property")]
public static extern int ZenSensorGetInt32Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, global::System.Runtime.InteropServices.HandleRef jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorGetUInt64Property")]
public static extern int ZenSensorGetUInt64Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, global::System.Runtime.InteropServices.HandleRef jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorSetArrayProperty")]
public static extern int ZenSensorSetArrayProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5, uint jarg6);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorSetBoolProperty")]
public static extern int ZenSensorSetBoolProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, bool jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorSetFloatProperty")]
public static extern int ZenSensorSetFloatProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, float jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorSetInt32Property")]
public static extern int ZenSensorSetInt32Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, int jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorSetUInt64Property")]
public static extern int ZenSensorSetUInt64Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3, uint jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorIsArrayProperty")]
public static extern bool ZenSensorIsArrayProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorIsConstantProperty")]
public static extern bool ZenSensorIsConstantProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorIsExecutableProperty")]
public static extern bool ZenSensorIsExecutableProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorPropertyType")]
public static extern int ZenSensorPropertyType(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, int jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentType")]
public static extern string ZenSensorComponentType(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentExecuteProperty")]
public static extern int ZenSensorComponentExecuteProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentGetArrayProperty")]
public static extern int ZenSensorComponentGetArrayProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, int jarg5, global::System.Runtime.InteropServices.HandleRef jarg6, global::System.Runtime.InteropServices.HandleRef jarg7);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentGetBoolProperty")]
public static extern int ZenSensorComponentGetBoolProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentGetFloatProperty")]
public static extern int ZenSensorComponentGetFloatProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentGetInt32Property")]
public static extern int ZenSensorComponentGetInt32Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentGetUInt64Property")]
public static extern int ZenSensorComponentGetUInt64Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, global::System.Runtime.InteropServices.HandleRef jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentSetArrayProperty")]
public static extern int ZenSensorComponentSetArrayProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, int jarg5, global::System.Runtime.InteropServices.HandleRef jarg6, uint jarg7);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentSetBoolProperty")]
public static extern int ZenSensorComponentSetBoolProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, bool jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentSetFloatProperty")]
public static extern int ZenSensorComponentSetFloatProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, float jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentSetInt32Property")]
public static extern int ZenSensorComponentSetInt32Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, int jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentSetUInt64Property")]
public static extern int ZenSensorComponentSetUInt64Property(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4, uint jarg5);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentIsArrayProperty")]
public static extern bool ZenSensorComponentIsArrayProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentIsConstantProperty")]
public static extern bool ZenSensorComponentIsConstantProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentIsExecutableProperty")]
public static extern bool ZenSensorComponentIsExecutableProperty(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentPropertyType")]
public static extern int ZenSensorComponentPropertyType(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, int jarg4);
[global::System.Runtime.InteropServices.DllImport("OpenZen", EntryPoint="CSharp_ZenSensorComponentGnnsForwardRtkCorrections")]
public static extern int ZenSensorComponentGnnsForwardRtkCorrections(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, global::System.Runtime.InteropServices.HandleRef jarg3, string jarg4, string jarg5, uint jarg6);
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_bool {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_bool(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_bool() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_bool obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_float {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_float(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_float() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_float obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_int {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_int(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_int() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_int obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_p_ZenComponentHandle {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_p_ZenComponentHandle(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_p_ZenComponentHandle() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_p_ZenComponentHandle obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_size_t {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_size_t(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_size_t() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_size_t obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_unsigned_char {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_unsigned_char(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_unsigned_char() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_unsigned_char obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_unsigned_long {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_unsigned_long(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_unsigned_long() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_unsigned_long obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class SWIGTYPE_p_void {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
internal SWIGTYPE_p_void(global::System.IntPtr cPtr, bool futureUse) {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
protected SWIGTYPE_p_void() {
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_void obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
}

View File

@@ -0,0 +1,19 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenAsyncStatus {
ZenAsync_Finished,
ZenAsync_ThreadBusy,
ZenAsync_InvalidArgument,
ZenAsync_Updating,
ZenAsync_Failed,
ZenAsync_Max
}

View File

@@ -0,0 +1,59 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenClientHandle_t : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenClientHandle_t(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenClientHandle_t obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenClientHandle_t() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenClientHandle_t(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public uint handle {
set {
OpenZenPINVOKE.ZenClientHandle_t_handle_set(swigCPtr, value);
}
get {
uint ret = OpenZenPINVOKE.ZenClientHandle_t_handle_get(swigCPtr);
return ret;
}
}
public ZenClientHandle_t() : this(OpenZenPINVOKE.new_ZenClientHandle_t(), true) {
}
}

View File

@@ -0,0 +1,59 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenComponentHandle_t : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenComponentHandle_t(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenComponentHandle_t obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenComponentHandle_t() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenComponentHandle_t(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public uint handle {
set {
OpenZenPINVOKE.ZenComponentHandle_t_handle_set(swigCPtr, value);
}
get {
uint ret = OpenZenPINVOKE.ZenComponentHandle_t_handle_get(swigCPtr);
return ret;
}
}
public ZenComponentHandle_t() : this(OpenZenPINVOKE.new_ZenComponentHandle_t(), true) {
}
}

View File

@@ -0,0 +1,58 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenError {
ZenError_None = 0,
ZenError_Unknown = 1,
ZenError_IsNull = 10,
ZenError_NotNull = 11,
ZenError_WrongDataType = 12,
ZenError_BufferTooSmall = 13,
ZenError_InvalidArgument = 14,
ZenError_NotSupported = 15,
ZenError_AlreadyInitialized = 20,
ZenError_NotInitialized = 21,
ZenError_Device_IoTypeInvalid = 30,
ZenError_Sensor_VersionNotSupported = 31,
ZenError_Device_ListingFailed = 32,
ZenError_Device_Listing = 35,
ZenError_WrongSensorType = 40,
ZenError_WrongIoType = 41,
ZenError_UnknownDeviceId = 42,
ZenError_Io_AlreadyInitialized = 800,
ZenError_Io_NotInitialized = 801,
ZenError_Io_InitFailed = 802,
ZenError_Io_DeinitFailed = 803,
ZenError_Io_ReadFailed = 804,
ZenError_Io_SendFailed = 805,
ZenError_Io_GetFailed = 806,
ZenError_Io_SetFailed = 807,
ZenError_Io_Busy = 811,
ZenError_Io_Timeout = 812,
ZenError_Io_UnexpectedFunction = 813,
ZenError_Io_UnsupportedFunction = 814,
ZenError_Io_MsgCorrupt = 815,
ZenError_Io_MsgTooBig = 816,
ZenError_Io_ExpectedAck = 820,
ZenError_Io_BaudratesUnknown = 821,
ZenError_UnknownProperty = 850,
ZenError_UnknownCommandMode = 851,
ZenError_UnsupportedEvent = 852,
ZenError_FW_FunctionFailed = 900,
ZenError_Can_BusError = 1001,
ZenError_Can_OutOfAddresses = 1002,
ZenError_Can_ResetFailed = 1006,
ZenError_Can_AddressOutOfRange = 1009,
ZenError_InvalidClientHandle = 2000,
ZenError_InvalidSensorHandle = 2001,
ZenError_InvalidComponentHandle = 2002,
ZenError_Max
}

View File

@@ -0,0 +1,92 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenEvent : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenEvent(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenEvent obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenEvent() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenEvent(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public ZenEventType eventType {
set {
OpenZenPINVOKE.ZenEvent_eventType_set(swigCPtr, (int)value);
}
get {
ZenEventType ret = (ZenEventType)OpenZenPINVOKE.ZenEvent_eventType_get(swigCPtr);
return ret;
}
}
public ZenSensorHandle_t sensor {
set {
OpenZenPINVOKE.ZenEvent_sensor_set(swigCPtr, ZenSensorHandle_t.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEvent_sensor_get(swigCPtr);
ZenSensorHandle_t ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenSensorHandle_t(cPtr, false);
return ret;
}
}
public ZenComponentHandle_t component {
set {
OpenZenPINVOKE.ZenEvent_component_set(swigCPtr, ZenComponentHandle_t.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEvent_component_get(swigCPtr);
ZenComponentHandle_t ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenComponentHandle_t(cPtr, false);
return ret;
}
}
public ZenEventData data {
set {
OpenZenPINVOKE.ZenEvent_data_set(swigCPtr, ZenEventData.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEvent_data_get(swigCPtr);
ZenEventData ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenEventData(cPtr, false);
return ret;
}
}
public ZenEvent() : this(OpenZenPINVOKE.new_ZenEvent(), true) {
}
}

View File

@@ -0,0 +1,104 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenEventData : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenEventData(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenEventData obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenEventData() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenEventData(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public ZenImuData imuData {
set {
OpenZenPINVOKE.ZenEventData_imuData_set(swigCPtr, ZenImuData.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEventData_imuData_get(swigCPtr);
ZenImuData ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenImuData(cPtr, false);
return ret;
}
}
public ZenGnssData gnssData {
set {
OpenZenPINVOKE.ZenEventData_gnssData_set(swigCPtr, ZenGnssData.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEventData_gnssData_get(swigCPtr);
ZenGnssData ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenGnssData(cPtr, false);
return ret;
}
}
public ZenEventData_SensorDisconnected sensorDisconnected {
set {
OpenZenPINVOKE.ZenEventData_sensorDisconnected_set(swigCPtr, ZenEventData_SensorDisconnected.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEventData_sensorDisconnected_get(swigCPtr);
ZenEventData_SensorDisconnected ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenEventData_SensorDisconnected(cPtr, false);
return ret;
}
}
public ZenSensorDesc sensorFound {
set {
OpenZenPINVOKE.ZenEventData_sensorFound_set(swigCPtr, ZenSensorDesc.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEventData_sensorFound_get(swigCPtr);
ZenSensorDesc ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenSensorDesc(cPtr, false);
return ret;
}
}
public ZenEventData_SensorListingProgress sensorListingProgress {
set {
OpenZenPINVOKE.ZenEventData_sensorListingProgress_set(swigCPtr, ZenEventData_SensorListingProgress.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenEventData_sensorListingProgress_get(swigCPtr);
ZenEventData_SensorListingProgress ret = (cPtr == global::System.IntPtr.Zero) ? null : new ZenEventData_SensorListingProgress(cPtr, false);
return ret;
}
}
public ZenEventData() : this(OpenZenPINVOKE.new_ZenEventData(), true) {
}
}

View File

@@ -0,0 +1,59 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenEventData_SensorDisconnected : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenEventData_SensorDisconnected(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenEventData_SensorDisconnected obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenEventData_SensorDisconnected() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenEventData_SensorDisconnected(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public int error {
set {
OpenZenPINVOKE.ZenEventData_SensorDisconnected_error_set(swigCPtr, value);
}
get {
int ret = OpenZenPINVOKE.ZenEventData_SensorDisconnected_error_get(swigCPtr);
return ret;
}
}
public ZenEventData_SensorDisconnected() : this(OpenZenPINVOKE.new_ZenEventData_SensorDisconnected(), true) {
}
}

View File

@@ -0,0 +1,69 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenEventData_SensorListingProgress : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenEventData_SensorListingProgress(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenEventData_SensorListingProgress obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenEventData_SensorListingProgress() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenEventData_SensorListingProgress(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public float progress {
set {
OpenZenPINVOKE.ZenEventData_SensorListingProgress_progress_set(swigCPtr, value);
}
get {
float ret = OpenZenPINVOKE.ZenEventData_SensorListingProgress_progress_get(swigCPtr);
return ret;
}
}
public char complete {
set {
OpenZenPINVOKE.ZenEventData_SensorListingProgress_complete_set(swigCPtr, value);
}
get {
char ret = OpenZenPINVOKE.ZenEventData_SensorListingProgress_complete_get(swigCPtr);
return ret;
}
}
public ZenEventData_SensorListingProgress() : this(OpenZenPINVOKE.new_ZenEventData_SensorListingProgress(), true) {
}
}

View File

@@ -0,0 +1,26 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenEventType {
ZenEventType_None = 0,
ZenEventType_SensorFound = 1,
ZenEventType_SensorListingProgress = 2,
ZenEventType_SensorDisconnected = 3,
ZenEventType_ImuData = 100,
ZenEventType_GnssData = 200,
ZenEventType_SensorSpecific_Start = 1000,
ZenEventType_SensorSpecific_End = 1999,
ZenEventType_ImuComponentSpecific_Start = 2000,
ZenEventType_ImuComponentSpecific_End = 2999,
ZenEventType_GnssComponentSpecific_Start = 3000,
ZenEventType_GnssComponentSpecific_End = 3999,
ZenEventType_Max
}

View File

@@ -0,0 +1,269 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenGnssData : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenGnssData(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenGnssData obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenGnssData() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenGnssData(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public int frameCount {
set {
OpenZenPINVOKE.ZenGnssData_frameCount_set(swigCPtr, value);
}
get {
int ret = OpenZenPINVOKE.ZenGnssData_frameCount_get(swigCPtr);
return ret;
}
}
public double timestamp {
set {
OpenZenPINVOKE.ZenGnssData_timestamp_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_timestamp_get(swigCPtr);
return ret;
}
}
public double latitude {
set {
OpenZenPINVOKE.ZenGnssData_latitude_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_latitude_get(swigCPtr);
return ret;
}
}
public double horizontalAccuracy {
set {
OpenZenPINVOKE.ZenGnssData_horizontalAccuracy_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_horizontalAccuracy_get(swigCPtr);
return ret;
}
}
public double longitude {
set {
OpenZenPINVOKE.ZenGnssData_longitude_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_longitude_get(swigCPtr);
return ret;
}
}
public double verticalAccuracy {
set {
OpenZenPINVOKE.ZenGnssData_verticalAccuracy_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_verticalAccuracy_get(swigCPtr);
return ret;
}
}
public double height {
set {
OpenZenPINVOKE.ZenGnssData_height_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_height_get(swigCPtr);
return ret;
}
}
public double headingOfMotion {
set {
OpenZenPINVOKE.ZenGnssData_headingOfMotion_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_headingOfMotion_get(swigCPtr);
return ret;
}
}
public double headingOfVehicle {
set {
OpenZenPINVOKE.ZenGnssData_headingOfVehicle_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_headingOfVehicle_get(swigCPtr);
return ret;
}
}
public double headingAccuracy {
set {
OpenZenPINVOKE.ZenGnssData_headingAccuracy_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_headingAccuracy_get(swigCPtr);
return ret;
}
}
public double velocity {
set {
OpenZenPINVOKE.ZenGnssData_velocity_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_velocity_get(swigCPtr);
return ret;
}
}
public double velocityAccuracy {
set {
OpenZenPINVOKE.ZenGnssData_velocityAccuracy_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenGnssData_velocityAccuracy_get(swigCPtr);
return ret;
}
}
public ZenGnssFixType fixType {
set {
OpenZenPINVOKE.ZenGnssData_fixType_set(swigCPtr, (int)value);
}
get {
ZenGnssFixType ret = (ZenGnssFixType)OpenZenPINVOKE.ZenGnssData_fixType_get(swigCPtr);
return ret;
}
}
public ZenGnssFixCarrierPhaseSolution carrierPhaseSolution {
set {
OpenZenPINVOKE.ZenGnssData_carrierPhaseSolution_set(swigCPtr, (int)value);
}
get {
ZenGnssFixCarrierPhaseSolution ret = (ZenGnssFixCarrierPhaseSolution)OpenZenPINVOKE.ZenGnssData_carrierPhaseSolution_get(swigCPtr);
return ret;
}
}
public byte numberSatellitesUsed {
set {
OpenZenPINVOKE.ZenGnssData_numberSatellitesUsed_set(swigCPtr, value);
}
get {
byte ret = OpenZenPINVOKE.ZenGnssData_numberSatellitesUsed_get(swigCPtr);
return ret;
}
}
public ushort year {
set {
OpenZenPINVOKE.ZenGnssData_year_set(swigCPtr, value);
}
get {
ushort ret = OpenZenPINVOKE.ZenGnssData_year_get(swigCPtr);
return ret;
}
}
public byte month {
set {
OpenZenPINVOKE.ZenGnssData_month_set(swigCPtr, value);
}
get {
byte ret = OpenZenPINVOKE.ZenGnssData_month_get(swigCPtr);
return ret;
}
}
public byte day {
set {
OpenZenPINVOKE.ZenGnssData_day_set(swigCPtr, value);
}
get {
byte ret = OpenZenPINVOKE.ZenGnssData_day_get(swigCPtr);
return ret;
}
}
public byte hour {
set {
OpenZenPINVOKE.ZenGnssData_hour_set(swigCPtr, value);
}
get {
byte ret = OpenZenPINVOKE.ZenGnssData_hour_get(swigCPtr);
return ret;
}
}
public byte minute {
set {
OpenZenPINVOKE.ZenGnssData_minute_set(swigCPtr, value);
}
get {
byte ret = OpenZenPINVOKE.ZenGnssData_minute_get(swigCPtr);
return ret;
}
}
public byte second {
set {
OpenZenPINVOKE.ZenGnssData_second_set(swigCPtr, value);
}
get {
byte ret = OpenZenPINVOKE.ZenGnssData_second_get(swigCPtr);
return ret;
}
}
public int nanoSecondCorrection {
set {
OpenZenPINVOKE.ZenGnssData_nanoSecondCorrection_set(swigCPtr, value);
}
get {
int ret = OpenZenPINVOKE.ZenGnssData_nanoSecondCorrection_get(swigCPtr);
return ret;
}
}
public ZenGnssData() : this(OpenZenPINVOKE.new_ZenGnssData(), true) {
}
}

View File

@@ -0,0 +1,16 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenGnssFixCarrierPhaseSolution {
ZenGnssFixCarrierPhaseSolution_None = 0,
ZenGnssFixCarrierPhaseSolution_FloatAmbiguities = 1,
ZenGnssFixCarrierPhaseSolution_FixedAmbiguities = 2
}

View File

@@ -0,0 +1,20 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenGnssFixType {
ZenGnssFixType_NoFix = 0,
ZenGnssFixType_DeadReckoningOnly = 1,
ZenGnssFixType_2dFix = 2,
ZenGnssFixType_3dFix = 3,
ZenGnssFixType_GnssAndDeadReckoning = 4,
ZenGnssFixType_TimeOnlyFix = 5,
ZenGnssFixType_Max
}

View File

@@ -0,0 +1,295 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenImuData : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenImuData(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenImuData obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenImuData() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenImuData(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public int frameCount {
set {
OpenZenPINVOKE.ZenImuData_frameCount_set(swigCPtr, value);
}
get {
int ret = OpenZenPINVOKE.ZenImuData_frameCount_get(swigCPtr);
return ret;
}
}
public double timestamp {
set {
OpenZenPINVOKE.ZenImuData_timestamp_set(swigCPtr, value);
}
get {
double ret = OpenZenPINVOKE.ZenImuData_timestamp_get(swigCPtr);
return ret;
}
}
public SWIGTYPE_p_float a {
set {
OpenZenPINVOKE.ZenImuData_a_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_a_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float g1 {
set {
OpenZenPINVOKE.ZenImuData_g1_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_g1_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float g2 {
set {
OpenZenPINVOKE.ZenImuData_g2_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_g2_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float g1BiasCalib {
set {
OpenZenPINVOKE.ZenImuData_g1BiasCalib_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_g1BiasCalib_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float g2BiasCalib {
set {
OpenZenPINVOKE.ZenImuData_g2BiasCalib_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_g2BiasCalib_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float b {
set {
OpenZenPINVOKE.ZenImuData_b_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_b_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float aRaw {
set {
OpenZenPINVOKE.ZenImuData_aRaw_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_aRaw_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float g1Raw {
set {
OpenZenPINVOKE.ZenImuData_g1Raw_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_g1Raw_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float g2Raw {
set {
OpenZenPINVOKE.ZenImuData_g2Raw_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_g2Raw_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float bRaw {
set {
OpenZenPINVOKE.ZenImuData_bRaw_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_bRaw_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float w {
set {
OpenZenPINVOKE.ZenImuData_w_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_w_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float r {
set {
OpenZenPINVOKE.ZenImuData_r_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_r_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float q {
set {
OpenZenPINVOKE.ZenImuData_q_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_q_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float rotationM {
set {
OpenZenPINVOKE.ZenImuData_rotationM_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_rotationM_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public SWIGTYPE_p_float rotOffsetM {
set {
OpenZenPINVOKE.ZenImuData_rotOffsetM_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_rotOffsetM_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public float pressure {
set {
OpenZenPINVOKE.ZenImuData_pressure_set(swigCPtr, value);
}
get {
float ret = OpenZenPINVOKE.ZenImuData_pressure_get(swigCPtr);
return ret;
}
}
public SWIGTYPE_p_float linAcc {
set {
OpenZenPINVOKE.ZenImuData_linAcc_set(swigCPtr, SWIGTYPE_p_float.getCPtr(value));
}
get {
global::System.IntPtr cPtr = OpenZenPINVOKE.ZenImuData_linAcc_get(swigCPtr);
SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
return ret;
}
}
public float gTemp {
set {
OpenZenPINVOKE.ZenImuData_gTemp_set(swigCPtr, value);
}
get {
float ret = OpenZenPINVOKE.ZenImuData_gTemp_get(swigCPtr);
return ret;
}
}
public float altitude {
set {
OpenZenPINVOKE.ZenImuData_altitude_set(swigCPtr, value);
}
get {
float ret = OpenZenPINVOKE.ZenImuData_altitude_get(swigCPtr);
return ret;
}
}
public float temperature {
set {
OpenZenPINVOKE.ZenImuData_temperature_set(swigCPtr, value);
}
get {
float ret = OpenZenPINVOKE.ZenImuData_temperature_get(swigCPtr);
return ret;
}
}
public float heaveMotion {
set {
OpenZenPINVOKE.ZenImuData_heaveMotion_set(swigCPtr, value);
}
get {
float ret = OpenZenPINVOKE.ZenImuData_heaveMotion_get(swigCPtr);
return ret;
}
}
public ZenImuData() : this(OpenZenPINVOKE.new_ZenImuData(), true) {
}
}

View File

@@ -0,0 +1,19 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenLogLevel {
ZenLogLevel_Off,
ZenLogLevel_Error,
ZenLogLevel_Warning,
ZenLogLevel_Info,
ZenLogLevel_Debug,
ZenLogLevel_Max
}

View File

@@ -0,0 +1,17 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenOrientationOffsetMode {
ZenOrientationOffsetMode_Object = 0,
ZenOrientationOffsetMode_Heading = 1,
ZenOrientationOffsetMode_Alignment = 2,
ZenOrientationOffsetMode_Max
}

View File

@@ -0,0 +1,20 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenPropertyType {
ZenPropertyType_Invalid = 0,
ZenPropertyType_Byte = 1,
ZenPropertyType_Bool = 2,
ZenPropertyType_Float = 3,
ZenPropertyType_Int32 = 4,
ZenPropertyType_UInt64 = 5,
ZenPropertyType_Max
}

View File

@@ -0,0 +1,99 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenSensorDesc : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenSensorDesc(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenSensorDesc obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenSensorDesc() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenSensorDesc(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public string name {
set {
OpenZenPINVOKE.ZenSensorDesc_name_set(swigCPtr, value);
}
get {
string ret = OpenZenPINVOKE.ZenSensorDesc_name_get(swigCPtr);
return ret;
}
}
public string serialNumber {
set {
OpenZenPINVOKE.ZenSensorDesc_serialNumber_set(swigCPtr, value);
}
get {
string ret = OpenZenPINVOKE.ZenSensorDesc_serialNumber_get(swigCPtr);
return ret;
}
}
public string ioType {
set {
OpenZenPINVOKE.ZenSensorDesc_ioType_set(swigCPtr, value);
}
get {
string ret = OpenZenPINVOKE.ZenSensorDesc_ioType_get(swigCPtr);
return ret;
}
}
public string identifier {
set {
OpenZenPINVOKE.ZenSensorDesc_identifier_set(swigCPtr, value);
}
get {
string ret = OpenZenPINVOKE.ZenSensorDesc_identifier_get(swigCPtr);
return ret;
}
}
public uint baudRate {
set {
OpenZenPINVOKE.ZenSensorDesc_baudRate_set(swigCPtr, value);
}
get {
uint ret = OpenZenPINVOKE.ZenSensorDesc_baudRate_get(swigCPtr);
return ret;
}
}
public ZenSensorDesc() : this(OpenZenPINVOKE.new_ZenSensorDesc(), true) {
}
}

View File

@@ -0,0 +1,59 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public class ZenSensorHandle_t : global::System.IDisposable {
private global::System.Runtime.InteropServices.HandleRef swigCPtr;
protected bool swigCMemOwn;
internal ZenSensorHandle_t(global::System.IntPtr cPtr, bool cMemoryOwn) {
swigCMemOwn = cMemoryOwn;
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
}
internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ZenSensorHandle_t obj) {
return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
}
~ZenSensorHandle_t() {
Dispose(false);
}
public void Dispose() {
Dispose(true);
global::System.GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool disposing) {
lock(this) {
if (swigCPtr.Handle != global::System.IntPtr.Zero) {
if (swigCMemOwn) {
swigCMemOwn = false;
OpenZenPINVOKE.delete_ZenSensorHandle_t(swigCPtr);
}
swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
}
}
}
public uint handle {
set {
OpenZenPINVOKE.ZenSensorHandle_t_handle_set(swigCPtr, value);
}
get {
uint ret = OpenZenPINVOKE.ZenSensorHandle_t_handle_get(swigCPtr);
return ret;
}
}
public ZenSensorHandle_t() : this(OpenZenPINVOKE.new_ZenSensorHandle_t(), true) {
}
}

View File

@@ -0,0 +1,33 @@
//------------------------------------------------------------------------------
// <auto-generated />
//
// This file was automatically generated by SWIG (http://www.swig.org).
// Version 4.0.2
//
// Do not make changes to this file unless you know what you are doing--modify
// the SWIG interface file instead.
//------------------------------------------------------------------------------
public enum ZenSensorInitError {
ZenSensorInitError_None = 0,
ZenSensorInitError_InvalidHandle,
ZenSensorInitError_IsNull,
ZenSensorInitError_UnknownIdentifier,
ZenSensorInitError_UnsupportedComponent,
ZenSensorInitError_UnsupportedDataFormat,
ZenSensorInitError_UnsupportedIoType,
ZenSensorInitError_UnsupportedProtocol,
ZenSensorInitError_UnsupportedFunction,
ZenSensorInitError_ConnectFailed,
ZenSensorInitError_IoFailed,
ZenSensorInitError_RetrieveFailed,
ZenSensorInitError_SetBaudRateFailed,
ZenSensorInitError_SendFailed,
ZenSensorInitError_Timeout,
ZenSensorInitError_IncompatibleBaudRates,
ZenSensorInitError_InvalidAddress,
ZenSensorInitError_InvalidConfig,
ZenSensorInitError_NoConfiguration,
ZenSensorInitError_Max
}

View File

@@ -0,0 +1,142 @@
# Automated build file for the OpenZen repository
# -----
# Custom Docker image which brings C++ compiler and boost libraries
image:
name: mcr.microsoft.com/devcontainers/cpp:ubuntu-20.04
username: $DOCKER_HUB_USERNAME
password: $DOCKER_HUB_PASSWORD
email: $DOCKER_HUB_EMAIL
pipelines:
default:
- parallel:
- step:
name: Linux x64 Build Gcc
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake ../build
- make
- ./OpenZenTests
- step:
name: Linux x64 Build Gcc Python support
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake ../build -DZEN_PYTHON=ON
- make
- ./OpenZenTests
- step:
name: Linux x64 Unity Build Gcc
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake -DCMAKE_UNITY_BUILD=TRUE ../build
- make
- ./OpenZenTests
- step:
name: Linux x64 Build Gcc Static
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake -DZEN_USE_STATIC_LIBS=ON ../build
- make
- ./OpenZenTests
- step:
name: Linux x64 Build Clang
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang ../build
- make
- ./OpenZenTests
- step:
name: Linux x64 Build Gcc ZeroMQ support
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake -DZEN_NETWORK=ON ../build
- make
- ./OpenZenTests
- step:
name: Linux x64 Build in C++20 with Python and zmq options
script:
- git submodule update --init
- mkdir ../linux_x64_build && cd ../linux_x64_build
- cmake -DZEN_NETWORK=ON -DZEN_PYTHON=ON -DZEN_INTERNAL_CXX_VERSION=20 ../build
- make
- ./OpenZenTests
- step:
name: Linux x64 CMake Package compile and Standalone test
script:
- git submodule update --init
- mkdir ../linux_x64_build_release && cd ../linux_x64_build_release
- cmake -DCMAKE_INSTALL_PREFIX=../openzen_install ../build
- make install
- mkdir ../linux_x64_build_standalone && cd ../linux_x64_build_standalone
- cmake -DCMAKE_INSTALL_PREFIX=../openzen_install ../build/standalone_example
- make
- ./OpenZenStandaloneExample
- step:
name: Linux x64 Ubuntu 16.04
image:
name: thauth/buildbox-ubuntu-1604:2
username: $DOCKER_HUB_USERNAME
password: $DOCKER_HUB_PASSWORD
email: $DOCKER_HUB_EMAIL
script:
- git submodule update --init
- mkdir linux_x64_build_release && cd linux_x64_build_release
- cmake -DCMAKE_INSTALL_PREFIX=../openzen_release_build -DCMAKE_CXX_COMPILER=g++-7 -DCMAKE_C_COMPILER=gcc-7 -DZEN_STATIC_LINK_LIBCXX=ON ..
- make
- ./OpenZenTests
custom:
ubuntu-16-04-x64-release:
- step:
name: Linux x64 Ubuntu 16.04 Release
image:
name: thauth/buildbox-ubuntu-1604:2
username: $DOCKER_HUB_USERNAME
password: $DOCKER_HUB_PASSWORD
email: $DOCKER_HUB_EMAIL
script:
- git submodule update --init
- mkdir linux_x64_build_release && cd linux_x64_build_release
- /opt/cmake-3.16.3-Linux-x86_64/bin/cmake -DCMAKE_INSTALL_PREFIX=../openzen_release_build -DCMAKE_CXX_COMPILER=g++-7 -DCMAKE_C_COMPILER=gcc-7 -DZEN_STATIC_LINK_LIBCXX=ON ..
- make install
- cd .. && mkdir openzen_release && cd openzen_release
- sphinx-build ../docs docs/
# copy needed files into the release folder
- cp ../README.md .
- cp ../LICENSE .
- cp -rv ../openzen_release_build/lib/ .
- cp -rv ../openzen_release_build/include/ .
# compress
- cd .. && tar -zcvf openzen_release.tar.gz openzen_release
artifacts:
- openzen_release.tar.gz
ubuntu-16-04-arm64-release:
- step:
name: Linux arm64 Ubuntu 16.04 Release
image:
name: thauth/buildbox-ubuntu-1604:2
username: $DOCKER_HUB_USERNAME
password: $DOCKER_HUB_PASSWORD
email: $DOCKER_HUB_EMAIL
script:
- git submodule update --init
- export XCOMPILER_ROOT=/root/x-tools/aarch64-unknown-linux-gnu/
- mkdir linux_arm64_build_release && cd linux_arm64_build_release
- /opt/cmake-3.16.3-Linux-x86_64/bin/cmake -DCMAKE_INSTALL_PREFIX=../openzen_release_build -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=arm64 -DCMAKE_SYSTEM_VERSION=1 -DCMAKE_C_COMPILER=${XCOMPILER_ROOT}/bin/aarch64-unknown-linux-gnu-gcc -DCMAKE_CXX_COMPILER=${XCOMPILER_ROOT}/bin/aarch64-unknown-linux-gnu-g++ -DCMAKE_FIND_ROOT_PATH=${XCOMPILER_ROOT}/aarch64-unknown-linux-gnu/sysroot/ -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER -DCMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY -DCMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY -DCMAKE_BUILD_TYPE=Release -DZEN_STATIC_LINK_LIBCXX=ON ..
- make install
- cd .. && mkdir openzen_release && cd openzen_release
- sphinx-build ../docs docs/
# copy needed files into the release folder
- cp ../README.md .
- cp ../LICENSE .
- cp -rv ../openzen_release_build/lib/ .
- cp -rv ../openzen_release_build/include/ .
# compress
- cd .. && tar -zcvf openzen_release.tar.gz openzen_release
artifacts:
- openzen_release.tar.gz

View File

@@ -0,0 +1 @@
include("${CMAKE_CURRENT_LIST_DIR}/OpenZenTargets.cmake")

View File

@@ -0,0 +1,20 @@
The MIT License (MIT)
Copyright (c) 2013-2018 Dave Snider, Read the Docs, Inc. & contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@@ -0,0 +1,32 @@
"""
Sphinx Read the Docs theme.
From https://github.com/ryan-roemer/sphinx-bootstrap-theme.
"""
from os import path
import sphinx
__version__ = '0.4.3.dev0'
__version_full__ = __version__
def get_html_theme_path():
"""Return list of HTML theme paths."""
cur_dir = path.abspath(path.dirname(path.dirname(__file__)))
return cur_dir
# See http://www.sphinx-doc.org/en/stable/theming.html#distribute-your-theme-as-a-python-package
def setup(app):
app.add_html_theme('sphinx_rtd_theme', path.abspath(path.dirname(__file__)))
if sphinx.version_info >= (1, 8, 0):
# Add Sphinx message catalog for newer versions of Sphinx
# See http://www.sphinx-doc.org/en/master/extdev/appapi.html#sphinx.application.Sphinx.add_message_catalog
rtd_locale_path = path.join(path.abspath(path.dirname(__file__)), 'locale')
app.add_message_catalog('sphinx', rtd_locale_path)
return {'parallel_read_safe': True, 'parallel_write_safe': True}

View File

@@ -0,0 +1,82 @@
{# Support for Sphinx 1.3+ page_source_suffix, but don't break old builds. #}
{% if page_source_suffix %}
{% set suffix = page_source_suffix %}
{% else %}
{% set suffix = source_suffix %}
{% endif %}
{% if meta is defined and meta is not none %}
{% set check_meta = True %}
{% else %}
{% set check_meta = False %}
{% endif %}
{% if check_meta and 'github_url' in meta %}
{% set display_github = True %}
{% endif %}
{% if check_meta and 'bitbucket_url' in meta %}
{% set display_bitbucket = True %}
{% endif %}
{% if check_meta and 'gitlab_url' in meta %}
{% set display_gitlab = True %}
{% endif %}
<div role="navigation" aria-label="breadcrumbs navigation">
<ul class="wy-breadcrumbs">
{% block breadcrumbs %}
<li><a href="{{ pathto(master_doc) }}" class="icon icon-home"></a> &raquo;</li>
{% for doc in parents %}
<li><a href="{{ doc.link|e }}">{{ doc.title }}</a> &raquo;</li>
{% endfor %}
<li>{{ title }}</li>
{% endblock %}
{% block breadcrumbs_aside %}
<li class="wy-breadcrumbs-aside">
{% if hasdoc(pagename) %}
{% if display_github %}
{% if check_meta and 'github_url' in meta %}
<!-- User defined GitHub URL -->
<a href="{{ meta['github_url'] }}" class="fa fa-github"> {{ _('Edit on GitHub') }}</a>
{% else %}
<a href="https://{{ github_host|default("github.com") }}/{{ github_user }}/{{ github_repo }}/{{ theme_vcs_pageview_mode|default("blob") }}/{{ github_version }}{{ conf_py_path }}{{ pagename }}{{ suffix }}" class="fa fa-github"> {{ _('Edit on GitHub') }}</a>
{% endif %}
{% elif display_bitbucket %}
{% if check_meta and 'bitbucket_url' in meta %}
<!-- User defined Bitbucket URL -->
<a href="{{ meta['bitbucket_url'] }}" class="fa fa-bitbucket"> {{ _('Edit on Bitbucket') }}</a>
{% else %}
<a href="https://bitbucket.org/{{ bitbucket_user }}/{{ bitbucket_repo }}/src/{{ bitbucket_version}}{{ conf_py_path }}{{ pagename }}{{ suffix }}?mode={{ theme_vcs_pageview_mode|default("view") }}" class="fa fa-bitbucket"> {{ _('Edit on Bitbucket') }}</a>
{% endif %}
{% elif display_gitlab %}
{% if check_meta and 'gitlab_url' in meta %}
<!-- User defined GitLab URL -->
<a href="{{ meta['gitlab_url'] }}" class="fa fa-gitlab"> {{ _('Edit on GitLab') }}</a>
{% else %}
<a href="https://{{ gitlab_host|default("gitlab.com") }}/{{ gitlab_user }}/{{ gitlab_repo }}/{{ theme_vcs_pageview_mode|default("blob") }}/{{ gitlab_version }}{{ conf_py_path }}{{ pagename }}{{ suffix }}" class="fa fa-gitlab"> {{ _('Edit on GitLab') }}</a>
{% endif %}
{% elif show_source and source_url_prefix %}
<a href="{{ source_url_prefix }}{{ pagename }}{{ suffix }}">{{ _('View page source') }}</a>
{% elif show_source and has_source and sourcename %}
<a href="{{ pathto('_sources/' + sourcename, true)|e }}" rel="nofollow"> {{ _('View page source') }}</a>
{% endif %}
{% endif %}
</li>
{% endblock %}
</ul>
{% if (theme_prev_next_buttons_location == 'top' or theme_prev_next_buttons_location == 'both') and (next or prev) %}
<div class="rst-breadcrumbs-buttons" role="navigation" aria-label="breadcrumb navigation">
{% if next %}
<a href="{{ next.link|e }}" class="btn btn-neutral float-right" title="{{ next.title|striptags|e }}" accesskey="n">{{ _('Next') }} <span class="fa fa-arrow-circle-right"></span></a>
{% endif %}
{% if prev %}
<a href="{{ prev.link|e }}" class="btn btn-neutral float-left" title="{{ prev.title|striptags|e }}" accesskey="p"><span class="fa fa-arrow-circle-left"></span> {{ _('Previous') }}</a>
{% endif %}
</div>
{% endif %}
<hr/>
</div>

View File

@@ -0,0 +1,56 @@
<footer>
{% if (theme_prev_next_buttons_location == 'bottom' or theme_prev_next_buttons_location == 'both') and (next or prev) %}
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
{% if next %}
<a href="{{ next.link|e }}" class="btn btn-neutral float-right" title="{{ next.title|striptags|e }}" accesskey="n" rel="next">{{ _('Next') }} <span class="fa fa-arrow-circle-right"></span></a>
{% endif %}
{% if prev %}
<a href="{{ prev.link|e }}" class="btn btn-neutral float-left" title="{{ prev.title|striptags|e }}" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> {{ _('Previous') }}</a>
{% endif %}
</div>
{% endif %}
<hr/>
<div role="contentinfo">
<p>
{%- if show_copyright %}
{%- if hasdoc('copyright') %}
{% set path = pathto('copyright') %}
{% set copyright = copyright|e %}
&copy; <a href="{{ path }}">{% trans %}Copyright{% endtrans %}</a> {{ copyright }}
{%- else %}
{% set copyright = copyright|e %}
&copy; {% trans %}Copyright{% endtrans %} {{ copyright }}
{%- endif %}
{%- endif %}
{%- if build_id and build_url %}
<span class="build">
{# Translators: Build is a noun, not a verb #}
{% trans %}Build{% endtrans %}
<a href="{{ build_url }}">{{ build_id }}</a>.
</span>
{%- elif commit %}
<span class="commit">
{% trans %}Revision{% endtrans %} <code>{{ commit }}</code>.
</span>
{%- elif last_updated %}
<span class="lastupdated">
{% trans last_updated=last_updated|e %}Last updated on {{ last_updated }}.{% endtrans %}
</span>
{%- endif %}
</p>
</div>
{%- if show_sphinx %}
{% set sphinx_web = '<a href="http://sphinx-doc.org/">Sphinx</a>' %}
{% set readthedocs_web = '<a href="https://readthedocs.org">Read the Docs</a>' %}
{% trans sphinx_web=sphinx_web, readthedocs_web=readthedocs_web %}Built with {{ sphinx_web }} using a{% endtrans %} <a href="https://github.com/rtfd/sphinx_rtd_theme">{% trans %}theme{% endtrans %}</a> {% trans %}provided by {{ readthedocs_web }}{% endtrans %}.
{%- endif %}
{%- block extrafooter %} {% endblock %}
</footer>

View File

@@ -0,0 +1,240 @@
{# TEMPLATE VAR SETTINGS #}
{%- set url_root = pathto('', 1) %}
{%- if url_root == '#' %}{% set url_root = '' %}{% endif %}
{%- if not embedded and docstitle %}
{%- set titlesuffix = " &mdash; "|safe + docstitle|e %}
{%- else %}
{%- set titlesuffix = "" %}
{%- endif %}
{%- set lang_attr = 'en' if language == None else (language | replace('_', '-')) %}
<!DOCTYPE html>
<html lang="{{ lang_attr }}" >
<head>
<meta charset="utf-8">
{{ metatags }}
<meta name="viewport" content="width=device-width, initial-scale=1.0">
{% block htmltitle %}
<title>{{ title|striptags|e }}{{ titlesuffix }}</title>
{% endblock %}
{# CSS #}
<link rel="stylesheet" href="{{ pathto('_static/' + style, 1) }}" type="text/css" />
<link rel="stylesheet" href="{{ pathto('_static/pygments.css', 1) }}" type="text/css" />
{%- for css in css_files %}
{%- if css|attr("rel") %}
<link rel="{{ css.rel }}" href="{{ pathto(css.filename, 1) }}" type="text/css"{% if css.title is not none %} title="{{ css.title }}"{% endif %} />
{%- else %}
<link rel="stylesheet" href="{{ pathto(css, 1) }}" type="text/css" />
{%- endif %}
{%- endfor %}
{%- for cssfile in extra_css_files %}
<link rel="stylesheet" href="{{ pathto(cssfile, 1) }}" type="text/css" />
{%- endfor %}
{# FAVICON #}
{% if favicon %}
<link rel="shortcut icon" href="{{ pathto('_static/' + favicon, 1) }}"/>
{% endif %}
{# CANONICAL URL #}
{% if theme_canonical_url %}
<link rel="canonical" href="{{ theme_canonical_url }}{{ pagename }}.html"/>
{% endif %}
{# JAVASCRIPTS #}
{%- block scripts %}
<!--[if lt IE 9]>
<script src="{{ pathto('_static/js/html5shiv.min.js', 1) }}"></script>
<![endif]-->
{%- if not embedded %}
{# XXX Sphinx 1.8.0 made this an external js-file, quick fix until we refactor the template to inherert more blocks directly from sphinx #}
{% if sphinx_version >= "1.8.0" %}
<script type="text/javascript" id="documentation_options" data-url_root="{{ pathto('', 1) }}" src="{{ pathto('_static/documentation_options.js', 1) }}"></script>
{%- for scriptfile in script_files %}
{{ js_tag(scriptfile) }}
{%- endfor %}
{% else %}
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'{{ url_root }}',
VERSION:'{{ release|e }}',
LANGUAGE:'{{ language }}',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'{{ '' if no_search_suffix else file_suffix }}',
HAS_SOURCE: {{ has_source|lower }},
SOURCELINK_SUFFIX: '{{ sourcelink_suffix }}'
};
</script>
{%- for scriptfile in script_files %}
<script type="text/javascript" src="{{ pathto(scriptfile, 1) }}"></script>
{%- endfor %}
{% endif %}
<script type="text/javascript" src="{{ pathto('_static/js/theme.js', 1) }}"></script>
{# OPENSEARCH #}
{%- if use_opensearch %}
<link rel="search" type="application/opensearchdescription+xml"
title="{% trans docstitle=docstitle|e %}Search within {{ docstitle }}{% endtrans %}"
href="{{ pathto('_static/opensearch.xml', 1) }}"/>
{%- endif %}
{%- endif %}
{%- endblock %}
{%- block linktags %}
{%- if hasdoc('about') %}
<link rel="author" title="{{ _('About these documents') }}" href="{{ pathto('about') }}" />
{%- endif %}
{%- if hasdoc('genindex') %}
<link rel="index" title="{{ _('Index') }}" href="{{ pathto('genindex') }}" />
{%- endif %}
{%- if hasdoc('search') %}
<link rel="search" title="{{ _('Search') }}" href="{{ pathto('search') }}" />
{%- endif %}
{%- if hasdoc('copyright') %}
<link rel="copyright" title="{{ _('Copyright') }}" href="{{ pathto('copyright') }}" />
{%- endif %}
{%- if next %}
<link rel="next" title="{{ next.title|striptags|e }}" href="{{ next.link|e }}" />
{%- endif %}
{%- if prev %}
<link rel="prev" title="{{ prev.title|striptags|e }}" href="{{ prev.link|e }}" />
{%- endif %}
{%- endblock %}
{%- block extrahead %} {% endblock %}
</head>
<body class="wy-body-for-nav">
{% block extrabody %} {% endblock %}
<div class="wy-grid-for-nav">
{# SIDE NAV, TOGGLES ON MOBILE #}
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search" {% if theme_style_nav_header_background %} style="background: {{theme_style_nav_header_background}}" {% endif %}>
{% block sidebartitle %}
{% if logo and theme_logo_only %}
<a href="{{ pathto(master_doc) }}">
{% else %}
<a href="{{ pathto(master_doc) }}" class="icon icon-home" alt="{{ _("Documentation Home") }}"> {{ project }}
{% endif %}
{% if logo %}
{# Not strictly valid HTML, but it's the only way to display/scale
it properly, without weird scripting or heaps of work
#}
<img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="{{ _('Logo') }}"/>
{% endif %}
</a>
{% if theme_display_version %}
{%- set nav_version = version %}
{% if READTHEDOCS and current_version %}
{%- set nav_version = current_version %}
{% endif %}
{% if nav_version %}
<div class="version">
{{ nav_version }}
</div>
{% endif %}
{% endif %}
{% include "searchbox.html" %}
{% endblock %}
</div>
{% block navigation %}
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
{% block menu %}
{#
The singlehtml builder doesn't handle this toctree call when the
toctree is empty. Skip building this for now.
#}
{% if 'singlehtml' not in builder %}
{% set global_toc = toctree(maxdepth=theme_navigation_depth|int,
collapse=theme_collapse_navigation|tobool,
includehidden=theme_includehidden|tobool,
titles_only=theme_titles_only|tobool) %}
{% endif %}
{% if global_toc %}
{{ global_toc }}
{% else %}
<!-- Local TOC -->
<div class="local-toc">{{ toc }}</div>
{% endif %}
{% endblock %}
</div>
{% endblock %}
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
{# MOBILE NAV, TRIGGLES SIDE NAV ON TOGGLE #}
<nav class="wy-nav-top" aria-label="top navigation">
{% block mobile_nav %}
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="{{ pathto(master_doc) }}">{{ project }}</a>
{% endblock %}
</nav>
<div class="wy-nav-content">
{%- block content %}
{% if theme_style_external_links|tobool %}
<div class="rst-content style-external-links">
{% else %}
<div class="rst-content">
{% endif %}
{% include "breadcrumbs.html" %}
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
{%- block document %}
<div itemprop="articleBody">
{% block body %}{% endblock %}
</div>
{% if self.comments()|trim %}
<div class="articleComments">
{% block comments %}{% endblock %}
</div>
{% endif%}
</div>
{%- endblock %}
{% include "footer.html" %}
</div>
{%- endblock %}
</div>
</section>
</div>
{% include "versions.html" %}
<script type="text/javascript">
jQuery(function () {
SphinxRtdTheme.Navigation.enable({{ 'true' if theme_sticky_navigation|tobool else 'false' }});
});
</script>
{# Do not conflict with RTD insertion of analytics script #}
{% if not READTHEDOCS %}
{% if theme_analytics_id %}
<!-- Theme Analytics -->
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', '{{ theme_analytics_id }}', 'auto');
ga('send', 'pageview');
</script>
{% endif %}
{% endif %}
{%- block footer %} {% endblock %}
</body>
</html>

View File

@@ -0,0 +1,208 @@
# German translations for sphinx_rtd_theme.
# Copyright (C) 2018 Read the Docs
# This file is distributed under the same license as the sphinx_rtd_theme
# project.
# Dennis Wegner <dennis@instant-thinking.de>, 2018.
msgid ""
msgstr ""
"Project-Id-Version: sphinx_rtd_theme 0.2.4\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2019-07-24 23:51-0600\n"
"PO-Revision-Date: 2020-01-30 12:53+0100\n"
"Last-Translator: Jan Niklas Hasse <jhasse@bixense.com>\n"
"Language-Team: German Team\n"
"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"Generated-By: Babel 2.4.0\n"
"X-Generator: Poedit 2.2.4\n"
#: sphinx_rtd_theme/breadcrumbs.html:31
msgid "Docs"
msgstr "Dokumente"
#: sphinx_rtd_theme/breadcrumbs.html:43 sphinx_rtd_theme/breadcrumbs.html:45
msgid "Edit on GitHub"
msgstr "Auf GitHub bearbeiten"
#: sphinx_rtd_theme/breadcrumbs.html:50 sphinx_rtd_theme/breadcrumbs.html:52
msgid "Edit on Bitbucket"
msgstr "Auf Bitbucket bearbeiten"
#: sphinx_rtd_theme/breadcrumbs.html:57 sphinx_rtd_theme/breadcrumbs.html:59
msgid "Edit on GitLab"
msgstr "Auf GitLab bearbeiten"
#: sphinx_rtd_theme/breadcrumbs.html:62 sphinx_rtd_theme/breadcrumbs.html:64
msgid "View page source"
msgstr "Seitenquelltext anzeigen"
#: sphinx_rtd_theme/breadcrumbs.html:74 sphinx_rtd_theme/footer.html:5
msgid "Next"
msgstr "Weiter"
#: sphinx_rtd_theme/breadcrumbs.html:77 sphinx_rtd_theme/footer.html:8
msgid "Previous"
msgstr "Zurück"
#: sphinx_rtd_theme/footer.html:21 sphinx_rtd_theme/footer.html:24
#: sphinx_rtd_theme/layout.html:92
msgid "Copyright"
msgstr "Copyright"
#. Build is a noun, not a verb
#: sphinx_rtd_theme/footer.html:31
msgid "Build"
msgstr "Build"
#: sphinx_rtd_theme/footer.html:36
msgid "Revision"
msgstr "Revision"
#: sphinx_rtd_theme/footer.html:40
#, python-format
msgid "Last updated on %(last_updated)s."
msgstr "Zuletzt aktualisiert am %(last_updated)s."
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "Built with %(sphinx_web)s using a"
msgstr "Erstellt mit %(sphinx_web)s unter Verwendung eines"
#: sphinx_rtd_theme/footer.html:50
msgid "theme"
msgstr "Themes"
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "provided by %(readthedocs_web)s"
msgstr "von %(readthedocs_web)s"
#: sphinx_rtd_theme/layout.html:61
#, python-format
msgid "Search within %(docstitle)s"
msgstr "Suche in %(docstitle)s"
#: sphinx_rtd_theme/layout.html:83
msgid "About these documents"
msgstr "Über diese Dokumente"
#: sphinx_rtd_theme/layout.html:86
msgid "Index"
msgstr "Index"
#: sphinx_rtd_theme/layout.html:89 sphinx_rtd_theme/search.html:11
msgid "Search"
msgstr "Suche"
#: sphinx_rtd_theme/layout.html:124
msgid "Logo"
msgstr "Logo"
#: sphinx_rtd_theme/search.html:26
msgid "Please activate JavaScript to enable the search functionality."
msgstr "Bitte JavaScript aktivieren um die Suchfunktion zu ermöglichen."
#. Search is a noun, not a verb
#: sphinx_rtd_theme/search.html:34
msgid "Search Results"
msgstr "Suchergebnisse"
#: sphinx_rtd_theme/search.html:36
msgid ""
"Your search did not match any documents. Please make sure that all words are "
"spelled correctly and that you've selected enough categories."
msgstr ""
"Deine Suche ergab keine Treffer. Bitte stelle sicher, dass alle Wörter "
"richtig geschrieben sind und du genug Kategorien ausgewählt hast."
#: sphinx_rtd_theme/searchbox.html:4
msgid "Search docs"
msgstr "Dokumentation durchsuchen"
#: sphinx_rtd_theme/versions.html:11
msgid "Versions"
msgstr "Versionen"
#: sphinx_rtd_theme/versions.html:17
msgid "Downloads"
msgstr "Downloads"
#. The phrase "Read the Docs" is not translated
#: sphinx_rtd_theme/versions.html:24
msgid "On Read the Docs"
msgstr "Auf Read the Docs"
#: sphinx_rtd_theme/versions.html:26
msgid "Project Home"
msgstr "Projektseite"
#: sphinx_rtd_theme/versions.html:29
msgid "Builds"
msgstr "Builds"
#: sphinx_rtd_theme/versions.html:33
msgid "Free document hosting provided by"
msgstr "Kostenloses Dokumenten-Hosting von"
#~ msgid "&copy; <a href=\"%(path)s\">Copyright</a> %(copyright)s."
#~ msgstr "&copy; <a href=\\\"%(path)s\\\">Copyright</a> %(copyright)s."
#~ msgid "&copy; Copyright %(copyright)s."
#~ msgstr "&copy; Copyright %(copyright)s."
#~ msgid ""
#~ "\n"
#~ " <span class=\"build\">\n"
#~ " Build\n"
#~ " <a href=\"%(build_url)s\">%(build_id)s</a>.\n"
#~ " </span>\n"
#~ " "
#~ msgstr ""
#~ "\n"
#~ " <span class=\"build\">\n"
#~ " Build\n"
#~ " <a href=\"%(build_url)s\">%(build_id)s</a>.\n"
#~ " </span>\n"
#~ " "
#~ msgid ""
#~ "\n"
#~ " <span class=\"commit\">\n"
#~ " Revision <code>%(commit)s</code>.\n"
#~ " </span>\n"
#~ " "
#~ msgstr ""
#~ "\n"
#~ " <span class=\"commit\">\n"
#~ " Revision <code>%(commit)s</code>.\n"
#~ " </span>\n"
#~ " "
#~ msgid ""
#~ "Built with <a href=\"http://sphinx-doc.org/\">Sphinx</a> using a <a href="
#~ "\"https://github.com/snide/sphinx_rtd_theme\">theme</a> provided by <a "
#~ "href=\"https://readthedocs.org\">Read the Docs</a>"
#~ msgstr ""
#~ "Erstellt mit <a href=\"http://sphinx-doc.org/\">Sphinx</a> unter "
#~ "Verwendung eines <a href=\"https://github.com/snide/sphinx_rtd_theme"
#~ "\">Themes</a> von <a href=\"https://readthedocs.org\">Read the Docs</a>"
#~ msgid "Navigation"
#~ msgstr "Navigation"
#~ msgid ""
#~ "Created using <a href=\"http://sphinx-doc.org/\">Sphinx</a> "
#~ "%(sphinx_version)s."
#~ msgstr ""
#~ "Erstellt mit <a href=\"http://sphinx-doc.org/\">Sphinx</a> "
#~ "%(sphinx_version)s."
#~ msgid ""
#~ "Free document hosting provided by <a href=\"http://www.readthedocs.org"
#~ "\">Read the Docs</a>."
#~ msgstr ""
#~ "Dokumentationshosting gratis bei <a href=\"http://www.readthedocs.org"
#~ "\">Read the Docs</a>."

View File

@@ -0,0 +1,147 @@
# English translations for sphinx_rtd_theme.
# Copyright (C) 2019 ORGANIZATION
# This file is distributed under the same license as the sphinx_rtd_theme
# project.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2019.
#
msgid ""
msgstr ""
"Project-Id-Version: sphinx_rtd_theme 0.4.3.dev0\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2019-07-24 23:51-0600\n"
"PO-Revision-Date: 2019-07-16 15:43-0600\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language: en\n"
"Language-Team: en <LL@li.org>\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.7.0\n"
#: sphinx_rtd_theme/breadcrumbs.html:31
msgid "Docs"
msgstr ""
#: sphinx_rtd_theme/breadcrumbs.html:43 sphinx_rtd_theme/breadcrumbs.html:45
msgid "Edit on GitHub"
msgstr ""
#: sphinx_rtd_theme/breadcrumbs.html:50 sphinx_rtd_theme/breadcrumbs.html:52
msgid "Edit on Bitbucket"
msgstr ""
#: sphinx_rtd_theme/breadcrumbs.html:57 sphinx_rtd_theme/breadcrumbs.html:59
msgid "Edit on GitLab"
msgstr ""
#: sphinx_rtd_theme/breadcrumbs.html:62 sphinx_rtd_theme/breadcrumbs.html:64
msgid "View page source"
msgstr ""
#: sphinx_rtd_theme/breadcrumbs.html:74 sphinx_rtd_theme/footer.html:5
msgid "Next"
msgstr ""
#: sphinx_rtd_theme/breadcrumbs.html:77 sphinx_rtd_theme/footer.html:8
msgid "Previous"
msgstr ""
#: sphinx_rtd_theme/footer.html:21 sphinx_rtd_theme/footer.html:24
#: sphinx_rtd_theme/layout.html:92
msgid "Copyright"
msgstr ""
#. Build is a noun, not a verb
#: sphinx_rtd_theme/footer.html:31
msgid "Build"
msgstr ""
#: sphinx_rtd_theme/footer.html:36
msgid "Revision"
msgstr ""
#: sphinx_rtd_theme/footer.html:40
#, python-format
msgid "Last updated on %(last_updated)s."
msgstr ""
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "Built with %(sphinx_web)s using a"
msgstr ""
#: sphinx_rtd_theme/footer.html:50
msgid "theme"
msgstr ""
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "provided by %(readthedocs_web)s"
msgstr ""
#: sphinx_rtd_theme/layout.html:61
#, python-format
msgid "Search within %(docstitle)s"
msgstr ""
#: sphinx_rtd_theme/layout.html:83
msgid "About these documents"
msgstr ""
#: sphinx_rtd_theme/layout.html:86
msgid "Index"
msgstr ""
#: sphinx_rtd_theme/layout.html:89 sphinx_rtd_theme/search.html:11
msgid "Search"
msgstr ""
#: sphinx_rtd_theme/layout.html:124
msgid "Logo"
msgstr ""
#: sphinx_rtd_theme/search.html:26
msgid "Please activate JavaScript to enable the search functionality."
msgstr ""
#. Search is a noun, not a verb
#: sphinx_rtd_theme/search.html:34
msgid "Search Results"
msgstr ""
#: sphinx_rtd_theme/search.html:36
msgid ""
"Your search did not match any documents. Please make sure that all words "
"are spelled correctly and that you've selected enough categories."
msgstr ""
#: sphinx_rtd_theme/searchbox.html:4
msgid "Search docs"
msgstr ""
#: sphinx_rtd_theme/versions.html:11
msgid "Versions"
msgstr ""
#: sphinx_rtd_theme/versions.html:17
msgid "Downloads"
msgstr ""
#. The phrase "Read the Docs" is not translated
#: sphinx_rtd_theme/versions.html:24
msgid "On Read the Docs"
msgstr ""
#: sphinx_rtd_theme/versions.html:26
msgid "Project Home"
msgstr ""
#: sphinx_rtd_theme/versions.html:29
msgid "Builds"
msgstr ""
#: sphinx_rtd_theme/versions.html:33
msgid "Free document hosting provided by"
msgstr ""

View File

@@ -0,0 +1,149 @@
# Spanish translations for sphinx_rtd_theme.
# Copyright (C) 2019 Read the Docs, Inc
# This file is distributed under the same license as the sphinx_rtd_theme
# project.
msgid ""
msgstr ""
"Project-Id-Version: sphinx_rtd_theme 0.4.3.dev0\n"
"Report-Msgid-Bugs-To: support@readthedocs.org\n"
"POT-Creation-Date: 2019-07-24 23:51-0600\n"
"PO-Revision-Date: 2019-07-16 21:44+0000\n"
"Last-Translator: Anthony <aj@ohess.org>, 2019\n"
"Language: es\n"
"Language-Team: Spanish "
"(https://www.transifex.com/readthedocs/teams/101354/es/)\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.7.0\n"
#: sphinx_rtd_theme/breadcrumbs.html:31
msgid "Docs"
msgstr "Documentos"
#: sphinx_rtd_theme/breadcrumbs.html:43 sphinx_rtd_theme/breadcrumbs.html:45
msgid "Edit on GitHub"
msgstr "Editar en GitHub"
#: sphinx_rtd_theme/breadcrumbs.html:50 sphinx_rtd_theme/breadcrumbs.html:52
msgid "Edit on Bitbucket"
msgstr "Editar en Bitbucket"
#: sphinx_rtd_theme/breadcrumbs.html:57 sphinx_rtd_theme/breadcrumbs.html:59
msgid "Edit on GitLab"
msgstr "Editar en GitLab"
#: sphinx_rtd_theme/breadcrumbs.html:62 sphinx_rtd_theme/breadcrumbs.html:64
msgid "View page source"
msgstr "Ver código fuente de la página"
#: sphinx_rtd_theme/breadcrumbs.html:74 sphinx_rtd_theme/footer.html:5
msgid "Next"
msgstr "Siguiente"
#: sphinx_rtd_theme/breadcrumbs.html:77 sphinx_rtd_theme/footer.html:8
msgid "Previous"
msgstr "Anterior"
#: sphinx_rtd_theme/footer.html:21 sphinx_rtd_theme/footer.html:24
#: sphinx_rtd_theme/layout.html:92
msgid "Copyright"
msgstr "Derechos de autor"
#. Build is a noun, not a verb
#: sphinx_rtd_theme/footer.html:31
msgid "Build"
msgstr "Construido"
#: sphinx_rtd_theme/footer.html:36
msgid "Revision"
msgstr "Revisión"
#: sphinx_rtd_theme/footer.html:40
#, python-format
msgid "Last updated on %(last_updated)s."
msgstr "Actualizado por última vez en %(last_updated)s."
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "Built with %(sphinx_web)s using a"
msgstr "Construido con %(sphinx_web)s usando un"
#: sphinx_rtd_theme/footer.html:50
msgid "theme"
msgstr "tema"
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "provided by %(readthedocs_web)s"
msgstr "proporcionado por %(readthedocs_web)s"
#: sphinx_rtd_theme/layout.html:61
#, python-format
msgid "Search within %(docstitle)s"
msgstr "Buscar en %(docstitle)s"
#: sphinx_rtd_theme/layout.html:83
msgid "About these documents"
msgstr "Sobre esta documentación"
#: sphinx_rtd_theme/layout.html:86
msgid "Index"
msgstr "Índice"
#: sphinx_rtd_theme/layout.html:89 sphinx_rtd_theme/search.html:11
msgid "Search"
msgstr "Búsqueda"
#: sphinx_rtd_theme/layout.html:124
msgid "Logo"
msgstr "Logotipo"
#: sphinx_rtd_theme/search.html:26
msgid "Please activate JavaScript to enable the search functionality."
msgstr "Por favor, active JavaScript para habilitar la funcionalidad de búsqueda."
#. Search is a noun, not a verb
#: sphinx_rtd_theme/search.html:34
msgid "Search Results"
msgstr "Resultados de la búsqueda"
#: sphinx_rtd_theme/search.html:36
msgid ""
"Your search did not match any documents. Please make sure that all words "
"are spelled correctly and that you've selected enough categories."
msgstr ""
"Su búsqueda no coincide con ningún documento. Por favor, asegúrese de que"
" todas las palabras estén correctamente escritas y que usted haya "
"seleccionado las suficientes categorías."
#: sphinx_rtd_theme/searchbox.html:4
msgid "Search docs"
msgstr "Buscar documentos"
#: sphinx_rtd_theme/versions.html:11
msgid "Versions"
msgstr "Versiones"
#: sphinx_rtd_theme/versions.html:17
msgid "Downloads"
msgstr "Descargas"
#. The phrase "Read the Docs" is not translated
#: sphinx_rtd_theme/versions.html:24
msgid "On Read the Docs"
msgstr "En Read the Docs"
#: sphinx_rtd_theme/versions.html:26
msgid "Project Home"
msgstr "Página de Proyecto"
#: sphinx_rtd_theme/versions.html:29
msgid "Builds"
msgstr "Construcciones"
#: sphinx_rtd_theme/versions.html:33
msgid "Free document hosting provided by"
msgstr "Alojamiento gratuito de documentos proporcionado por"

View File

@@ -0,0 +1,152 @@
# English translations for sphinx_rtd_theme.
# Copyright (C) 2019 ORGANIZATION
# This file is distributed under the same license as the sphinx_rtd_theme
# project.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2019.
#
# Translators:
# Jesse Tan, 2019
msgid ""
msgstr ""
"Project-Id-Version: sphinx_rtd_theme 0.4.3.dev0\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2019-07-24 23:51-0600\n"
"PO-Revision-Date: 2019-07-16 21:44+0000\n"
"Last-Translator: Jesse Tan, 2019\n"
"Language: nl\n"
"Language-Team: Dutch "
"(https://www.transifex.com/readthedocs/teams/101354/nl/)\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: Babel 2.7.0\n"
#: sphinx_rtd_theme/breadcrumbs.html:31
msgid "Docs"
msgstr "Documentatie"
#: sphinx_rtd_theme/breadcrumbs.html:43 sphinx_rtd_theme/breadcrumbs.html:45
msgid "Edit on GitHub"
msgstr "Bewerk op GitHub"
#: sphinx_rtd_theme/breadcrumbs.html:50 sphinx_rtd_theme/breadcrumbs.html:52
msgid "Edit on Bitbucket"
msgstr "Bewerk op BitBucket"
#: sphinx_rtd_theme/breadcrumbs.html:57 sphinx_rtd_theme/breadcrumbs.html:59
msgid "Edit on GitLab"
msgstr "Bewerk op GitLab"
#: sphinx_rtd_theme/breadcrumbs.html:62 sphinx_rtd_theme/breadcrumbs.html:64
msgid "View page source"
msgstr "Bekijk paginabron"
#: sphinx_rtd_theme/breadcrumbs.html:74 sphinx_rtd_theme/footer.html:5
msgid "Next"
msgstr "Volgende"
#: sphinx_rtd_theme/breadcrumbs.html:77 sphinx_rtd_theme/footer.html:8
msgid "Previous"
msgstr "Vorige"
#: sphinx_rtd_theme/footer.html:21 sphinx_rtd_theme/footer.html:24
#: sphinx_rtd_theme/layout.html:92
msgid "Copyright"
msgstr "Copyright"
#. Build is a noun, not a verb
#: sphinx_rtd_theme/footer.html:31
msgid "Build"
msgstr "Bouwsel"
#: sphinx_rtd_theme/footer.html:36
msgid "Revision"
msgstr "Revisie"
#: sphinx_rtd_theme/footer.html:40
#, python-format
msgid "Last updated on %(last_updated)s."
msgstr "Laatste update op %(last_updated)s."
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "Built with %(sphinx_web)s using a"
msgstr "Gebouwd met %(sphinx_web)s met een"
#: sphinx_rtd_theme/footer.html:50
msgid "theme"
msgstr "thema"
#: sphinx_rtd_theme/footer.html:50
#, python-format
msgid "provided by %(readthedocs_web)s"
msgstr "geleverd door %(readthedocs_web)s"
#: sphinx_rtd_theme/layout.html:61
#, python-format
msgid "Search within %(docstitle)s"
msgstr "Zoek binnen %(docstitle)s"
#: sphinx_rtd_theme/layout.html:83
msgid "About these documents"
msgstr "Over deze documenten"
#: sphinx_rtd_theme/layout.html:86
msgid "Index"
msgstr "Index"
#: sphinx_rtd_theme/layout.html:89 sphinx_rtd_theme/search.html:11
msgid "Search"
msgstr "Zoek"
#: sphinx_rtd_theme/layout.html:124
msgid "Logo"
msgstr "Logo"
#: sphinx_rtd_theme/search.html:26
msgid "Please activate JavaScript to enable the search functionality."
msgstr "Zet JavaScript aan om de zoekfunctie mogelijk te maken."
#. Search is a noun, not a verb
#: sphinx_rtd_theme/search.html:34
msgid "Search Results"
msgstr "Zoekresultaten"
#: sphinx_rtd_theme/search.html:36
msgid ""
"Your search did not match any documents. Please make sure that all words "
"are spelled correctly and that you've selected enough categories."
msgstr ""
"Zoekpoging vond geen documenten. Zorg ervoor dat alle woorden correct "
"zijn gespeld en dat voldoende categorieën zijn geselecteerd."
#: sphinx_rtd_theme/searchbox.html:4
msgid "Search docs"
msgstr "Zoek in documentatie"
#: sphinx_rtd_theme/versions.html:11
msgid "Versions"
msgstr "Versies"
#: sphinx_rtd_theme/versions.html:17
msgid "Downloads"
msgstr "Downloads"
#. The phrase "Read the Docs" is not translated
#: sphinx_rtd_theme/versions.html:24
msgid "On Read the Docs"
msgstr "Op Read the Docs"
#: sphinx_rtd_theme/versions.html:26
msgid "Project Home"
msgstr "Project Home"
#: sphinx_rtd_theme/versions.html:29
msgid "Builds"
msgstr "Bouwsels"
#: sphinx_rtd_theme/versions.html:33
msgid "Free document hosting provided by"
msgstr "Gratis hosting voor documentatie verzorgd door"

Some files were not shown because too many files have changed in this diff Show More