Fixed flashing writing failure problem

Disable interrupt when writing flash