Edit

Share via


I2cDevice Class

Definition

The communications channel to a device on an I2C bus.

public abstract class I2cDevice : IDisposable
type I2cDevice = class
    interface IDisposable
Public MustInherit Class I2cDevice
Implements IDisposable
Inheritance
I2cDevice
Derived
Implements

Constructors

I2cDevice()

Properties

ConnectionSettings

The connection settings of a device on an I2C bus. The connection settings are immutable after the device is created so the object returned will be a clone of the settings object.

Methods

Create(I2cConnectionSettings)

Creates a communications channel to a device on an I2C bus running on the current platform

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Dispose(Boolean)

Disposes this instance

QueryComponentInformation()

Query information about a component and it's children.

Read(Span<Byte>)

Reads data from the I2C device.

ReadByte()

Reads a byte from the I2C device.

Write(ReadOnlySpan<Byte>)

Writes data to the I2C device.

WriteByte(Byte)

Writes a byte to the I2C device.

WriteRead(ReadOnlySpan<Byte>, Span<Byte>)

Performs an atomic operation to write data to and then read data from the I2C bus on which the device is connected, and sends a restart condition between the write and read operations.

Applies to