making a simple DAC (be gentle)

Hi all,

I have a fairly simple project I'm working on, and I'm hoping somebody can confirm or deny that arduino would be a viable (even good, perhaps) solution for me.

Essentially, I'm trying to interface with an old analog chart recorder. The chart recorder takes a +DC voltage, and moves a pen along along a roll of paper as that voltage increases and decreases. A knob on the front of the chart recorder lets you select a voltage sensitivity, from 1 mV up to 10V.

What I'd like is something which is connected to a computer, and which takes a changing integer value (0-99 or 0-255 or something) and outputs a voltage proportional to the input value. Simplest example would be outputting 1 mV for 1, 10 mV for 10 etc.

This should be relatively easy to accomplish, correct? I've never used arduino before, but it seems well suited to this project.

one minor point of confusion before I finish: with a board like the Uno, can the USB input be used to receive and transmit data while the board is active, or is it only for loading firmware? Do I need a usb shield or something to transmit data from the computer in real-time?

thanks in advance for your help.

The Arduino doesn’t have a pure analog output capablity built in. One could attach a true digital to analog chip if wanted. However the arduino does have PWM analogWrite outputs, that if you filter with a simple resistor/capacitor low pass filter, becomes a 0-5vdc true analog output voltage that has 256 (0-255) steps of resolution. You can then use a resistor divider to lower the voltage range, or a simple DC op-amp to raise the voltage range, or if your chart has a 0-5vdc range just leave it as is.

one minor point of confusion before I finish: with a board like the Uno, can the USB input be used to receive and transmit data while the board is active, or is it only for loading firmware? Do I need a usb shield or something to transmit data from the computer in real-time?

The built-in USB port can be used in your sketch to send and receive charaters to an attached PC. That is what all the serial commands are all about. http://arduino.cc/en/Reference/Serial

Lefty