Crash with PX4 Pixhawk

Conf: x4, Pixhawk 2.4.5 , 3DR GPS + compass, 12000mAh 6S Lipo, 16" propellers, T-motor MN4014-9 400KV

We have a custom frame with X4 configuration. We have made a takeoff command in manual mode to an altitude of 10 meters and then the x4 started to rotate and then decreased the altitude then crashed onto the ground. In the previous takeoff try, the Pixhawk to ESC connection was wrong and the copter has crashed during takeoff. May the previous crash affect the second crash in compass aspect? The log is attached. Is it like a toilet bowl? Cani i get the compass error from logs? I couldn’t find any. I looked at the LPOS x,y,z setpoint and LPOS x,y,z values and there is a huge difference in 11:29:15 which is the time the copter finishes take off and started to rotate and then crash.

LOG: https://drive.google.com/file/d/0B67fT6oKKBwYMTRBTzNCOS0tazg/view?usp=sharing

BR,

After analysis and tests, we have seen that the root cause of the problem was about the sensors of the Pixhawk 2.4.8 labeled hardware which we bought from an informal seller. I will now see the ICs on the PCB to have idea about the difference. (of course maybe the PCB layout and routing itself).

When we replaced the Pixhawk with the one bought from 3DR, the autonomous flight was OK with both INAV and EKF2.

I will write my outputs here.

BR