NeuronBot2 is the newest version of NeuronBot made by Adlink, which fully supports ROS1 and ROS2.
- Nice
- Good
- Awesome
- Wonderful
- Magnificent
- Impressive
- Intimidating
- Stunning
- Extraordinary
- Superb
This package includes the functions to bring up the robot, to make it SLAM, to navigation, and to simulate it with your own computer, testing the same functions mentioned before.
Now we support the following version, you can checkout to these branch.
- ROS 1 melodic
- ROS 2 dashing
- ROS 2 eloquent
-
Create workspace
mkdir -p ~/neuronbot2_ros1_ws/src cd ~/neuronbot2_ros1_ws/src -
Git clone this package with melodic-devel branches
git clone https://github.com/Adlink-ROS/neuronbot2.git -b melodic-devel -
Install dependencies
cd ~/neuronbot2_ros1_ws/ rosdep update rosdep install --from-paths src --ignore-src -r -y --rosdistro melodic -
Initialze NeuronBot2 ttyUSB nodes
neuronbot_init.shis needed to be run only once for the first setup.cd ~/neuronbot2_ros1_ws/src/neuronbot2/neuronbot2_tools/neuronbot2_init/ sudo ./neuronbot2_init.sh -
catkin_make
cd ~/neuronbot2_ros1_ws/ source /opt/ros/melodic/setup.bash catkin_make source devel/setup.bash
Below document is the quick-start guide for simulation if you don't realy have a NeuronBot.
-
Specify the model path for Gazebo
source /opt/ros/melodic/setup.bash source ~/neuronbot2_ros1_ws/devel/setup.bash export GAZEBO_MODEL_PATH=~/neuronbot2_ros1_ws/src/neuronbot2/neuronbot2_gazebo/models -
Launch Gazebo simulation.
There are two worlds for users to explore.
- Mememan world
roslaunch neuronbot2_gazebo neuronbot2_world.launch world_model:=mememan_world.model- Phenix world
roslaunch neuronbot2_gazebo neuronbot2_world.launch world_model:=phenix_world.model -
Teleop it in the world
Users are able to control the NeuronBot2 with the following rosnode. Run it with the other terminal.
source /opt/ros/melodic/setup.bash rosrun teleop_twist_keyboard teleop_twist_keyboard.py
-
Launch SLAM as well as Rviz while the Gazebo simulation is running.
roslaunch neuronbot2_slam gmapping.launch open_rviz:=true -
Teleop it to explore the world
rosrun teleop_twist_keyboard teleop_twist_keyboard.py -
Explore the world with move_base while SLAM with gmapping
roslaunch neuronbot2_nav navigation.launch -
Save the map
source ~/neuronbot2_ros1_ws/devel/setup.bash roscd neuronbot2_nav/maps/ rosrun map_server map_saver -f <map_name>Then, you shall turn off Gmapping.
Once users obtain the map, the pgm file & yaml file, navigation is good to go.
-
Launch Navigation as well as Rviz while the Gazebo simulation is running.
roscd neuronbot2_nav/maps/ roslaunch neuronbot2_nav bringup.launch open_rviz:=true local_planner:=dwa map:=map_name.yamlopen_rviz: whether open RViz or not [default: false]
local_planner: can be either dwa or teb [default: dwa]
map: sholud be assigned to the absolute path if you are not in neuronbot2_nav/maps/ [default: mememan.yaml]
You can also change the default map file in neuronbot2_nav/launch/bringup.launch
-
Set Estimation
Click "2D Pose Estimate", and set estimation to the approximate location of robot on the map.
-
Set Goal
Click "2D Nav Goal", and set goal to any free space on the map.
-
Speed up simulation
rosrun dynamic_reconfigure dynparam set gazebo time_step 0.002 # default is 0.001
-
Why do I see "ERROR: cannot launch node of type [xxx] ..." ?
ANS: You probably forgot to install dependent packages, please try below commands:
cd ~/neuronbot2_ros1_ws/ rosdep install --from-paths src --ignore-src -r -y --rosdistro $ROS_DISTRO -
Why do I see "RLException: [xxx.launch] is neither a launch file in package [neuronbot2_xxx]" ?
ANS: You probably forgot to source the environment of this workspace, please try below commands:
source ~/neuronbot2_ros1_ws/devel/setup.bash









