RoverRobotics / roverrobotics_ros1

ROS1 Driver for communicating with Rover Robotics products. Requires librover.
Apache License 2.0
11 stars 7 forks source link

Rover rotates violently when the input command is just linear speed. #22

Closed nknxr closed 2 years ago

nknxr commented 2 years ago

Hi all,

Rover rotates at a very high speed when the input twist message is just low linear speed. This strange behavior is observed at three different rovers with the new driver. This happens less frequently but still need to be fixed.

I ran the pro.launch with everything same except for twist_mux config file. I have attached the bag file and twist_mux config file for reference. Link to the bag file

Usually I restart the pro.launch to fix this issue. Can we have a patch to fix this issue? Thanks.

drhieu commented 2 years ago

What happens when you power cycle your controller. I noticed that sometimes if your power order is not correct, the linux system will use the wrong driver for the controller.

nknxr commented 2 years ago

I wasn't using a controller. I was using rqt_robot_steering.

Negative linear speed makes the rover rotates clockwise while positive linear speed makes the rover rotate anti-clockwise.

nknxr commented 2 years ago

I disabled roverrobotics.service. I ran the pro.launch directly. I usually fix this issue by restarting pro.launch.

drhieu commented 2 years ago

Does this happens if you run the robot in Open Loop Mode ?

nknxr commented 2 years ago

In closed loop mode.

nknxr commented 2 years ago

Let know me if you need more information.

drhieu commented 2 years ago

What happens when you control the robot via librover exclusively. Librover movement commands are very simple for OPEN_LOOP and only PID is applied to CLOSE_LOOP. So it shouldn't break the robot. Does the RQT outputting the correct data when it run with ROS, Does the robot move straight if you input Angular Z commands ?

nknxr commented 2 years ago

When I input angular z commands, it rotates correctly at a proper speed.

nknxr commented 2 years ago

I have attached a bag file with input command and odom output from the rover.

drhieu commented 2 years ago

Could you try to bypass Rover Input Manager, by adding speed_topic to pro.launch and speed_topic is a topic that coming out of rqt_steer

nknxr commented 2 years ago

I restarted the driver while back. But from my previous observation, I directly published Twist() message on /cmd_vel/managed topic. So, it bypasses both input_manager and twist_mux. It had the same behavior.

drhieu commented 2 years ago

Please output these variables to the console to verify that you are getting valid output from ROS.