Table of Contents

Class Ads1115.Sim

Namespace
Pamoja.Sensors
Assembly
Pamoja.Sensors.dll

An ADS1115 that is not there, for a bus with nothing plugged in.

public static class Ads1115.Sim
Inheritance
Ads1115.Sim
Inherited Members

Remarks

A conversion comes back as a count of the range the gain selects, so Reporting(byte, Pga, float) takes the same gain a driver is given. The part keeps whatever configuration a driver writes, so a conversion a driver starts reads as finished.

Fields

Volts

The voltage Part(byte) reports: half a 3.3 V supply.

public const float Volts = 1.65

Field Value

float

Methods

Part(byte)

Makes a part reading Volts at the range a driver starts with.

public static WordPart Part(byte address)

Parameters

address byte

The address it answers to.

Returns

WordPart

The part, to put on a simulated bus.

Reporting(byte, Pga, float)

Makes a part that reads what it is asked to at the range a driver converts at.

public static WordPart Reporting(byte address, Ads1115.Pga gain, float volts)

Parameters

address byte

The address it answers to.

gain Ads1115.Pga

The range the driver converts at.

volts float

The voltage it reports, held to the range.

Returns

WordPart

The part, to put on a simulated bus.