Treehopper C# API
Mcp4725 Class Reference

Microchip MCP4725 12-bit DAC More...

Inheritance diagram for Mcp4725:
Dac

Public Member Functions

 Mcp4725 (I2C i2c, bool addr=false, double refVoltage=3.3, int speed=400)
 Construct an MCP4725 More...
 
 Mcp4725 (I2C i2c, byte address, double refVoltage=3.3, int speed=400)
 Construct an MCP4725 More...
 

Properties

double ReferenceVoltage [get, protected set]
 Gets the reference voltage of this DAC More...
 
double Voltage [get, set]
 Get or set the output voltage of the DAC More...
 
double Value [get, set]
 Get or set the output value of the DAC, normalized from 0-1 More...
 
int DacValue [get, set]
 Get or set the raw, 12-bit value of the DAC More...
 

Detailed Description

Microchip MCP4725 12-bit DAC

Constructor & Destructor Documentation

◆ Mcp4725() [1/2]

Mcp4725 ( I2C  i2c,
bool  addr = false,
double  refVoltage = 3.3,
int  speed = 400 
)

Construct an MCP4725

Parameters
i2cThe I2c bus this DAC is attached to
addrThe address pin state
refVoltageThe voltage of the VDD pin
speedThe speed to use

◆ Mcp4725() [2/2]

Mcp4725 ( I2C  i2c,
byte  address,
double  refVoltage = 3.3,
int  speed = 400 
)

Construct an MCP4725

Parameters
i2cThe I2c bus this DAC is attached to
addressThe address to use
refVoltageThe voltage of the VDD pin
speedThe speed to use

Property Documentation

◆ ReferenceVoltage

double ReferenceVoltage
getprotected set

Gets the reference voltage of this DAC

◆ Voltage

double Voltage
getset

Get or set the output voltage of the DAC

◆ Value

double Value
getset

Get or set the output value of the DAC, normalized from 0-1

◆ DacValue

int DacValue
getset

Get or set the raw, 12-bit value of the DAC


The documentation for this class was generated from the following file: