Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,20 @@ set(INCLUDE_DIRECTORIES
${PROJECT_SOURCE_DIR}/../include/cpp)

if(UNIX)
set(DEP_LIB_DIR ${PROJECT_SOURCE_DIR}/../libs/linux)
string(TOLOWER "${CMAKE_SYSTEM_PROCESSOR}" DEXCAP_ARCH)
if(DEXCAP_ARCH MATCHES "^(x86_64|amd64)$")
set(DEP_LIB_DIR "${PROJECT_SOURCE_DIR}/../libs/linux/x86_64")
elseif(DEXCAP_ARCH MATCHES "^(aarch64|arm64)$")
set(DEP_LIB_DIR "${PROJECT_SOURCE_DIR}/../libs/linux/aarch64")
else()
message(FATAL_ERROR
"Unsupported Linux architecture: ${CMAKE_SYSTEM_PROCESSOR}. "
"Supported: x86_64, aarch64.")
endif()
elseif(WIN32)
set(DEP_LIB_DIR "${PROJECT_SOURCE_DIR}/../libs/windows")
else()
set(DEP_LIB_DIR ${PROJECT_SOURCE_DIR}/../libs/windows)
message(FATAL_ERROR "Unsupported platform.")
endif()

if(UNIX)
Expand Down
2 changes: 2 additions & 0 deletions include/configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include<Windows.h>
#endif

#include <yaml-cpp/yaml.h>
#include "cpp/TypeDef.hpp"

#ifdef __cplusplus
Expand Down Expand Up @@ -113,6 +114,7 @@ class DexCapConfig final

private:

YAML::Node configuration;

};

Expand Down
2 changes: 1 addition & 1 deletion include/cpp/DexCap.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ class DexCapSuit

[[nodiscard]] const DexCapEndPoses & GetEndPose() const;

[[nodiscard]] uint16_t GetBatteryLevel(ExoApparatus device) const;
[[nodiscard]] uint16_t GetBatteryLevel(ExoApparatus device);
[[nodiscard]] const MainBatteryState *GetMainBatteryState() const;

void VibeMotors(ExoApparatus hand, const std::vector<uint8_t> &) const;
Expand Down
2 changes: 1 addition & 1 deletion include/typedef.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ extern "C"

#ifndef _WIN32
#ifndef BOOL
#define BOOL int
#define BOOL unsigned char
#else
#undef BOOL
#define BOOL int
Expand Down
Binary file modified libs/linux/x86_64/libDexCap.so
Binary file not shown.