Class Mcp7940n
Battery-Backed I2C Real-Time Clock/Calendar with SRAM.
public class Mcp7940n : Mcp7940m
- Inheritance
-
Mcp7940n
- Derived
- Inherited Members
Constructors
Mcp7940n(I2cDevice, ClockSource)
Initializes a new instance of the Mcp7940n class.
public Mcp7940n(I2cDevice i2cDevice, ClockSource clockSource)
Parameters
i2cDevice
I2cDeviceThe I2C device to use for communication.
clockSource
ClockSourceThe clocks oscillator configuration.
Exceptions
- ArgumentNullException
Thrown when
i2cDevice
isnull
.
Properties
HasPowerFailureAlert
Gets a value indicating whether the device has experienced a power failure.
public bool HasPowerFailureAlert { get; }
Property Value
IsEnabledExternalBatteryBackup
Gets a value indicating whether the external battery backup is enabled.
public bool IsEnabledExternalBatteryBackup { get; }
Property Value
Methods
ClearPowerFailureAlert()
Clears the power failure alert flag.
public void ClearPowerFailureAlert()
DisableExternalBatteryBackup()
Disables external battery backup.
public void DisableExternalBatteryBackup()
EnableExternalBatteryBackup()
Enables external battery backup.
public void EnableExternalBatteryBackup()
GetLastPowerDown()
Gets a Mcp7940n.PowerEvent object that is set to the date and time of the last power down event.
public Mcp7940n.PowerEvent GetLastPowerDown()
Returns
- Mcp7940n.PowerEvent
An object whose value is the date and time of the last power down event.
GetLastPowerUp()
Gets a Mcp7940n.PowerEvent object that is set to the date and time of the last power up event.
public Mcp7940n.PowerEvent GetLastPowerUp()
Returns
- Mcp7940n.PowerEvent
An object whose value is the date and time of the last power up event.