In my opinion there are two bugs HAL_RTC_SetTime(..) (p. 776) and HAL_RTC_GetTime(..) (p. 881)./* Check Binary mode ((32-bit free-running counter) */if (READ_BIT(RTC->ICSR, RTC_ICSR_BIN) != RTC_BINARY_ONLY)should be RTC_BINARY_ONLY instead of RTC_BIN...