diff --git a/include/depthai-shared/common/ProcessorType.hpp b/include/depthai-shared/common/ProcessorType.hpp index 3c2524cf..4c8d36d1 100644 --- a/include/depthai-shared/common/ProcessorType.hpp +++ b/include/depthai-shared/common/ProcessorType.hpp @@ -3,11 +3,12 @@ #include namespace dai { + /** * On which processor the node will be placed * * Enum specifying processor */ -enum class ProcessorType : int32_t { LOS, LRT }; +enum class ProcessorType : int32_t { LEON_CSS, LEON_MSS }; } // namespace dai \ No newline at end of file diff --git a/include/depthai-shared/properties/MyProducerProperties.hpp b/include/depthai-shared/properties/MyProducerProperties.hpp index 7f3e6bf1..9a467fc2 100644 --- a/include/depthai-shared/properties/MyProducerProperties.hpp +++ b/include/depthai-shared/properties/MyProducerProperties.hpp @@ -19,7 +19,7 @@ struct MyProducerProperties { /** * On which processor the node will be placed */ - ProcessorType processorPlacement = ProcessorType::LOS; + ProcessorType processorPlacement = ProcessorType::LEON_CSS; }; NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(MyProducerProperties, message, processorPlacement); diff --git a/include/depthai-shared/properties/SPIInProperties.hpp b/include/depthai-shared/properties/SPIInProperties.hpp new file mode 100644 index 00000000..0795ba59 --- /dev/null +++ b/include/depthai-shared/properties/SPIInProperties.hpp @@ -0,0 +1,36 @@ +#pragma once + +#include + +#include "depthai-shared/xlink/XLinkConstants.hpp" + +namespace dai { + +/** + * Properties for SPIIn node + */ +struct SPIInProperties { + /** + * Name of stream + */ + std::string streamName; + + /** + * SPI bus to use + */ + int busId = 0; + + /** + * Maximum input data size + */ + std::uint32_t maxDataSize = dai::XLINK_USB_BUFFER_MAX_SIZE; + + /** + * Number of frames in pool + */ + std::uint32_t numFrames = 4; +}; + +NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(SPIInProperties, streamName, busId, maxDataSize, numFrames); + +} // namespace dai diff --git a/include/depthai-shared/properties/SPIOutProperties.hpp b/include/depthai-shared/properties/SPIOutProperties.hpp index cf33fa12..69f24ccf 100644 --- a/include/depthai-shared/properties/SPIOutProperties.hpp +++ b/include/depthai-shared/properties/SPIOutProperties.hpp @@ -1,12 +1,3 @@ -// To parse this JSON data, first install -// -// Boost http://www.boost.org -// json.hpp https://github.com/nlohmann/json -// -// Then include this file, and then do -// -// SPIOutProperties.hpp data = nlohmann::json::parse(jsonString); - #pragma once #include @@ -17,10 +8,15 @@ namespace dai { * Specify properties for SPIOut node */ struct SPIOutProperties { - /// Output stream name + /** + * Name of stream + */ std::string streamName; - /// SPI bus to use - int busId; + + /** + * SPI bus to use + */ + int busId = 0; }; NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(SPIOutProperties, streamName, busId); diff --git a/include/depthai-shared/properties/ScriptProperties.hpp b/include/depthai-shared/properties/ScriptProperties.hpp new file mode 100644 index 00000000..eaca324a --- /dev/null +++ b/include/depthai-shared/properties/ScriptProperties.hpp @@ -0,0 +1,31 @@ +#pragma once + +#include +#include +#include + +namespace dai { + +/** + * Specify ScriptProperties options such as script uri, script name, ... + */ +struct ScriptProperties { + /** + * Uri which points to actual script + */ + std::string scriptUri = ""; + + /** + * Name of script + */ + std::string scriptName = "