Added battery state of charge flash codes and neatened up USB connect handling