Another idea going round in my head is logging GPS data every second to the local file store, but the problem then is it could be used to incriminate yourself if obtained by police rather than used to get yourself off the hook if their equipment is faulty.
If the data is recorded and encrypted, in a lot of countries the police can demand you decrypt it, or put you in jail until you do.
An interesting problem I have no answer for at this point in time, no doubt some interesting application of plausable deniable cryptography.