PX4FLOW ground mag Anomaly

Im using Arducopter 3.6.6

PX4FLOW was connected to I2c port and 24GHz mmwaveradar as range finder
When i tried switching the mode from STABILIZE to LOITER witch GPS completely removed, the copter started Toilet bowl movement and also displayed Ground mag anomaly

in next takeoff the GPS was enabled, mmwave radar was installed and only the PX4flow was removed

By removing that i switched from STABILIZE to LOITER … with GPS enabled the LOITER was working fine and then i switched to AUTO and LOITER again… within a Minute the copter motors got shut down and it was about to fell down. the mode was changed to STABILIZE and that has recovered successfully.

Can anyone please review the following logs