ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
/.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’ typedef sync_policies::ApproximateTime<sensor_msgs::NavSatFix, std_msgs::Float64, sensor_msgs::IMU> NavSyncPolicy; ^~~~~~~~~~~ /.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’
This sounds like you forgot to include the sensor_msgs/Imu.h
.
Note: the message name is Imu
, not IMU
.
another note: time synchronisation is only possible with message types that have a header: std_msgs/Float64
doesn't have one, so it cannot be used.
2 | No.2 Revision |
/.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’ typedef sync_policies::ApproximateTime<sensor_msgs::NavSatFix, std_msgs::Float64, sensor_msgs::IMU> NavSyncPolicy; ^~~~~~~~~~~ /.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’
This sounds like you forgot to include the sensor_msgs/Imu.h
. header.
Note: the message name is Imu
, not IMU
.
another note: time synchronisation is only possible with message types that have a header: std_msgs/Float64
doesn't have one, so it cannot be used.
3 | No.3 Revision |
/.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’ typedef sync_policies::ApproximateTime<sensor_msgs::NavSatFix, std_msgs::Float64, sensor_msgs::IMU> NavSyncPolicy; ^~~~~~~~~~~ /.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’
This sounds like you forgot to include the sensor_msgs/Imu.h
header.
Note: the message name is Imu
, not IMU
.
another note: time synchronisation is only possible with message types that have a header: std_msgs/Float64
doesn't have one, so it cannot be used.
Edit:
Is this an error with synchronizer.h I can't fix, was it caused by a minor error in my code?
seeing as these packages have been around for at least 10 years, I would always assume your code is at fault -- at first.
However, no code is faultless, so if you've assured that you're doing the right thing, then suspecting message_filters
starts to make sense.
4 | No.4 Revision |
/.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’ typedef sync_policies::ApproximateTime<sensor_msgs::NavSatFix, std_msgs::Float64, sensor_msgs::IMU> NavSyncPolicy; ^~~~~~~~~~~ /.../src/roscomm.cpp:222:85: error: ‘IMU’ is not a member of ‘sensor_msgs’
This sounds like Note: the message name is Imu
, not IMU
.
If you've fixed that and still get the same error, it's likely you forgot to include the sensor_msgs/Imu.h
header.
Note: the message name is Imu
, not IMU
.
another note: time synchronisation is only possible with message types that have a header: std_msgs/Float64
doesn't have one, so it cannot be used.
Edit:
Is this an error with synchronizer.h I can't fix, was it caused by a minor error in my code?
seeing as these packages have been around for at least 10 years, I would always assume your code is at fault -- at first.
However, no code is faultless, so if you've assured that you're doing the right thing, then suspecting message_filters
starts to make sense.