forked from ouster-lidar/ouster-sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial commit of the example visualizer
* Uses VTK6 to display point clouds and range/intensity/noise images * No dependencies other than VTK6, Eigen3, and a C++11 compiler * Currently only supports linux; tested on multiple distributions and platforms
- Loading branch information
Showing
17 changed files
with
2,599 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
README for OS1 Example Client | ||
|
||
## Contents | ||
* `ouster_client/` contains a simple C++ client for the OS1 sensor | ||
|
||
## Building the Sample Client | ||
* The sample client requires a compiler supporting C++11 or newer and CMake | ||
* Build with `cd /path/to/ouster_example/ouster_client && mkdir build && cd build && cmake .. && make` | ||
|
||
## Running the Sample Client | ||
* The sample client includes a small driver program that just prints some data to the terminal | ||
* Make sure the OS1 is connected to the network and has obtained a dhcp lease. See accompanying documentation for more details | ||
* You should see a binary called `ouster_client_example` in your build directory on success | ||
* Run `ouster_client_example <os1_hostname> <udp_data_dest_ip>` where `<os1_hostname>` is the hostname or IP address of the OS1 sensor, and `<udp_data_dest_ip>` is the IP to which the sensor should send lidar data | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#README for OS1 Example ROS Node | ||
|
||
## Building the Sample ROS Node | ||
* Supports Ubuntu 16.04 with ROS Kinetic (for ouster_ros) | ||
* ROS installation instructions can be found [here](http://wiki.ros.org/kinetic/Installation/Ubuntu) | ||
* Additionally requires ros-kinetic-pcl-ros and, optionally, ros-kinetic-rviz for visualization | ||
* Be sure to source the ROS setup script before building. For example:`source /opt/ros/kinetic/setup.bash` | ||
* Both packages can be built by catkin by moving them into a catkin workspace | ||
* Build with `mkdir myworkspace && cd myworkspace && ln -s /path/to/ouster_example ./src && catkin_make` | ||
|
||
## Running the Sample ROS Node | ||
* Set up the ROS environment with `source /path/to/myworkspace/devel/setup.bash` in a new terminal for each command below | ||
* For use with a running sensor: | ||
- To publish OS1 data as ROS topic `roslaunch ouster_ros os1.launch os1_hostname:=<os1_hostname> os1_udp_dest=<udp_data_dest_ip>` where `<os1_hostname>` can be the hostname or IP of the OS1 device and `<udp_data_dest_ip>` is the IP to which the sensor should send data | ||
- To record raw sensor output, run `rosbag record /os1_node/imu_packets /os1_node/lidar_packets` in another terminal | ||
- To visualize output, run `rviz -d /path/to/ouster_ros/viz.rviz` in another terminal | ||
* For use with recorded sensor data: | ||
- To replay raw sensor output, run `roslaunch ouster_ros os1.launch replay:=true` | ||
- In a second terminal, run `rosbag play --clock <bagfile>` | ||
- To visualize output, run `rviz -d /path/to/ouster_ros/viz.rviz` in another terminal | ||
* Sample raw sensor output is available [here](https://data.ouster.io/ouster-os1-100sec.bag) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
build/ |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
cmake_minimum_required(VERSION 3.1.0) | ||
project(ouster_viz) | ||
|
||
set(CMAKE_CXX_STANDARD 11) | ||
set(CMAKE_CXX_FLAGS "-Wall -Wextra") | ||
set(CMAKE_CXX_FLAGS_DEBUG "-O0 -g") | ||
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG") | ||
|
||
find_package(Threads) | ||
find_package(Eigen3 REQUIRED) | ||
find_package(VTK REQUIRED) | ||
|
||
add_subdirectory(../ouster_client ouster_client) | ||
|
||
include_directories(include) | ||
|
||
include_directories(SYSTEM | ||
${EIGEN3_INCLUDE_DIR} | ||
${VTK_INCLUDE_DIRS} | ||
) | ||
|
||
add_executable(viz src/main.cpp src/viz.cpp) | ||
|
||
target_link_libraries(viz | ||
ouster_client | ||
${VTK_LIBRARIES} | ||
${CMAKE_THREAD_LIBS_INIT} | ||
) |
Oops, something went wrong.