Log task stops logging suddenly when flight isn't finished


I performed yesterday some flight tests with a plane model using PX4 firmware and Pixhawk hardware. The flights went fine, I flew for around 4 minutes in each flight in order to perform the required maneuvers for tuning the FW control laws (therefore all the flights were in manual mode).

I had quite a surprise when trying to open the logs as I saw that for the first flight only some of the variables had been logged and for the second flight the log only lasts 9 seconds (whereas both flights lasted several minutes). I don’t know why this happened, before taking off I didn’t have any message error. By looking at the messages recorded in the SD card I have for both flights this kind of messages:

[ekf] dead-reckoning enabled
[ekf] stop dead-reckoning
[ekf] gave up dead-reckoning after long timeout

As well as this:

[ekf check] velocity diverted, check access config

I had calibrated all the sensors before the flight and was getting an accurate GPS position before take-off, I really don’t know why the log stops. I have uploaded both logs to LogMuncher in case it helps understanding the problem:
First flight
Second flight

Thank you for your help,