Move the database insertion to separate thread not to block OpenCPN