Skip to content

Commit

Permalink
[Estimation][VIO] fix bug: initialize prev_timestamp
Browse files Browse the repository at this point in the history
  • Loading branch information
tongtybj authored and Moju Zhao committed Apr 10, 2024
1 parent 5688e4f commit 283a137
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions aerial_robot_estimation/src/sensor/vo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ namespace sensor_plugin
if(time_sync_) queuse_size = 10;
vo_sub_ = nh_.subscribe(topic_name, queuse_size, &VisualOdometry::voCallback, this);


/* servo control timer */
if(variable_sensor_tf_flag_)
{
Expand All @@ -92,6 +93,8 @@ namespace sensor_plugin

servo_control_timer_ = indexed_nhp_.createTimer(ros::Duration(servo_control_rate_), &VisualOdometry::servoControl,this); // 10 Hz
}

prev_timestamp_ = 0;
}

void VisualOdometry::voCallback(const nav_msgs::Odometry::ConstPtr & vo_msg)
Expand Down

0 comments on commit 283a137

Please sign in to comment.