/* Programs the FLASH User Option Byte: IWDG_SW / RST_STOP / RST_STDBY.  */
FLASH_Status FLASH_UserOptionByteConfig(OB_IWDG_TypeDef ob_iwdg, OB_STOP_TypeDef ob_stop, OB_STDBY_TypeDef standby)
/* Programs the FLASH User Option Byte: IWDG_SW / RST_STOP / RST_STDBY.  */
FLASH_Status FLASH_UserOptionByteConfig(OB_IWDG_TypeDef ob_iwdg, OB_STOP_TypeDef ob_stop, OB_STDBY_TypeDef standby)
{
    FLASH_OPTB_Enable();
    FLASH->CR |= FLASH_CR_OPTPG;
    OB->USER = ob_iwdg;
    OB->USER |= ob_stop;
    OB->USER |= standby;
    OB->USER |= 0xF8;
    return FLASH_WaitForLastOperation(ProgramTimeout);
}