removed reference to mbed stuff
updated error messages
cleaned up comments
added dblogerror to do the full logging function