attempts to shut down mbed smoothly