Skip to content

Commit

Permalink
Enforce HA option for MIPI SKU
Browse files Browse the repository at this point in the history
  • Loading branch information
ev-mp committed Nov 6, 2022
1 parent 4bd7ae1 commit 18af76b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
10 changes: 6 additions & 4 deletions common/on-chip-calib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@ namespace rs2
on_chip_calib_manager::on_chip_calib_manager(viewer_model& viewer, std::shared_ptr<subdevice_model> sub, device_model& model, device dev, std::shared_ptr<subdevice_model> sub_color, bool uvmapping_calib_full)
: process_manager("On-Chip Calibration"), _model(model), _dev(dev), _sub(sub), _viewer(viewer), _sub_color(sub_color), py_px_only(!uvmapping_calib_full)
{
device_id_string = "Unknown";
if (dev.supports(RS2_CAMERA_INFO_PRODUCT_ID))
{
std::string dev_pid = dev.get_info(RS2_CAMERA_INFO_PRODUCT_ID);
if (val_in_range(dev_pid, { std::string("0AD3") }))
device_id_string = _dev.get_info(RS2_CAMERA_INFO_PRODUCT_ID);
if (val_in_range(device_id_string, { std::string("0AD3") }))
speed = 4;
}
if (dev.supports(RS2_CAMERA_INFO_FIRMWARE_VERSION))
Expand Down Expand Up @@ -2069,6 +2070,7 @@ namespace rs2
ImGui::SetTooltip("%s", "Calculate ground truth for the specific target");

ImGui::SetCursorScreenPos({ float(x + 9), float(y + height - ImGui::GetTextLineHeightWithSpacing() - 30) });
get_manager().host_assistance = (get_manager().device_id_string == std::string("ABCD") ); // To be used for MIPI SKU only
bool assistance = (get_manager().host_assistance != 0);
if (ImGui::Checkbox("Host Assistance", &assistance))
get_manager().host_assistance = (assistance ? 1 : 0);
Expand Down Expand Up @@ -2164,9 +2166,9 @@ namespace rs2
// ImGui::SetTooltip("%s", "On-Chip Calibration Extended");

ImGui::SetCursorScreenPos({ float(x + 9), float(y + height - ImGui::GetTextLineHeightWithSpacing() - 31) });
get_manager().host_assistance = (get_manager().device_id_string == std::string("ABCD") ); // To be used for MIPI SKU only
bool assistance = (get_manager().host_assistance != 0);
if (ImGui::Checkbox("Host Assistance", &assistance))
get_manager().host_assistance = (assistance ? 1 : 0);
ImGui::Checkbox("Host Assistance", &assistance);
if (ImGui::IsItemHovered())
ImGui::SetTooltip("%s", "check = host assitance for statistics data, uncheck = no host assistance");

Expand Down
1 change: 1 addition & 0 deletions common/on-chip-calib.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ namespace rs2
const std::string Y8_FORMAT = "Y8";
const std::string Z16_FORMAT = "Z16";
const std::string RGB8_FORMAT = "RGB8";
std::string device_id_string;


void calibrate();
Expand Down

0 comments on commit 18af76b

Please sign in to comment.