From 2b172870d8ab03454598e0a0596bf317966e589e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=92=99=E8=B6=85=E6=81=92?= Date: Sun, 24 Apr 2022 10:26:12 +0800 Subject: [PATCH 1/6] Update README.md --- README.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e6fce0055..c9d084d89 100644 --- a/README.md +++ b/README.md @@ -62,8 +62,13 @@ Installation Instructions - Ubuntu 16.04 with ROS Kinetic $ cd ~/catkin_ws/ $ catkin build ``` - - 4. Add sourcing to your `.bashrc` file + 3.1. If you don't have `rotors_simulator` + + ``` + $ cd ~/catkin_ws/src + $ git clone https://github.com/ethz-asl/rotors_simulator.git + ``` +4. Add sourcing to your `.bashrc` file ``` $ echo "source ~/catkin_ws/devel/setup.bash" >> ~/.bashrc From 28ec88be7ce631ef0cbcc59b3a1ee9ad41f23d16 Mon Sep 17 00:00:00 2001 From: mengchaoheng Date: Sun, 24 Apr 2022 16:04:48 +0800 Subject: [PATCH 2/6] fix thrust_direction --- rotors_joy_interface/src/joy.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/rotors_joy_interface/src/joy.cpp b/rotors_joy_interface/src/joy.cpp index 8f098552c..9a3709471 100644 --- a/rotors_joy_interface/src/joy.cpp +++ b/rotors_joy_interface/src/joy.cpp @@ -89,14 +89,17 @@ void Joy::JoyCallback(const sensor_msgs::JoyConstPtr& msg) { else { current_yaw_vel_ = 0; } - control_msg_.yaw_rate = current_yaw_vel_; - + control_msg_.yaw_rate = msg->axes[3] * max_.rate_yaw ; +ROS_INFO("hello world! %d", axes_.thrust_direction); if (is_fixed_wing_) { double thrust = msg->axes[axes_.thrust] * axes_.thrust_direction; control_msg_.thrust.x = (thrust >= 0.0) ? thrust : 0.0; } else { - control_msg_.thrust.z = (msg->axes[axes_.thrust] + 1) * max_.thrust / 2.0 * axes_.thrust_direction; + control_msg_.thrust.z = (msg->axes[axes_.thrust] * axes_.thrust_direction + 1) * max_.thrust / 2.0 ; + + + } ros::Time update_time = ros::Time::now(); From 394343c8b2ec176ad819793877a2ff42a8f894f4 Mon Sep 17 00:00:00 2001 From: mengchaoheng Date: Sun, 24 Apr 2022 16:07:19 +0800 Subject: [PATCH 3/6] fix roslaunch about js --- rotors_gazebo/launch/mav_with_joy.launch | 6 +++++- rotors_gazebo/launch/mav_with_keyboard.launch | 9 +++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/rotors_gazebo/launch/mav_with_joy.launch b/rotors_gazebo/launch/mav_with_joy.launch index 7d3703dfe..6a3751cbe 100644 --- a/rotors_gazebo/launch/mav_with_joy.launch +++ b/rotors_gazebo/launch/mav_with_joy.launch @@ -22,7 +22,11 @@ - + + + + - - + + + + + + + From df10ed73f35bf9097b1dcac407cec9eccdb1444a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=92=99=E8=B6=85=E6=81=92?= Date: Sun, 24 Apr 2022 16:31:19 +0800 Subject: [PATCH 4/6] Update README.md update readme --- README.md | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/README.md b/README.md index c9d084d89..a289e87e5 100644 --- a/README.md +++ b/README.md @@ -74,6 +74,48 @@ Installation Instructions - Ubuntu 16.04 with ROS Kinetic $ echo "source ~/catkin_ws/devel/setup.bash" >> ~/.bashrc $ source ~/.bashrc ``` + +Installation Instructions - Ubuntu 20.04 with ROS Noetic +--------------------------------------------------------- + 1. Install and initialize ROS kinetic desktop full, additional ROS packages, catkin-tools, and wstool: + + ``` + $ sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list' + $ sudo apt install curl # if you haven't already installed curl + $ curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | sudo apt-key add - + $ sudo apt update + $ sudo apt install ros-noetic-desktop-full # install ros noetic + $ sudo apt install ros-noetic-joy ros-noetic-octomap-ros ros-noetic-mavlink python3-wstool python3-catkin-tools protobuf-compiler libgoogle-glog-dev ros-noetic-control-toolbox ros-noetic-mavros # install Dependencies + $ sudo rosdep init + $ rosdep update + $ source /opt/ros/kinetic/setup.bash + ``` + 2. If you don't have ROS workspace yet you can do so by + + ``` + $ mkdir -p ~/catkin_ws/src + $ cd ~/catkin_ws/src + $ catkin_init_workspace # initialize your catkin workspace + $ wstool init + $ git clone https://github.com/ethz-asl/rotors_simulator.git + $ wget https://raw.githubusercontent.com/ethz-asl/rotors_simulator/master/rotors_hil.rosinstall + $ wstool merge rotors_hil.rosinstall + $ wstool update + ``` + + 3. Build your workspace with `python_catkin_tools` (therefore you need `python_catkin_tools`) + + ``` + $ cd ~/catkin_ws/ + $ catkin build + ``` + + 4. Add sourcing to your `.bashrc` file + + ``` + $ echo "source ~/catkin_ws/devel/setup.bash" >> ~/.bashrc + $ source ~/.bashrc + ``` Installation Instructions - Ubuntu 14.04 with ROS Indigo -------------------------------------------------------- From fd3b85d22b6000f5cf710045676afda943729cf8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=92=99=E8=B6=85=E6=81=92?= Date: Sun, 24 Apr 2022 16:34:44 +0800 Subject: [PATCH 5/6] Update README.md update readme --- README.md | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index a289e87e5..e06958ac0 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ doi="10.1007/978-3-319-26054-9_23", url="http://dx.doi.org/10.1007/978-3-319-26054-9_23" } ``` -Installation Instructions - Ubuntu 16.04 with ROS Kinetic +Installation Instructions - Ubuntu 20.04 with ROS Noetic --------------------------------------------------------- 1. Install and initialize ROS kinetic desktop full, additional ROS packages, catkin-tools, and wstool: @@ -49,6 +49,7 @@ Installation Instructions - Ubuntu 16.04 with ROS Kinetic $ cd ~/catkin_ws/src $ catkin_init_workspace # initialize your catkin workspace $ wstool init + $ git clone https://github.com/ethz-asl/rotors_simulator.git $ wget https://raw.githubusercontent.com/ethz-asl/rotors_simulator/master/rotors_hil.rosinstall $ wstool merge rotors_hil.rosinstall $ wstool update @@ -75,17 +76,15 @@ Installation Instructions - Ubuntu 16.04 with ROS Kinetic $ source ~/.bashrc ``` -Installation Instructions - Ubuntu 20.04 with ROS Noetic +Installation Instructions - Ubuntu 16.04 with ROS Kinetic --------------------------------------------------------- 1. Install and initialize ROS kinetic desktop full, additional ROS packages, catkin-tools, and wstool: ``` - $ sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list' - $ sudo apt install curl # if you haven't already installed curl - $ curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | sudo apt-key add - - $ sudo apt update - $ sudo apt install ros-noetic-desktop-full # install ros noetic - $ sudo apt install ros-noetic-joy ros-noetic-octomap-ros ros-noetic-mavlink python3-wstool python3-catkin-tools protobuf-compiler libgoogle-glog-dev ros-noetic-control-toolbox ros-noetic-mavros # install Dependencies + $ sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu `lsb_release -sc` main" > /etc/apt/sources.list.d/ros-latest.list' + $ wget http://packages.ros.org/ros.key -O - | sudo apt-key add - + $ sudo apt-get update + $ sudo apt-get install ros-kinetic-desktop-full ros-kinetic-joy ros-kinetic-octomap-ros ros-kinetic-mavlink python-wstool python-catkin-tools protobuf-compiler libgoogle-glog-dev ros-kinetic-control-toolbox ros-kinetic-mavros $ sudo rosdep init $ rosdep update $ source /opt/ros/kinetic/setup.bash @@ -97,7 +96,6 @@ Installation Instructions - Ubuntu 20.04 with ROS Noetic $ cd ~/catkin_ws/src $ catkin_init_workspace # initialize your catkin workspace $ wstool init - $ git clone https://github.com/ethz-asl/rotors_simulator.git $ wget https://raw.githubusercontent.com/ethz-asl/rotors_simulator/master/rotors_hil.rosinstall $ wstool merge rotors_hil.rosinstall $ wstool update From dfda82547d28ddce6209c5acdea2c503afe22575 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=92=99=E8=B6=85=E6=81=92?= Date: Sun, 24 Apr 2022 16:35:47 +0800 Subject: [PATCH 6/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e06958ac0..c4e4b8f12 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ Installation Instructions - Ubuntu 20.04 with ROS Noetic $ cd ~/catkin_ws/src $ git clone https://github.com/ethz-asl/rotors_simulator.git ``` -4. Add sourcing to your `.bashrc` file + 4. Add sourcing to your `.bashrc` file ``` $ echo "source ~/catkin_ws/devel/setup.bash" >> ~/.bashrc