MCP4725 I2C DAC Breakout board
2023-10-30
Bought from here
#include <Wire.h>
#include <Adafruit_MCP4725.h>
Adafruit_MCP4725 dac;
#define DAV_RESOLUTION (9)
void setup() {
Serial.begin(9600);
Serial.println("MCP4725 Test");
// 0x62 default
// 0x63 Addr pin tied to VCC
// 0x60 Addr pin tied to GND
dac.begin(0x60);
}
void loop() {
for (int x=1;x<=5;x++){
dac.setVoltage(x*4096/5, false);
delay(50);
}
}
Testing maximum frequency, around 800us
#include <Wire.h>
#include <Adafruit_MCP4725.h>
Adafruit_MCP4725 dac;
#define DAV_RESOLUTION (9)
void setup() {
Serial.begin(9600);
Serial.println("MCP4725 Test");
// 0x62 default
// 0x63 Addr pin tied to VCC
// 0x60 Addr pin tied to GND
dac.begin(0x60);
}
void loop() {
dac.setVoltage(1, false);
dac.setVoltage(4095, false);
}