Go Down

### Topic: Offset voltage on Arduino due DAC0 / DAC1 (Read 2723 times)previous topic - next topic

#### dformenton

##### Jul 20, 2013, 12:27 pm
Hi,

with statement:

analogWrite(DAC0, 0);

instead of 0 volt output I find 0,540 volt. It seems as an offset voltage.

Is it normal? Is my Arduino damaged?

How I can avoid such offset to obtain output of 0 Volt with input value = 0?

Thank you

Domenico

#### Gericom

#1
##### Jul 20, 2013, 07:25 pm

Hi,

with statement:

analogWrite(DAC0, 0);

instead of 0 volt output I find 0,540 volt. It seems as an offset voltage.

Is it normal? Is my Arduino damaged?

How I can avoid such offset to obtain output of 0 Volt with input value = 0?

Thank you

Domenico

Yes, that's normal.

#### masumi

#2
##### Jul 25, 2013, 03:04 pm
it seems that many people have this trap.
Me too.:-)
http://forum.arduino.cc/index.php?topic=173747

#### HermannSW

#3
##### Mar 04, 2016, 04:15 pm
OK, I did run into this issue as well and did measure complete curve, after having measured 0.5V/1.51V/2.41V on DAC1 when writing 0/2048/4095 to DAC1 with "analogWriteResolution(12)".

Then I used direct connection between DAC1 and A11, with just a cable and with a 1kΩ resistor.
The middle part of the curve is quite linear, but it does not start at 0 and does not end at 1023:

This is the small sketch used:
Code: [Select]
`void setup() {  pinMode(A10, INPUT);  pinMode(DAC1, OUTPUT);  analogWriteResolution(12);  Serial.begin(9600);}void loop() {  for(int i=0; i<4095; i+=100) {    Serial.print(i);    Serial.print(" ");    analogWrite(DAC1, i);    Serial.print(analogRead(A10));    Serial.print(" ");    delay(100);    Serial.println(analogRead(A10));  }}`

I plan to use one of DAC0-1 to one of A0-11 connection for playing with PID library.
First test on UNO with PWM showed that DAC is desirable for that.

Hermann.
https://forum.arduino.cc/index.php?topic=462107.msg3236016#msg3236016
http://stamm-wilbrandt.de/en/Raspberry_camera.html

Go Up