stm32/boards/PYBD: Change RTC asynch prediv from 1 to 4.

This change has the following effects:
- Reduces the resolution of the RTC sub-second counter from 30.52us to
  122.07us.
- Allows RTC.calibration() to now support positive values (as well as
  negative values).
- Reduces VBAT current consumption in standby mode by a small amount.

For general purpose use 122us resolution of the sub-second counter is
good enough, and the benefits of full range calibration and minor reduction
in VBAT consumption are worth the change.
This commit is contained in:
Damien George 2020-01-07 23:59:29 +11:00
parent 54a2584de1
commit e3187b052f

View File

@ -56,8 +56,8 @@ void board_sleep(int value);
#define MICROPY_HW_FLASH_LATENCY (FLASH_LATENCY_3)
// There is an external 32kHz oscillator
#define RTC_ASYNCH_PREDIV (0)
#define RTC_SYNCH_PREDIV (0x7fff)
#define RTC_ASYNCH_PREDIV (3)
#define RTC_SYNCH_PREDIV (0x1fff)
#define MICROPY_HW_RTC_USE_BYPASS (1)
#define MICROPY_HW_RTC_USE_US (1)
#define MICROPY_HW_RTC_USE_CALOUT (1)