From 1836182e241800b0680390ed2286cda40b031ab6 Mon Sep 17 00:00:00 2001 From: Moses Turner <moses@collabora.com> Date: Sun, 18 Sep 2022 08:10:01 -0500 Subject: [PATCH] t/common: Remove superfluous PID/VIDs from SimulaVR builder And remove outdated comments --- .../targets/common/target_builder_simulavr.c | 24 +++++-------------- 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/src/xrt/targets/common/target_builder_simulavr.c b/src/xrt/targets/common/target_builder_simulavr.c index b71893b00..01f360061 100644 --- a/src/xrt/targets/common/target_builder_simulavr.c +++ b/src/xrt/targets/common/target_builder_simulavr.c @@ -49,12 +49,6 @@ static const char *driver_list[] = { "simula", }; -#define MOVIDIUS_VID 0x03E7 -#define MOVIDIUS_PID 0x2150 - -#define TM2_VID 0x8087 -#define TM2_PID 0x0B37 - struct simula_builder { struct xrt_builder base; @@ -73,12 +67,6 @@ process_poly_values(const cJSON *values, struct svr_display_distortion_polynomia return good; } -// struct svr_two_displays_distortion -// process_eye_config(cJSON *config_json) -// { - -// } - static bool process_config(const char *config_path, struct svr_two_displays_distortion *out_dist) { @@ -175,15 +163,18 @@ svr_estimate_system(struct xrt_builder *xb, cJSON *config, struct xrt_prober *xp return xret; } - bool movidius = u_builder_find_prober_device(xpdevs, xpdev_count, MOVIDIUS_VID, MOVIDIUS_PID, XRT_BUS_TYPE_USB); - bool tm2 = u_builder_find_prober_device(xpdevs, xpdev_count, TM2_VID, TM2_PID, XRT_BUS_TYPE_USB); + bool movidius = u_builder_find_prober_device(xpdevs, xpdev_count, REALSENSE_MOVIDIUS_VID, + REALSENSE_MOVIDIUS_PID, XRT_BUS_TYPE_USB); + bool tm2 = + u_builder_find_prober_device(xpdevs, xpdev_count, REALSENSE_TM2_VID, REALSENSE_TM2_PID, XRT_BUS_TYPE_USB); if (!movidius && !tm2) { U_LOG_E("Simula enabled but couldn't find realsense device!"); return XRT_SUCCESS; } - // I think that ideally we want `movidius` - in that case I think when we grab the device, it reboots to `tm2` + // I think that ideally we want `movidius` - in that case I think when we grab the device, it reboots to + // `tm2` estimate->maybe.head = true; @@ -206,9 +197,6 @@ svr_open_system(struct xrt_builder *xb, cJSON *config, struct xrt_prober *xp, st goto end; } - - // The below is a garbage hack - we should remove the autoprober entirely - but I'm tired af and need to ship it - struct xrt_device *t265_dev = rs_create_tracked_device_internal_slam(xp); struct xrt_device *svr_dev = svr_hmd_create(&sb->display_distortion);