Skip to main content

Class Si1145

Represents a SiLabs Proximity, UV, and ambient light sensor

Assembly: Si1145.dll
View Source
public class Si1145 : ByteCommsSensorBase<(Illuminance? VisibleLight, double? UltravioletIndex, Illuminance? Infrared)>, IObservable<IChangeResult<(Illuminance? VisibleLight, double? UltravioletIndex, Illuminance? Infrared)>>, ISamplingSensor<(Illuminance? VisibleLight, double? UltravioletIndex, Illuminance? Infrared)>, ISensor<(Illuminance? VisibleLight, double? UltravioletIndex, Illuminance? Infrared)>, ISensor, ISamplingSensor, IDisposable, II2cPeripheral

Inheritance: System.Object -> Meadow.Foundation.ObservableBase<UNIT> -> Meadow.Foundation.SamplingSensorBase<UNIT> -> Meadow.Foundation.PollingSensorBase<UNIT> -> Meadow.Foundation.ByteCommsSensorBase<UNIT>

Implements:
System.IObservable<Meadow.IChangeResult<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>>, Meadow.Peripherals.Sensors.ISamplingSensor<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>, Meadow.Peripherals.Sensors.ISensor<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>, Meadow.Peripherals.Sensors.ISensor, Meadow.Peripherals.Sensors.ISamplingSensor, System.IDisposable, Meadow.Hardware.II2cPeripheral

Properties

DefaultI2cAddress

The default I2C address for the peripheral

View Source
public byte DefaultI2cAddress { get; }

Methods

ReadSensor()

Read data from the sensor

View Source
protected override Task<(Illuminance? VisibleLight, double? UltravioletIndex, Illuminance? Infrared)> ReadSensor()
Returns

System.Threading.Tasks.Task<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>: Returns visible, ultraviolet index and infrared data

Implements

  • System.IObservable<Meadow.IChangeResult<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>>
  • Meadow.Peripherals.Sensors.ISamplingSensor<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>
  • Meadow.Peripherals.Sensors.ISensor<System.ValueTuple<System.Nullable<Meadow.Units.Illuminance>,System.Nullable<System.Double>,System.Nullable<Meadow.Units.Illuminance>>>
  • Meadow.Peripherals.Sensors.ISensor
  • Meadow.Peripherals.Sensors.ISamplingSensor
  • System.IDisposable
  • Meadow.Hardware.II2cPeripheral