From 7298ad9b8ab6fb93647d81ba5ebd6f2c49d3c77f Mon Sep 17 00:00:00 2001 From: simondlevy Date: Wed, 4 Jul 2018 15:40:59 -0400 Subject: [PATCH] Passing angles, size to scan_update() --- c/coreslam.c | 2 ++ python/pybreezyslam.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/c/coreslam.c b/c/coreslam.c index b6dd380..35ae1fb 100644 --- a/c/coreslam.c +++ b/c/coreslam.c @@ -439,6 +439,8 @@ scan_update( double velocities_dxy_mm, double velocities_dtheta_degrees) { + printf("%p %d\n", lidar_angles_deg, scan_size); + /* Take velocity into account */ int degrees_per_second = (int)(scan->rate_hz * 360); double horz_mm = velocities_dxy_mm / degrees_per_second; diff --git a/python/pybreezyslam.c b/python/pybreezyslam.c index 9367030..ca66f9f 100644 --- a/python/pybreezyslam.c +++ b/python/pybreezyslam.c @@ -353,7 +353,7 @@ Scan_update(Scan *self, PyObject *args, PyObject *kwds) // Update the scan scan_update( &self->scan, - NULL, + (py_scan_angles_degrees != Py_None) ? self->lidar_angles_deg :NULL, self->lidar_distances_mm, PyList_Size(py_lidar), hole_width_mm,