Don't the Americans regularly carry weapons on the flight deck as part of the FFDO scheme? I'm no expert but it would seem quite understandable how someone could end up in the UK with such a device. Clearly not allowed, but you could see how it could happen.
All it takes is to forget about it in the UK (remember this guy probably brings this device with him to work every day when flying domestically in the US) and you've got the situation as reported.