mirror of https://github.com/rusefi/rusefi-1.git
auto-sync
This commit is contained in:
parent
ef100af6ca
commit
c9c093d3dc
|
@ -52,6 +52,8 @@ RTCDriver RTCD1;
|
|||
/* Driver local functions. */
|
||||
/*===========================================================================*/
|
||||
|
||||
extern int lseTimeout;
|
||||
|
||||
/**
|
||||
* @brief Wait for synchronization of RTC registers with APB1 bus.
|
||||
* @details This function must be invoked before trying to read RTC registers.
|
||||
|
@ -60,7 +62,7 @@ RTCDriver RTCD1;
|
|||
*/
|
||||
#define rtc_lld_apb1_sync() { \
|
||||
int counter = 0; \
|
||||
while ((RTCD1.id_rtc->ISR & RTC_ISR_RSF) == 0 && ++counter <LSE_TIMEOUT);\
|
||||
while ((RTCD1.id_rtc->ISR & RTC_ISR_RSF) == 0 && ++counter <lseTimeout);\
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -59,6 +59,9 @@ int maxNesting = 0;
|
|||
#if HAL_USE_SPI || defined(__DOXYGEN__)
|
||||
static bool isSpiInitialized[5] = { false, false, false, false, false };
|
||||
|
||||
// todo: use larger value if LSE is available, make this a boardConfiguration option
|
||||
int lseTimeout = 0;
|
||||
|
||||
/**
|
||||
* Only one consumer can use SPI bus at a given time
|
||||
*/
|
||||
|
|
|
@ -298,5 +298,5 @@ int getRusEfiVersion(void) {
|
|||
return 123; // this is here to make the compiler happy about the unused array
|
||||
if (UNUSED_CCM_SIZE[0] * 0 != 0)
|
||||
return 3211; // this is here to make the compiler happy about the unused array
|
||||
return 20160426;
|
||||
return 20160503;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue