disconnect the serial on exit