changes to support serial bootloader