rosbag loading specific messages
3 views (last 30 days)
Show older comments
I am curious if there's a better way to load information from ROS bag files.
My current work flow is:
bag = rosbag(FILE_LOCATION)
bagSel = select(bag,'Topic','/mavros/imu/data')
X_imu_raw = timeseries(bagSel)
t_imu_angvel = X_imu_raw.Time - bag.StartTime
X_imu_angvel = X_immu_raw.Data(:,8:10) % problem line
When having to load a lot of different message sets this becomes very cumbersome. I'm not sure how to pull sets of messages from the timerseries, for example I could write:
timeseries(bagSel,'AngularVelocity.X')
and it will return the angular velocity around the X axis. I would ideally like to write something like:
timeseries(bagSel,'AngularVelocity')
and pull all of the angular velocity messages from the topic (x,y, and z) but i'm not sure if it is possible nor how to do it?
0 Comments
Answers (0)
See Also
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!