Show / Hide Table of Contents

Interface II2c

Interface for i2c communication

Namespace: Elatec.FCT.Client.Hardware
Assembly: ElatecFCT.dll
Syntax
public interface II2c

Methods

View Source

ReadByte(Byte, Byte)

Read i2c byte by passing i2c adress and memory adress

Declaration
byte ReadByte(byte deviceAdresss, byte adress)
Parameters
Type Name Description
System.Byte deviceAdresss
System.Byte adress
Returns
Type Description
System.Byte
View Source

ReadReg(Byte, Byte, Int32)

Read from i2c register

Declaration
byte[] ReadReg(byte Deviceaddress, byte Regaddress, int length)
Parameters
Type Name Description
System.Byte Deviceaddress

i2c device address

System.Byte Regaddress

Register address

System.Int32 length

Lenght of the data to read

Returns
Type Description
System.Byte[]
View Source

WriteByte(Byte, Byte, Byte)

Write i2c byte to memory by passing i2c adress, memory adress and data to be written

Declaration
void WriteByte(byte deviceAdresss, byte adress, byte data)
Parameters
Type Name Description
System.Byte deviceAdresss
System.Byte adress
System.Byte data
View Source

WriteReg(Byte, Byte, Byte[], Int32)

Write to i2c register

Declaration
void WriteReg(byte Deviceaddress, byte Regaddress, byte[] data, int length)
Parameters
Type Name Description
System.Byte Deviceaddress

i2c device address

System.Byte Regaddress

Register address

System.Byte[] data

Data to write

System.Int32 length

Lenght of the data

  • View Source
In This Article
Back to top Generated by DocFX