Skip to content

Commit f19964a

Browse files
authored
Disable Extrinsic connection check (#561)
* Removed validation check * Removed valid camera check for pipeline and factory storage too * Added seProductName function * Updated function fix * Added version update
1 parent ba9bd8b commit f19964a

File tree

4 files changed

+21
-6
lines changed

4 files changed

+21
-6
lines changed

include/depthai/device/CalibrationHandler.hpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,14 @@ class CalibrationHandler {
349349
uint32_t boardOptions,
350350
std::string boardCustom = "");
351351

352+
/**
353+
* Set the productName which acts as alisas for users to identify the device
354+
*
355+
* @param productName Sets product name (alias).
356+
*/
357+
358+
void setProductName(std::string productName);
359+
352360
/**
353361
* Set the Camera Intrinsics object
354362
*

src/device/CalibrationHandler.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -564,6 +564,13 @@ void CalibrationHandler::setBoardInfo(std::string productName,
564564
eepromData.version = 7;
565565
}
566566

567+
void CalibrationHandler::setProductName(std::string productName) {
568+
eepromData.productName = productName;
569+
570+
// Bump version to V7
571+
eepromData.version = 7;
572+
}
573+
567574
void CalibrationHandler::setCameraIntrinsics(CameraBoardSocket cameraId, std::vector<std::vector<float>> intrinsics, int width, int height) {
568575
if(intrinsics.size() != 3 || intrinsics[0].size() != 3) {
569576
throw std::runtime_error("Intrinsic Matrix size should always be 3x3 ");

src/device/DeviceBase.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -941,9 +941,9 @@ void DeviceBase::flashCalibration2(CalibrationHandler calibrationDataHandler) {
941941
getFlashingPermissions(factoryPermissions, protectedPermissions);
942942
spdlog::debug("Flashing calibration. Factory permissions {}, Protected permissions {}", factoryPermissions, protectedPermissions);
943943

944-
if(!calibrationDataHandler.validateCameraArray()) {
944+
/* if(!calibrationDataHandler.validateCameraArray()) {
945945
throw std::runtime_error("Failed to validate the extrinsics connection. Enable debug mode for more information.");
946-
}
946+
} */
947947

948948
bool success;
949949
std::string errorMsg;
@@ -989,9 +989,9 @@ void DeviceBase::flashFactoryCalibration(CalibrationHandler calibrationDataHandl
989989
throw std::runtime_error("Calling factory API is not allowed in current configuration");
990990
}
991991

992-
if(!calibrationDataHandler.validateCameraArray()) {
992+
/* if(!calibrationDataHandler.validateCameraArray()) {
993993
throw std::runtime_error("Failed to validate the extrinsics connection. Enable debug mode for more information.");
994-
}
994+
} */
995995

996996
bool success;
997997
std::string errorMsg;

src/pipeline/Pipeline.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -440,9 +440,9 @@ void PipelineImpl::unlink(const Node::Output& out, const Node::Input& in) {
440440
}
441441

442442
void PipelineImpl::setCalibrationData(CalibrationHandler calibrationDataHandler) {
443-
if(!calibrationDataHandler.validateCameraArray()) {
443+
/* if(!calibrationDataHandler.validateCameraArray()) {
444444
throw std::runtime_error("Failed to validate the extrinsics connection. Enable debug mode for more information.");
445-
}
445+
} */
446446
globalProperties.calibData = calibrationDataHandler.getEepromData();
447447
}
448448

0 commit comments

Comments
 (0)