RTC Information¶
The MitySOM-5CSx family of System on Modules (SoM) feature an on module Real Time Clock (RTC) IC, Abracon AB1805-T3, to ensure the ability to maintain timing information while running and, if enabled by an external battery, while a unit is powered off.
RTC Device Part Number¶
The current RTC device used on the MitySOM-5CSx family of modules is the Abracon AB1805 device.
Abracon AB1805 Datasheet: http://abracon.com/Precisiontiming/AB18X5-RTC.pdf
Abracon AB18XX Application Manual: http://www.abracon.com/Support/AppsManuals/Precisiontiming/AB18XX-Application-Manual.pdf
Note that a limited number of Revision 1 modules have utilized the AB1803 device which had a slightly more limited feature set. This is documented in section 3 of the following MitySOM-5CSx PCN (https://support.criticallink.com/redmine/attachments/download/8575/PCN20150626000.pdf)
RTC I2C Interface on MitySOM¶
- The RTC device is accessible on the I2C0 bus of the MitySOM-5CSx HPS
- It is located at address '1101001' (0x69)
Linux Kernel Drivers¶
Critical Link recommends that customers use the rtc-abx80x.c (KConfig CONFIG_RTC_DRV_ABX80X) driver for the RTC. This driver is available in the socfpga-4.9.78-ltsi branch of the Critical Link kernel repository. It was also back-ported to the socfpga-3.16 branch on 1/7/2019.
The legacy rtc-ab18xx.c (KConfig CONFIG_RTC_DRV_AB18XX) driver has been obsoleted and removed from the 3.16 and later kernel branches. There are known issues with the driver, it will not work correctly. Customers migrating from this legacy driver to the rtc-abx80x.c driver must ensure that their device tree uses the correct part number (e.g., ab1805 vs. ab1803) in order to instantiate the new driver.
Battery Backup¶
The "VBAT" input to the AB1805 device (Pin 5) is connected to the VBAT edge connector pin of the MitySOM-5CSx module (Pin 18). There is no battery installed on the MitySOM-5CSx module itself. If battery backup of the RTC is desired a battery/circuitry must be added to the carrier board.
If battery backed usage is not needed, Pin 18 of the module may be left floating and the RTC will function while power is applied to the module due to the Diode-Or circuit as shown below (+2.5V is an on SoM supply and +3VBAT is the VBAT input at pin 18 of the module):
VBAT Current Draw:¶
With the battery installed on the dev board and powering the RTC we have measured current draws as follows:
Measured Min | 310nA |
Measured Typ | 600nA |
Measured Max | 1.1uA |
Theoretical Max: 4.7uA
Note that both the RTC and Cyclone V VCCBAT Input (Ball D7) are powered by this battery. Depending on RTC mode operation the maximum expected current draw is ~330nA for the AB1805 component and the maximum expected current draw from the Cyclone V VCCBAT is ~4.4uA.
Battery life¶
The battery life will be dependent upon the cell size used, operating temperatures, self-discharge rate of the battery, configuration of the RTC device and configuration of the security volatile key reigster feature of the Cyclone V SoC.
In the example of our development board with a CR1025 cell we expect a range of approximately 3 to 10 years based on the Min/Max provided above.
Battery Life Calculator: https://www.maximintegrated.com/en/design/design-tools/calculators/product-design-calculators/battery.html
Timing and Calibration¶
The RTC implementation on the MitySOM-5CSx features a 32.768kHz Crystal connected to the XI (Pin 16)/XO (Pin 15) interface of the AB1805 device. Additionally a 47pF capacitor is connected to the "AF" pin (Pin 14) for "improved Auto calibration mode timing accuracy". This allows for the support of all calibration modes for the AB1805 device.
Advanced crystal calibration to ± 2 ppm
Advanced RC calibration to ± 16 ppm
Information concerning how to calibrate the RTC can be found on our RTC Calibration Process wiki page.
I2C Interface Delay Due to Temperature¶
Note that the AB1805 device may not be accessible over the I2C bus immediately upon application of power to the module in some cases.
Table 13 of the AB1805 Datasheet shows that there can be up to a 20 second delay at -40C from the time VCC goes high until FOUT goes high '1' (tVH:FOUT - VCC high to FOUT high). Until FOUT is high '1' the AB1805 device will not communicate with the I2C serial interface. Even at +25C there is a 0.5 second delay, unlikely to cause an issue in most cases.
Depending upon your specific software configuration your system may need to probe/re-scan the I2C0 bus after this delay period in order to communicate with the RTC device. For additional details regarding when the POR delay will be experienced in a design, refer to the AB18XX-Application-Manual, specifically Figure 31: Power States.
http://www.abracon.com/Support/AppsManuals/Precisiontiming/AB18XX-Application-Manual.pdf
Go to top