Skip to main content

DacChannel Class

Package: GHIElectronics.Endpoint.Devices.Dac
Namespace: GHIElectronics.Endpoint.Devices.Dac

A DAC channel opened with DacController.OpenChannel. DacChannel.WriteValue takes a raw value, DacChannel.WriteValue a 0.0 to 1.0 part of the range.

class DacChannel(IDisposable): ...

Properties​

ChannelNumber​

ChannelNumber: int # @property

The channel number, as given to OpenChannel

Returns int

Controller​

Controller: DacController # @property

The controller that opened the channel

Returns DacController

LastWrittenValue​

LastWrittenValue: int # @property

The last raw value written

Returns int

Methods​

Dispose()​

def Dispose(self) -> None:

Switches the output off and puts the pin back as it was

WriteValue(double ratio)​

def WriteValue(self, ratio: float) -> None:

Sets the output to a part of the range: 0.0 is 0 V, 1.0 is 3.3 V

WriteValue(int value)​

def WriteValue(self, value: int) -> None:

Sets the output to a raw value from MinValue (0 V) to MaxValue (3.3 V)