Open MaverickHunterZeroX opened 4 years ago
the same error appears with ROS Kinetic on Ubuntu 16.04
I'm getting the same error. This is where the error happens
// initialize it with a negative time, so as to avoid mistaken for being active
ros::Time two_wheel_robot_topic_timer(-TOPIC_ACTIVE_PERIOD-0.1);
So I changed the negative value of the time to 0 and it seems to be working. However I did not investigate the impact of this on the rest of the code
// LINE 56: ros::Time two_wheel_robot_topic_timer(-TOPIC_ACTIVE_PERIOD-0.1);
ros::Time two_wheel_robot_topic_timer(0);
Just remove the negative TOPIC_ACTIVE_PERIOD = 1.0 wo_wheel_robot_topic_timer is decrementing by 0.1
ros::Time two_wheel_robot_topic_timer(TOPIC_ACTIVE_PERIOD-0.1);
I am using ROS Melodic on Ubuntu 18.04 LTS, and catkin build was successful after cloning https://github.com/yangliu28/swarm_robot_ros_sim. However, running the following command
rosrun swarm_robot_simulation two_wheel_robot_dispersion _spring_length:=0.7 _sensing_range:=2.0
seems to throw the following error: