Skip to content

Odometry channel frequency issues #114

@cburbridge

Description

@cburbridge

There seams to be a delay of about 400ms between commanding a velocity, and the odometry of the robot reporting that the current velocity is the one that was commanded.

The velocity being commanded is not outside of the acceleration limits of the robot. This is nothing to do with ROS topics - it is the time between calling the MIRA service callService<void>("/robot/Robot", "setVelocity", speed); and the value reported on the MIRA /robot/Odometry channel.

Here is a plot of the commanded (green) vs odeometry reported(blue) velocities.

velocity

The delay is more apparent when zoomed in:

velocity_zoomed

Since the reported velocity looks to match the commanded, only offset by 400ms, could this be a problem with the odometry channel? I have tried having the subscription running in its own thread, but this has not effect. The frequency of the odometry messages remains:

hz

In this plot we can see that the odometry messages usually have just over 50ms between each, except the occasional hiccup where it has maybe missed one? Regardless of the delayed messages, I would not expect this plot. If the messages are generated at 20Hz - so one every 50ms - then should there not be a mean of 50ms between messages? For example, if I received the message due at t=50ms at t=55ms (5ms late), then the next message due at t=100ms at t=102ms (2ms late) then the time between these is only 47ms. In this plot there is no "time between" of less than 50ms, yet there are quite a few more than 50ms. So is the frequency of the odometry channel not constant?

The last plot is the time between velocity commands sent by the move_base control loop. Here the target frequency is 10Hz, and the mean is 14 microseconds off 10Hz.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions