Main Content

preview

Preview live lidar scan data from Hokuyo 2-D lidar sensor

Since R2024a

Description

example

preview(hokuyoObj) previews live lidar scan data from the Hokuyo™ 2-D lidar sensor associated with the hokuyolidar2d object hokuyoObj. The function pauses other MATLAB processes and opens a preview window to display the lidar scan data. You must close the preview window to continue running other MATLAB® commands.

preview(hokuyoObj,ScanAngleLimits=scanAngleLimits) specifies the lower and upper limits of the scan angles for previewing the lidar scan data.

Note

This feature requires the Lidar Toolbox™ Support Package for Hokuyo Lidar Sensors. You can install the support package from the Add-On Explorer. For more information, see Download and Install Lidar Toolbox Support Package for Hokuyo Lidar Sensors.

Examples

collapse all

Create a hokuyolidar2d object.

hokuyoObj = hokuyolidar2d;

Preview the lidar scan data by using the preview function of the hokuyolidar2d object. The preview window opens. Note that you must close the preview window to run any other commands.

preview(hokuyoObj)

Input Arguments

collapse all

Hokuyo 2-D lidar sensor connection, specified as a hokuyolidar2d object.

Azimuth limits for previewing the lidar scans, specified as a two-element vector of the form [min max]. The preview window displays data only within these limits. The values must not exceed the range specified by the ScanAngleLimits property of the hokuyolidar2d object. max must be greater than min. Units are in degrees.

Data Types: single | double

Version History

Introduced in R2024a