Class At24Cxx
Encapsulation for EEPROMs based upon the AT24Cxx family of chips
Assembly: At24Cxx.dll
View Source
public class At24Cxx : II2cPeripheral
Implements:
Meadow.Hardware.II2cPeripheral
Properties
DefaultI2cAddress
The default I2C address for the peripheral
View Source
public byte DefaultI2cAddress { get; }
PageSize
Number of bytes in a page
View Source
public ushort PageSize { get; }
MemorySize
Number of bytes in the EEPROM module
View Source
public ushort MemorySize { get; }
Fields
i2cComms
I2C Communication bus used to communicate with the peripheral
View Source
protected readonly II2cCommunications i2cComms
Methods
Read(ushort, ushort)
Force the sensor to make a reading and update the relevant properties.
View Source
public byte[] Read(ushort startAddress, ushort amount)
Returns
System.Byte[]
Parameters
Type | Name | Description |
---|---|---|
System.UInt16 | startAddress | Start address for the read operation. |
System.UInt16 | amount | Amount of data to read from the EEPROM. |
Write(ushort, params byte[])
Write a number of bytes to the EEPROM.
View Source
public void Write(ushort startAddress, params byte[] data)
Parameters
Type | Name | Description |
---|---|---|
System.UInt16 | startAddress | Address of he first byte to be written. |
System.Byte[] | data | Data to be written to the EEPROM. |
Implements
Meadow.Hardware.II2cPeripheral