Skip to content

Commit

Permalink
Merge pull request #1099 from luxonis/release_v2.28.0
Browse files Browse the repository at this point in the history
Release v2.28.0
  • Loading branch information
moratom authored Aug 19, 2024
2 parents 4d72946 + 6d24dba commit 12158a5
Show file tree
Hide file tree
Showing 11 changed files with 39 additions and 14 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/main.workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
cmake: ['3.10.x', ''] # Older version (Ubuntu 18.04) and newest
cmake: ['3.10.x', '3.29.x'] # Older version (Ubuntu 18.04) and newest
exclude:
- os: windows-latest
cmake: '3.10.x'
Expand Down Expand Up @@ -185,6 +185,8 @@ jobs:
- name: Setup cmake
uses: jwlawson/[email protected]
with:
cmake-version: '3.29.x'

- name: Configure ${{ matrix.build-type }}, shared ${{ matrix.shared }}, ${{ matrix.platform }}
run: cmake -S . -B build -D BUILD_SHARED_LIBS=${{ matrix.shared}} -D CMAKE_BUILD_TYPE=${{ matrix.build-type }} -D CMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/depthai_install ${{ env.CMAKE_ARGS }}
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ if(WIN32)
endif()

# Create depthai project
project(depthai VERSION "2.27.0" LANGUAGES CXX C)
project(depthai VERSION "2.28.0" LANGUAGES CXX C)
get_directory_property(has_parent PARENT_DIRECTORY)
if(has_parent)
set(DEPTHAI_VERSION ${PROJECT_VERSION} PARENT_SCOPE)
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -203,8 +203,8 @@ The following environment variables can be set to alter default behavior of the
| DEPTHAI_LIBUSB_ANDROID_JAVAVM | JavaVM pointer that is passed to libusb for rootless Android interaction with devices. Interpreted as decimal value of uintptr_t |
| DEPTHAI_CRASHDUMP | Directory in which to save the crash dump. |
| DEPTHAI_CRASHDUMP_TIMEOUT | Specifies the duration in seconds to wait for device reboot when obtaining a crash dump. Crash dump retrieval disabled if 0. |
| DEPTHAI_ENABLE_FEEDBACK_PIPELINE | Enables automatic pipeline schema collection used to improve the library |
| DEPTHAI_ENABLE_FEEDBACK_CRASHDUMP | Enables automatic crash dump collection used to improve the library |
| DEPTHAI_ENABLE_ANALYTICS_COLLECTION | Enables automatic analytics collection (pipeline schemas) used to improve the library |
| DEPTHAI_DISABLE_CRASHDUMP_COLLECTION | Disables automatic crash dump collection used to improve the library |

## Running tests

Expand Down
2 changes: 1 addition & 1 deletion cmake/Depthai/DepthaiDeviceSideConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

# "full commit hash of device side binary"
set(DEPTHAI_DEVICE_SIDE_COMMIT "9822af7082d67b87c5307b9c37ec7f6ab8e1bbce")
set(DEPTHAI_DEVICE_SIDE_COMMIT "9ed7c9ae4c232ff93a3500a585a6b1c00650e22c")

# "version if applicable"
set(DEPTHAI_DEVICE_SIDE_VERSION "")
11 changes: 6 additions & 5 deletions cmake/Hunter/config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ hunter_config(

hunter_config(
XLink
VERSION "luxonis-2021.4.2-xlink-linkid-race-fix"
URL "https://github.com/luxonis/XLink/archive/e0eddd9f98c5eacecd4134cbdb713b3d7be039b8.tar.gz"
SHA1 "c97a20d98ce3a5e35cf922c5aaad7e861569869d"
VERSION "luxonis-2021.4.2-master"
URL "https://github.com/luxonis/XLink/archive/2b517e1cb1ca77bea17679f9fdeb739812431174.tar.gz"
SHA1 "fa7eeb46abeb97626dad923b7733899198284587"
CMAKE_ARGS
XLINK_ENABLE_LIBUSB=${DEPTHAI_ENABLE_LIBUSB}
)
Expand Down Expand Up @@ -140,11 +140,12 @@ hunter_config(
BUILD_STATIC_LIBS=ON
)

# A hunterized and patched version of cpr- see https://github.com/luxonis/cpr/pull/1
hunter_config(
cpr
VERSION "1.4.0"
URL "https://github.com/luxonis/cpr/archive/a1d28dbbaccda3df8fddd993b2cd916f64f9da56.tar.gz"
SHA1 "14e18d04d05e36e920aa90ee744952bf55783ea4"
URL "https://github.com/luxonis/cpr/archive/50a1321738554e0152b0a6f1b0ca24e4fdecff5c.tar.gz"
SHA1 "2e2ba9920ed99c19887592ca89d9be5ffce4722b"
)

hunter_config(
Expand Down
1 change: 1 addition & 0 deletions src/device/DataQueue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

// libraries
#include "utility/Logging.hpp"
#include "utility/spdlog-fmt.hpp"

// Additions
#include "spdlog/fmt/bin_to_hex.h"
Expand Down
1 change: 1 addition & 0 deletions src/device/DeviceBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#include "utility/Initialization.hpp"
#include "utility/PimplImpl.hpp"
#include "utility/Resources.hpp"
#include "utility/spdlog-fmt.hpp"

// libraries
#include "XLink/XLink.h"
Expand Down
1 change: 1 addition & 0 deletions src/pipeline/datatype/StreamMessageParser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
#include <spdlog/spdlog.h>

#include "utility/Logging.hpp"
#include "utility/spdlog-fmt.hpp"

// project
#include "depthai/pipeline/datatype/ADatatype.hpp"
Expand Down
6 changes: 3 additions & 3 deletions src/utility/LogCollection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ void logPipeline(const PipelineSchema& pipelineSchema, const dai::DeviceInfo& de
#else
namespace fs = ghc::filesystem;
// Check if logging is explicitly disabled
auto loggingEnabled = utility::getEnv("DEPTHAI_ENABLE_FEEDBACK_PIPELINE");
auto loggingEnabled = utility::getEnv("DEPTHAI_ENABLE_ANALYTICS_COLLECTION");
if(loggingEnabled.empty()) {
logger::info("Logging disabled");
return;
Expand Down Expand Up @@ -218,8 +218,8 @@ void logCrashDump(const tl::optional<PipelineSchema>& pipelineSchema, const Cras
}

// Check if logging is explicitly disabled
auto loggingEnabled = utility::getEnv("DEPTHAI_ENABLE_FEEDBACK_CRASHDUMP");
if(!loggingEnabled.empty()) {
auto loggingDisabled = utility::getEnv("DEPTHAI_DISABLE_CRASHDUMP_COLLECTION");
if(loggingDisabled.empty()) {
logger::info("Logging enabled");
auto success = sendLogsToServer(pipelineData, crashDumpData, deviceInfo);
if(!success) {
Expand Down
19 changes: 19 additions & 0 deletions src/utility/spdlog-fmt.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@

#include "depthai/utility/Path.hpp"

#if FMT_VERSION >= 100000
#include <spdlog/fmt/ostr.h>

#include "depthai/common/CameraBoardSocket.hpp"
#include "depthai-shared/datatype/DatatypeEnum.hpp"
#endif

namespace dai {
namespace utility {
static constexpr char path_convert_err[] = "<Unicode path not convertible>";
Expand All @@ -25,3 +32,15 @@ struct fmt::formatter<dai::Path> : formatter<std::string> {
return formatter<std::string>::format(output, ctx);
}
};

#if FMT_VERSION >= 100000
template <>
struct fmt::formatter<dai::CameraBoardSocket> : ostream_formatter {};

template <>
struct fmt::formatter<dai::DatatypeEnum> : fmt::formatter<std::string> {
auto format(dai::DatatypeEnum my, format_context& ctx) const -> decltype(ctx.out()) {
return fmt::format_to(ctx.out(), "{}", static_cast<int32_t>(my));
}
};
#endif

0 comments on commit 12158a5

Please sign in to comment.