tinygo.org/x/drivers@v0.27.1-0.20240509133757-7dbca2a54349/ds3231/registers.go (about) 1 package ds3231 2 3 // The I2C address which this device listens to. 4 const Address = 0x68 5 6 // Registers 7 const ( 8 REG_TIMEDATE = 0x00 9 REG_ALARMONE = 0x07 10 REG_ALARMTWO = 0x0B 11 12 REG_CONTROL = 0x0E 13 REG_STATUS = 0x0F 14 REG_AGING = 0x10 15 16 REG_TEMP = 0x11 17 18 REG_ALARMONE_SIZE = 4 19 REG_ALARMTWO_SIZE = 3 20 21 // DS3231 Control Register Bits 22 A1IE = 0 23 A2IE = 1 24 INTCN = 2 25 RS1 = 3 26 RS2 = 4 27 CONV = 5 28 BBSQW = 6 29 EOSC = 7 30 31 // DS3231 Status Register Bits 32 A1F = 0 33 A2F = 1 34 BSY = 2 35 EN32KHZ = 3 36 OSF = 7 37 38 AlarmFlag_Alarm1 = 0x01 39 AlarmFlag_Alarm2 = 0x02 40 AlarmFlag_AlarmBoth = 0x03 41 42 None Mode = 0 43 BatteryBackup Mode = 1 44 Clock Mode = 2 45 AlarmOne Mode = 3 46 AlarmTwo Mode = 4 47 ModeAlarmBoth Mode = 5 48 )