1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-26 09:45:33 +03:00

Merge pull request #2752 from iNavFlight/de_refactor_underclock

Make sure defining/not defining USE_UNDERCLOCK doesn't break the functionality
This commit is contained in:
Konstantin Sharlaimov 2018-02-12 23:07:38 +10:00 committed by GitHub
commit 8539178eee
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 15 additions and 2 deletions

View file

@ -181,6 +181,7 @@ void init(void)
printfSupportInit();
// Initialize system and CPU clocks to their initial values
systemInit();
// initialize IO (needed for all IO operations)
@ -198,9 +199,8 @@ void init(void)
ensureEEPROMContainsValidData();
readEEPROM();
#ifdef USE_UNDERCLOCK
// Re-initialize system clock to their final values (if necessary)
systemClockSetup(systemConfig()->cpuUnderclock);
#endif
i2cSetSpeed(systemConfig()->i2c_speed);