Skip to content

Commit

Permalink
code review minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
remibettan committed Aug 2, 2022
1 parent 04b3f25 commit 3832346
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/ds5/ds5-device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,7 @@ namespace librealsense
_hw_monitor = std::make_shared<hw_monitor>(
std::make_shared<locked_transfer>(
std::make_shared<command_transfer_over_xu>(
raw_sensor, depth_xu, DS5_HWMONITOR, mipi_sensor),
raw_sensor, depth_xu, DS5_HWMONITOR),
raw_sensor));
}
else
Expand Down
2 changes: 1 addition & 1 deletion src/linux/backend-v4l2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -656,7 +656,7 @@ namespace librealsense
// /sys/devices/pci0000:00/0000:00:xx.0/ABC/M-N/version
usb_specification = get_usb_connection_type(real_path + "/../../../");
}
else // COMMENT THIS TO MAKE USB ENUMERATION POSSIBLE - Video4Linux Devices that are not listed as UVC
else // Video4Linux Devices that are not listed as UVC
{
//LOG_INFO("Enumerating v4l " << name << " realpath=" << real_path);
v4l_node = true;
Expand Down
5 changes: 2 additions & 3 deletions src/option.h
Original file line number Diff line number Diff line change
Expand Up @@ -492,15 +492,14 @@ namespace librealsense
std::vector<uint8_t> send_receive(const std::vector<uint8_t>& data, int, bool require_response) override;

command_transfer_over_xu(uvc_sensor& uvc,
platform::extension_unit xu, uint8_t ctrl, bool is_mipi = false)
: _uvc(uvc), _xu(std::move(xu)), _ctrl(ctrl), _is_mipi(is_mipi)
platform::extension_unit xu, uint8_t ctrl)
: _uvc(uvc), _xu(std::move(xu)), _ctrl(ctrl)
{}

private:
uvc_sensor& _uvc;
platform::extension_unit _xu;
uint8_t _ctrl;
bool _is_mipi; // D457 dev- should be removed after hwm discrepancy USB/MIPI fixed in driver
};

class polling_error_handler;
Expand Down
6 changes: 3 additions & 3 deletions src/sensor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,7 @@ void log_callback_end( uint32_t fps,
stream_profiles uvc_sensor::init_stream_profiles()
{
std::unordered_set<std::shared_ptr<video_stream_profile>> video_profiles;
// D457 development
// D457 development - only via mipi imu frames com from uvc instead of hid
std::unordered_set<std::shared_ptr<motion_stream_profile>> motion_profiles;
power on(std::dynamic_pointer_cast<uvc_sensor>(shared_from_this()));

Expand Down Expand Up @@ -965,8 +965,8 @@ void log_callback_end( uint32_t fps,
last_timestamp = timestamp;
frame_holder frame = _source.alloc_frame(RS2_EXTENSION_MOTION_FRAME, data_size, fr->additional_data, true);
memcpy( (void *)frame->get_frame_data(),
/*fr->data.data()*/ sensor_data.fo.pixels,
/*fr->data.size()*/ sizeof( byte ) * sensor_data.fo.frame_size );
sensor_data.fo.pixels,
sizeof( byte ) * sensor_data.fo.frame_size );
if (!frame)
{
LOG_INFO("Dropped frame. alloc_frame(...) returned nullptr");
Expand Down

0 comments on commit 3832346

Please sign in to comment.