diff --git a/cmake/Depthai/DepthaiDeviceSideConfig.cmake b/cmake/Depthai/DepthaiDeviceSideConfig.cmake index 4d7be1819..62fcd606c 100644 --- a/cmake/Depthai/DepthaiDeviceSideConfig.cmake +++ b/cmake/Depthai/DepthaiDeviceSideConfig.cmake @@ -2,7 +2,7 @@ set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot") # "full commit hash of device side binary" -set(DEPTHAI_DEVICE_SIDE_COMMIT "cee0e0be66ae6b1cce48fcbb75a83676aea5c5fc") +set(DEPTHAI_DEVICE_SIDE_COMMIT "762b13707068b5279c822a245602d43778442153") # "version if applicable" set(DEPTHAI_DEVICE_SIDE_VERSION "") diff --git a/include/depthai/pipeline/datatype/CameraControl.hpp b/include/depthai/pipeline/datatype/CameraControl.hpp index a1ffb7db7..4408dd96b 100644 --- a/include/depthai/pipeline/datatype/CameraControl.hpp +++ b/include/depthai/pipeline/datatype/CameraControl.hpp @@ -292,6 +292,41 @@ class CameraControl : public Buffer { */ CameraControl& setCaptureIntent(CaptureIntent mode); + /** + * Set a miscellaneous control. The controls set by this function get appended + * to a list, processed after the standard controls + * @param control Control name + * @param value Value as a string + */ + CameraControl& setMisc(std::string control, std::string value); + + /** + * Set a miscellaneous control. The controls set by this function get appended + * to a list, processed after the standard controls + * @param control Control name + * @param value Value as an integer number + */ + CameraControl& setMisc(std::string control, int value); + + /** + * Set a miscellaneous control. The controls set by this function get appended + * to a list, processed after the standard controls + * @param control Control name + * @param value Value as a floating point number + */ + CameraControl& setMisc(std::string control, float value); + + /** + * Clear the list of miscellaneous controls set by `setControl` + */ + void clearMiscControls(); + + /** + * Get the list of miscellaneous controls set by `setControl` + * @returns A list of pairs as strings + */ + std::vector> getMiscControls(); + // Functions to retrieve properties /** * Check whether command to capture a still is set diff --git a/shared/depthai-shared b/shared/depthai-shared index 8158fa678..5dece0072 160000 --- a/shared/depthai-shared +++ b/shared/depthai-shared @@ -1 +1 @@ -Subproject commit 8158fa678970af1b10334278dbcc544556372e9f +Subproject commit 5dece007271e1d61dfd1078991b7f911caa7c2eb diff --git a/src/pipeline/datatype/CameraControl.cpp b/src/pipeline/datatype/CameraControl.cpp index 0e9238576..f25e01b3c 100644 --- a/src/pipeline/datatype/CameraControl.cpp +++ b/src/pipeline/datatype/CameraControl.cpp @@ -215,6 +215,23 @@ CameraControl& CameraControl::setCaptureIntent(CaptureIntent mode) { return *this; } +CameraControl& CameraControl::setMisc(std::string control, std::string value) { + cfg.miscControls.push_back(std::make_pair(control, value)); + return *this; +} +CameraControl& CameraControl::setMisc(std::string control, int value) { + return setMisc(control, std::to_string(value)); +} +CameraControl& CameraControl::setMisc(std::string control, float value) { + return setMisc(control, std::to_string(value)); +} +void CameraControl::clearMiscControls() { + cfg.miscControls.clear(); +} +std::vector> CameraControl::getMiscControls() { + return cfg.miscControls; +} + bool CameraControl::getCaptureStill() const { return cfg.getCommand(RawCameraControl::Command::STILL_CAPTURE); }