ArduPilot / ardupilot

ArduPlane, ArduCopter, ArduRover, ArduSub source
http://ardupilot.org/
GNU General Public License v3.0
10.74k stars 17.19k forks source link

ROS / Hector SLAM - No EKF2 IMU data to GCS / Wrong FCU time, RTT too high for timesync #9678

Open bj-neilson opened 5 years ago

bj-neilson commented 5 years ago

Issue details

I think I've installed all as per the ROS and Hector SLAM for Non-GPS Navigation guide.

I have communication between my laptop that is running ROS and Pixhawk Cube via FTDI usb to serial connection (Telem2). Mission Planner is running on a separate laptop. Communicating with Pixhawk via 433Mhz radio (Telem1) For example I can arm the FCU from MAVROS by command. I can set home position on GCS and it is received by MAVROS. So I seem to have comms in both directions.

I cannot see any EFK2 IMU data coming in. Any thoughts? I'd be very grateful for any assistance.

Seeing several warnings/errors: [ WARN] [1541111777.853076146]: TM: Wrong FCU time. [ WARN] [1541111790.846931637]: GP: No GPS fix [ WARN] [1541111799.884152101]: TM : RTT too high for timesync: 1541110387094.33 ms.

Version

What version was the issue encountered with

Platform

[ ] All [ ] AntennaTracker [ ] Copter [ ] Plane [ X ] Rover [ ] Submarine

Airframe type

Mounted on a zero-turn (skid steer) Toro mower

Hardware type

Pixhawk Cube

Logs

Output from MAVROS starting and errors.

ben@ben-HP-Pavilion-Laptop-15-cc5xx:~/catkin_ws$ roslaunch mavros apm.launch fcu_url:=/dev/ttyUSB1:921600 ... logging to /home/ben/.ros/log/59926cfc-de23-11e8-9b32-28c63fe43a0e/roslaunch-ben-HP-Pavilion-Laptop-15-cc5xx-12293.log Checking log director roslaunch-ben-HP-Pavilion-Laptop-15-cc5xx-12293.log y for disk usage. This may take awhile. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://ben-HP-Pavilion-Laptop-15-cc5xx:35097/

SUMMARY

CLEAR PARAMETERS

PARAMETERS

NODES / mavros (mavros/mavros_node)

ROS_MASTER_URI=http://localhost:11311

process[mavros-1]: started with pid [12311] [ INFO] [1541110504.977623348]: FCU URL: /dev/ttyUSB1:921600 [ INFO] [1541110504.979353599]: serial0: device: /dev/ttyUSB1 @ 921600 bps [ INFO] [1541110504.980464026]: GCS bridge disabled [ INFO] [1541110504.991486855]: Plugin 3dr_radio loaded [ INFO] [1541110504.993718842]: Plugin 3dr_radio initialized [ INFO] [1541110504.993752603]: Plugin actuator_control blacklisted [ INFO] [1541110504.996647063]: Plugin adsb loaded [ INFO] [1541110505.000810947]: Plugin adsb initialized [ INFO] [1541110505.000844680]: Plugin altitude blacklisted [ INFO] [1541110505.000977144]: Plugin cam_imu_sync loaded [ INFO] [1541110505.001963952]: Plugin cam_imu_sync initialized [ INFO] [1541110505.002250373]: Plugin command loaded [ INFO] [1541110505.014473605]: Plugin command initialized [ INFO] [1541110505.014510298]: Plugin debug_value blacklisted [ INFO] [1541110505.014740188]: Plugin distance_sensor loaded [ INFO] [1541110505.025839161]: Plugin distance_sensor initialized [ INFO] [1541110505.026016584]: Plugin fake_gps loaded [ INFO] [1541110505.042256533]: Plugin fake_gps initialized [ INFO] [1541110505.042289721]: Plugin ftp blacklisted [ INFO] [1541110505.042475030]: Plugin global_position loaded [ INFO] [1541110505.060996449]: Plugin global_position initialized [ INFO] [1541110505.061154140]: Plugin gps_rtk loaded [ INFO] [1541110505.063800883]: Plugin gps_rtk initialized [ INFO] [1541110505.063834011]: Plugin hil blacklisted [ INFO] [1541110505.064016299]: Plugin home_position loaded [ INFO] [1541110505.069564094]: Plugin home_position initialized [ INFO] [1541110505.069738953]: Plugin imu loaded [ INFO] [1541110505.080324731]: Plugin imu initialized [ INFO] [1541110505.080509042]: Plugin local_position loaded [ INFO] [1541110505.086614418]: Plugin local_position initialized [ INFO] [1541110505.086781655]: Plugin log_transfer loaded [ INFO] [1541110505.090297888]: Plugin log_transfer initialized [ INFO] [1541110505.090515601]: Plugin manual_control loaded [ INFO] [1541110505.093873162]: Plugin manual_control initialized [ INFO] [1541110505.093908778]: Plugin mocap_pose_estimate blacklisted [ INFO] [1541110505.094041556]: Plugin obstacle_distance loaded [ INFO] [1541110505.096752990]: Plugin obstacle_distance initialized [ INFO] [1541110505.096914708]: Plugin odom loaded [ INFO] [1541110505.103370136]: Plugin odom initialized [ INFO] [1541110505.103654952]: Plugin param loaded [ INFO] [1541110505.106842942]: Plugin param initialized [ INFO] [1541110505.106875027]: Plugin px4flow blacklisted [ INFO] [1541110505.107001841]: Plugin rangefinder loaded [ INFO] [1541110505.107848015]: Plugin rangefinder initialized [ INFO] [1541110505.108047618]: Plugin rc_io loaded [ INFO] [1541110505.112190997]: Plugin rc_io initialized [ INFO] [1541110505.112222068]: Plugin safety_area blacklisted [ INFO] [1541110505.112383957]: Plugin setpoint_accel loaded [ INFO] [1541110505.116033150]: Plugin setpoint_accel initialized [ INFO] [1541110505.116390857]: Plugin setpoint_attitude loaded [ INFO] [1541110505.129021494]: Plugin setpoint_attitude initialized [ INFO] [1541110505.129261786]: Plugin setpoint_position loaded [ INFO] [1541110505.146456442]: Plugin setpoint_position initialized [ INFO] [1541110505.146660500]: Plugin setpoint_raw loaded [ INFO] [1541110505.158039414]: Plugin setpoint_raw initialized [ INFO] [1541110505.158242981]: Plugin setpoint_velocity loaded [ INFO] [1541110505.166365039]: Plugin setpoint_velocity initialized [ INFO] [1541110505.166769052]: Plugin sys_status loaded [ INFO] [1541110505.178494819]: Plugin sys_status initialized [ INFO] [1541110505.178728287]: Plugin sys_time loaded [ INFO] [1541110505.185350488]: TM: Timesync mode: NONE [ INFO] [1541110505.186660392]: Plugin sys_time initialized [ INFO] [1541110505.186827882]: Plugin trajectory loaded [ INFO] [1541110505.194521799]: Plugin trajectory initialized [ INFO] [1541110505.194727834]: Plugin vfr_hud loaded [ INFO] [1541110505.195769767]: Plugin vfr_hud initialized [ INFO] [1541110505.195807909]: Plugin vibration blacklisted [ INFO] [1541110505.195955855]: Plugin vision_pose_estimate loaded [ INFO] [1541110505.205738565]: Plugin vision_pose_estimate initialized [ INFO] [1541110505.205780899]: Plugin vision_speed_estimate blacklisted [ INFO] [1541110505.205977804]: Plugin waypoint loaded [ INFO] [1541110505.211893379]: Plugin waypoint initialized [ INFO] [1541110505.212104183]: Plugin wind_estimation loaded [ INFO] [1541110505.213040219]: Plugin wind_estimation initialized [ INFO] [1541110505.213138798]: Built-in SIMD instructions: SSE, SSE2 [ INFO] [1541110505.213163975]: Built-in MAVLink package version: 2018.10.10 [ INFO] [1541110505.213191468]: Known MAVLink dialects: common ardupilotmega ASLUAV autoquad icarous matrixpilot paparazzi slugs standard uAvionix ualberta [ INFO] [1541110505.213214160]: MAVROS started. MY ID 1.240, TARGET ID 1.1 [ INFO] [1541110505.715442244]: CON: Got HEARTBEAT, connected. FCU: ArduPilotMega / ArduCopter [ INFO] [1541110505.735985821]: IMU: Raw IMU message used. [ WARN] [1541110505.758095807]: GP: No GPS fix [ INFO] [1541110505.760867382]: RC_CHANNELS message detected! [ WARN] [1541110505.763901341]: TM: Wrong FCU time. [ INFO] [1541110506.735913028]: VER: 1.1: Capabilities 0x00000000000031cf [ INFO] [1541110506.735963610]: VER: 1.1: Flight software: 030402ff ( 318a941) [ INFO] [1541110506.735988641]: VER: 1.1: Middleware software: 00000000 ( ) [ INFO] [1541110506.736014662]: VER: 1.1: OS software: 00000000 ( ) [ INFO] [1541110506.736050428]: VER: 1.1: Board hardware: 00000000 [ INFO] [1541110506.736077279]: VER: 1.1: VID/PID: 0000:0000 [ INFO] [1541110506.736103902]: VER: 1.1: UID: 0000000000000000 [ WARN] [1541110506.736797594]: CMD: Unexpected command 520, result 0 [ INFO] [1541110515.716787748]: HP: requesting home position [ INFO] [1541110515.733631213]: FCU: ArduRover V3.4.2 (318a941d) [ INFO] [1541110520.751257726]: WP: item #0 F:0 C: 16 p: 0.000000 0.000000 0.000000 0.000000 x: 0.000000 y: 0.000000 z: 0.000000 [ INFO] [1541110520.771010305]: WP: item #1 F:0 C: 16 p: 0.000000 0.000000 0.000000 0.000000 x: 0.000000 y: 0.000000 z: 0.270000 [ INFO] [1541110520.791912979]: WP: item #2 F:0 C: 16 p: 0.000000 0.000000 0.000000 0.000000 x: 0.000000 y: 0.000000 z: 0.190000 [ INFO] [1541110520.812010923]: WP: item #3 F:0 C: 16 p: 0.000000 0.000000 0.000000 0.000000 x: 0.000000 y: 0.000000 z: 0.510000 [ INFO] [1541110520.831970342]: WP: item #4 F:0 C: 16 p: 0.000000 0.000000 0.000000 0.000000 x: 0.000000 y: 0.000000 z: 0.350000 [ INFO] [1541110520.832071792]: WP: mission received [ INFO] [1541110525.716364849]: HP: requesting home position [ INFO] [1541110532.029396115]: PR: parameters list received [ INFO] [1541110535.716782532]: HP: requesting home position [ WARN] [1541110536.750876630]: GP: No GPS fix [ INFO] [1541110545.716152524]: HP: requesting home position [ INFO] [1541110555.716574369]: HP: requesting home position [ INFO] [1541110565.716508101]: HP: requesting home position [ WARN] [1541110566.751479145]: TM: Wrong FCU time. [ WARN] [1541110567.745620477]: GP: No GPS fix [ INFO] [1541110575.716143259]: HP: requesting home position [ INFO] [1541110585.716347981]: HP: requesting home position [ INFO] [1541110595.716650323]: HP: requesting home position [ WARN] [1541110599.740173083]: GP: No GPS fix [ INFO] [1541110605.716125990]: HP: requesting home position [ INFO] [1541110615.716507069]: HP: requesting home position [ INFO] [1541110625.715935242]: HP: requesting home position [ WARN] [1541110627.740097081]: TM: Wrong FCU time. [ WARN] [1541110630.734092715]: GP: No GPS fix [ INFO] [1541110635.716402170]: HP: requesting home position [ INFO] [1541110645.715990577]: HP: requesting home position [ INFO] [1541110655.716703894]: HP: requesting home position [ WARN] [1541110660.744534704]: GP: No GPS fix [ INFO] [1541110665.716682541]: HP: requesting home position [ INFO] [1541110675.716480079]: HP: requesting home position [ INFO] [1541110685.716127791]: HP: requesting home position [ WARN] [1541110687.784255007]: TM: Wrong FCU time. [ WARN] [1541110690.782370617]: GP: No GPS fix [ INFO] [1541110695.716517745]: HP: requesting home position [ INFO] [1541110705.716430842]: HP: requesting home position [ERROR] [1541110711.753050230]: FCU: PreArm: Hardware safety switch [ INFO] [1541110715.716136726]: HP: requesting home position [ WARN] [1541110720.798451142]: GP: No GPS fix [ INFO] [1541110725.716910971]: HP: requesting home position [ INFO] [1541110732.699798878]: FCU: Throttle armed [ INFO] [1541110735.716465614]: HP: requesting home position [ INFO] [1541110745.716472274]: HP: requesting home position [ WARN] [1541110747.896416108]: TM: Wrong FCU time. [ WARN] [1541110750.892477077]: GP: No GPS fix [ INFO] [1541110755.715874129]: HP: requesting home position [ INFO] [1541110765.716801908]: HP: requesting home position [ INFO] [1541110775.716696397]: HP: requesting home position [ WARN] [1541110780.896525759]: GP: No GPS fix [ INFO] [1541110785.716462053]: HP: requesting home position [ INFO] [1541110787.441071069]: FCU: Mission Planner 1.0.0.0 [ INFO] [1541110787.460065012]: FCU: Mission Planner 1.0.0.0 [ INFO] [1541110795.716495801]: HP: requesting home position [ INFO] [1541110805.715936651]: HP: requesting home position [ WARN] [1541110808.838291281]: TM: Wrong FCU time. [ WARN] [1541110811.828144809]: GP: No GPS fix [ INFO] [1541110815.716955090]: HP: requesting home position [ INFO] [1541110825.716109779]: HP: requesting home position [ INFO] [1541110835.716962045]: HP: requesting home position [ WARN] [1541110837.537081385]: TM : RTT too high for timesync: 1541110386666.93 ms. [ WARN] [1541110842.814779834]: GP: No GPS fix [ INFO] [1541110845.716675238]: HP: requesting home position [ INFO] [1541110855.716681831]: HP: requesting home position [ INFO] [1541110865.716563140]: HP: requesting home position [ WARN] [1541110869.802535341]: TM: Wrong FCU time. [ WARN] [1541110873.795479595]: GP: No GPS fix [ INFO] [1541110875.716897419]: HP: requesting home position [ INFO] [1541110885.716618954]: HP: requesting home position [ INFO] [1541110895.716208734]: HP: requesting home position [ WARN] [1541110897.683370286]: TM : RTT too high for timesync: 1541110386693.58 ms. [ WARN] [1541110904.783002514]: GP: No GPS fix [ INFO] [1541110905.716632538]: HP: requesting home position [ INFO] [1541110915.716421270]: HP: requesting home position [ INFO] [1541110925.715848472]: HP: requesting home position [ WARN] [1541110930.016443191]: TM: Wrong FCU time. [ WARN] [1541110935.021293891]: GP: No GPS fix [ INFO] [1541110935.716523135]: HP: requesting home position [ INFO] [1541110945.716895317]: HP: requesting home position [ INFO] [1541110955.716277620]: HP: requesting home position [ WARN] [1541110958.226485528]: TM : RTT too high for timesync: 1541110387116.90 ms. [ INFO] [1541110965.716243745]: HP: requesting home position [ WARN] [1541110965.870370333]: GP: No GPS fix [ INFO] [1541110975.716705888]: HP: requesting home position [ INFO] [1541110985.716366823]: HP: requesting home position [ WARN] [1541110990.854155062]: TM: Wrong FCU time. [ INFO] [1541110995.716268966]: HP: requesting home position [ WARN] [1541110996.846270295]: GP: No GPS fix [ INFO] [1541111005.715873202]: HP: requesting home position [ INFO] [1541111015.716332788]: HP: requesting home position [ WARN] [1541111018.171168857]: TM : RTT too high for timesync: 1541110386941.62 ms. [ INFO] [1541111025.716763798]: HP: requesting home position [ WARN] [1541111027.691875726]: GP: No GPS fix [ INFO] [1541111035.716661802]: HP: requesting home position [ INFO] [1541111045.716525458]: HP: requesting home position [ WARN] [1541111051.782707433]: TM: Wrong FCU time. [ INFO] [1541111055.716721447]: HP: requesting home position [ WARN] [1541111057.805554163]: GP: No GPS fix [ INFO] [1541111062.217850535]: FCU: Set HOME to -28.80144 153.3854 at 141.95m [ WARN] [1541111078.640515880]: TM : RTT too high for timesync: 1541110387290.97 ms. [ WARN] [1541111088.078110574]: GP: No GPS fix [ WARN] [1541111112.043607149]: TM: Wrong FCU time. [ WARN] [1541111118.911981511]: GP: No GPS fix [ WARN] [1541111138.623965124]: TM : RTT too high for timesync: 1541110387153.85 ms. [ WARN] [1541111149.860175075]: GP: No GPS fix [ WARN] [1541111172.891086301]: TM: Wrong FCU time. [ WARN] [1541111180.826748372]: GP: No GPS fix [ WARN] [1541111198.620930319]: TM : RTT too high for timesync: 1541110387031.15 ms. [ WARN] [1541111211.786328403]: GP: No GPS fix [ WARN] [1541111233.807909180]: TM: Wrong FCU time. [ WARN] [1541111241.803894615]: GP: No GPS fix [ WARN] [1541111259.080367550]: TM : RTT too high for timesync: 1541110387370.79 ms. [ WARN] [1541111271.805521793]: GP: No GPS fix [ WARN] [1541111293.883729035]: TM: Wrong FCU time. [ WARN] [1541111301.891017787]: GP: No GPS fix [ WARN] [1541111319.444907768]: TM : RTT too high for timesync: 1541110387615.28 ms. [ WARN] [1541111331.914784314]: GP: No GPS fix [ WARN] [1541111354.846427701]: TM: Wrong FCU time. [ WARN] [1541111362.828356299]: GP: No GPS fix [ WARN] [1541111379.150195057]: TM : RTT too high for timesync: 1541110387200.56 ms. [ WARN] [1541111393.804815428]: GP: No GPS fix [ WARN] [1541111415.820445735]: TM: Wrong FCU time. [ WARN] [1541111423.818211043]: GP: No GPS fix [ WARN] [1541111439.180198547]: TM : RTT too high for timesync: 1541110387110.07 ms. [ WARN] [1541111453.824516679]: GP: No GPS fix [ WARN] [1541111475.829416043]: TM: Wrong FCU time. [ WARN] [1541111484.823834520]: GP: No GPS fix [ WARN] [1541111499.241479879]: TM : RTT too high for timesync: 1541110387051.69 ms. [ WARN] [1541111515.820924260]: GP: No GPS fix [ WARN] [1541111535.834575236]: TM: Wrong FCU time. [ WARN] [1541111545.841609236]: GP: No GPS fix [ WARN] [1541111559.550263579]: TM : RTT too high for timesync: 1541110387240.68 ms. [ WARN] [1541111575.861992400]: GP: No GPS fix [ WARN] [1541111595.872952252]: TM: Wrong FCU time. [ WARN] [1541111605.870383283]: GP: No GPS fix [ WARN] [1541111619.590765438]: TM : RTT too high for timesync: 1541110387161.21 ms. [ WARN] [1541111635.874988455]: GP: No GPS fix [ WARN] [1541111655.881413129]: TM: Wrong FCU time. [ WARN] [1541111666.873322959]: GP: No GPS fix [ WARN] [1541111679.385477288]: TM : RTT too high for timesync: 1541110386835.86 ms. [ WARN] [1541111697.861154161]: GP: No GPS fix [ WARN] [1541111716.861513399]: TM: Wrong FCU time. [ WARN] [1541111728.853716728]: GP: No GPS fix [ WARN] [1541111739.529722083]: TM : RTT too high for timesync: 1541110386859.63 ms. [ WARN] [1541111759.850188792]: GP: No GPS fix [ WARN] [1541111777.853076146]: TM: Wrong FCU time. [ WARN] [1541111790.846931637]: GP: No GPS fix [ WARN] [1541111799.884152101]: TM : RTT too high for timesync: 1541110387094.33 ms. ^C[mavros-1] killing on exit shutting down processing monitor... ... shutting down processing monitor complete

Thanks, Ben

NickNunno commented 5 years ago

@rmackay9 this looks to mirror the results myself and others have seen when following the AP Dev docs. I beleive something is missing from the docs, just havent had the time to chase it down.

@jmachuca77

rmackay9 commented 5 years ago

@bj-neilson,

We should probably do support for this in the Rover forums.. but in any case..

Some questions:

  1. does the Rover appear on the map? Hopefully you're using the MP's set-ekf-origin to tell the EKF where the vehicle is in the world and then soon after that it appears on the map?
  2. has the GPS been disabled? I don't think I've seen the "GP: No GPS fix" message on my setup but I could be wrong. There's some instructions on the wiki here.
  3. how are you checking that the IMU data is not coming into ROS? Sorry, I'm not very familiar with ROS but I guess you're doing a "rostopic echo xxx" where "xxx" is one of the topics under /mavros?
bj-neilson commented 5 years ago

@rmackay9 @jmachuca77 @NickNunno Hi Randy, thanks for your time.

  1. I used "set EKF origin". That seemed to take a few goes. Maybe it was my mouse location. Did work though. I'm sorry I can't recall if it showed the rover on the map. I'll be trying again later today.

  2. Yes GPS disabled as per your excellent guide.

  3. I'm a real ROS beginner so am relying heavily on your guide. Learning on the go. I was just looking in MP for the Messages your guide mentioned: EKF2 IMU1 initial pos NED = 0.0,0.0,0.0 (m) EKF2 IMU1 is using external nav data EKF2 IMU0 initial pos NED = 0.0,0.0,0.0 (m) EKF2 IMU0 is using external nav data

I'll try that rostopic echo and see what i can find.

I'm trying a fresh install of ROS/MavROS/MavLink today. Never know, might find something. Sticking with Ubuntu 16.04 for now. I'll let you know how it goes. Looking forward to your guide continuing! I'll really be keen to see the next bit you appear to be working on....feeding lidar data back to the FCU for collision avoidance. Thanks again for the help

bj-neilson commented 5 years ago

Hi @rmackay9 , I did a complete fresh install of Ubuntu 16.04 then followed the ROS Kinetic and MAVROS installation instructions as per their respective wiki’s. Did the GeographicLib install from source as the script install didn’t seem to work well. Pretty much back where I started.

  1. Tried to “set ekf origin” but had no response to that. No rover appears on MP screen. If I use “set home”, the home location is sent to ROS. I see that being received on the MAVROS window that is running.
  2. GPS disabled, all as per your guide. Still shows gps: no gps fix message.
  3. As best I can tell from looking through ROS topics, data is flowing both ways between ROS laptop and Cube.

As an aside, can GPS be used in this case? Asign it a low confidence value in the ekf? Might help correct odometry errors over time and distance?

Thanks for any thoughts. I’ve still got a bit of wiring to tidy up on the mower and other farm work to do in the meantime. Can then do a bit of gps driving if needed to tune speeds, turning radius etc as you’ve been working on with Kenny Russell etc.

Ta, Ben

Mohit953 commented 4 years ago

Hi, I am facing the same issue. Can you guide me for the same?

bj-neilson commented 4 years ago

Hi @Mohit953 , I did get it working, but a long time ago now. I’m sorry I don’t remember what was the problem. Try the Cartographer guide. Much the same and Cartographer will give you better results anyway. If you come up with any specific questions please ask. Ben

siddharthcb commented 3 years ago

hi @bj-neilson i know its been long since this thread come up but i am facing exactly same problems as you have mentioned. my pixhawk is getting harmed but i am getting these problems

Tried to “set ekf origin” but had no response to that. No rover appears on MP screen. If I use “set home”, the home location is sent to ROS. I see that being received on the MAVROS window that is running. GPS disabled, all as per your guide. Still shows gps: no gps fix message.

do you recall any of the things that you tried?

Try the Cartographer guide. Much the same and Cartographer will give you better results anyway.

did you get it working after switching to cartographer or hector-slam itself worked for you?

Omiclous commented 11 months ago

Hi @Mohit953, @siddharthcb , Have you solved the problem? The same thing is happening to me.