Control and Status Request enumerated type.
This enumerated type is used with the control() and status() methods to identify the control action request.
Enumerator |
---|
DS3231_CLOCK_HALT | Controls the EOSC bit. When set to ON, the oscillator is stopped when the DS3231 switches to battery, effectively stopping any RTC functions. This bit is OFF when power is first applied. When the DS3231 is powered by Vcc, the oscillator is always on regardless of this status.
|
DS3231_SQW_ENABLE | Controls the BBSQW bit. This bit is OFF when power is first applied. When set to ON with INT_ENABLE OFF, the square wave output is enabled.
|
DS3231_SQW_TYPE | Controls the RS1 and RS2 bits to control the frequency of the square wave output. When power is first applied SQW_8KHZ is selected.
|
DS3231_12H | Controls whether the library is using 24 hour time or AM/PM designation. Setting ON enables 12 hour time and AM/PM.
|
DS3231_TCONV | Controls the CONV bit. Setting this ON forces the temperature sensor to convert the temperature into digital code and execute the TCXO algorithm. The user should check the status of BUSY_FLAG before forcing the controller to start a new TCXO execution. The TCONV status remains ON from the time it is written until the conversion is finished, at which time both TCONV and BUSY_FLAG go OFF. The TCONV status should be used when monitoring the status of a user-initiated conversion.
|
DS3231_INT_ENABLE | Controls the INTCN bit. When set OFF, a square wave is output on the INT/SQW pin. When set ON, then the Alarm interrupt functions are enabled if the corresponding alarm interrupt is also enabled. The corresponding An_FLAG is always set regardless of this status. The function is ON when power is first applied.
|
DS3231_A1_INT_ENABLE | Controls the A1E bit. When ON, the this bit enables the A1_FLAG bit to generate an interrupt when INT_ENABLE is also ON. When this is OFF, or INT_ENABLE is OFF, no interrupt signal is generated for Alarm 1. A1_INT_ENABLE is OFF when power is first applied.
|
DS3231_A2_INT_ENABLE | Controls the A2E bit and operates like A1_INT_ENABLE but for alarm 2.
|
DS3231_HALTED_FLAG | Controls the OSF bit. When ON, this indicates that the oscillator either is stopped or was stopped for some period and may be used to judge the validity of the timekeeping data. It remains ON turned OFF by user code.
|
DS3231_32KHZ_ENABLE | Controls the EN32KHZ bit. When set to ON, the 32kHz pin is enabled and outputs a 32.768kHz square wave signal. When set OFF, the 32kHz pin goes to a high-impedance state. The initial power-up state is ON.
|
DS3231_BUSY_FLAG | Reports the BSY bit. This status indicates the device is busy executing TCXO functions. It goes ON when the conversion is being carried out and then set to OFF when the TCXO is in the idle state.
|
DS3231_A1_FLAG | Controls the A1F bit. When ON, it indicates that the time matched the alarm 1 registers. If A1_FLAG is ON and the INT_ENABLE status IS ON, an interrupt is also generated for the alarm. A1_FLAG is only cleared when written OFF by the user code.
|
DS3231_A2_FLAG | Controls the A2F bit and operates like the A1_FLAG except for alarm 2.
|
DS3231_AGING_OFFSET | Controls the Aging Offset register value. The register takes a user-provided value to add to or subtract from the codes in the capacitance array registers. The code is encoded in two's complement, with bit 7 representing the sign bit.
|