add recovery and fota support