Quote:
I'm planning to use Linear's LTC1660 DAC, which Microchip DAC did you went with?
I actually used a Microchip MCP4822 or 4821 (not at desk, so not quite sure!) which went well. An extract of my code follows.
void Output_Volts(unsigned short Analog_out)
{
unsigned short Code_out; // unsigned 16bits
Code_out = 0x3000 + Analog_out; // 0x11 = ChanA,x,Vout =Vref * data/4096, Output active
// Send 0x3XXX, the command to set 0x11,NibH, NibM, NibL i.e 0x3,data 12bits
cs = 0; // Select the device by seting chip select low
spi_dac.write(Code_out);
cs = 1; // this action actually writes the data to the analog out pin
}
simply called in my case by (yes I know it could be done in one line... but I wanted to keep final calculations separate).
Analog_out = 0x7FF; // set for nominal zero volts *** need to add in calibration offset
Output_Volts(Analog_out); // output to SPI dac
These DAC's work well an I powered mine from a low noise 5V linear regulator and treated the whole circuit as an analogue part to keep all digital noise away.
Re thinking your requirements....
12Volts will be more 'normally' available, but will often be used with solenoids and valves etc., so will be noisey.
With your own dedicated supply I would use the 5V supply to keep disipation lower and use a 5V to +/-12V module. As Ceri refered to a "lego brick" mine was a NMK0515SAC (actually +/-15V) and with the recommended decoupling and filtering worked well.
Contrary to Ceri's comment on battery power, mine is battery powered using NMHi AA cells of 2,400mAH capacity and with my usage duty cycle and expected system use duration between recharges works well, so it depends on your application, but for you this is not an issue.
Just to add a few extra comments on the mbed;
I use multiple A/D readings per point i.e. readings are recorded at 100mS intervals but each is the average of 25 readings, using this techniquie I achieve sub one bit resolution.
The external 3V3 supply is different from the onboard mbed 3V3 supply and as such may not track well if used for biasing the DAC output around zero i.e. bipolar operation.
Makes sure you decouple the mbed well close to the pins, someone advised me to treat the mbed as a 'regulator chip' with a good input and output capacitors to a ground plane/ ground point and this worked well. Also use several ceramic capitors in parallel, high values and low to get rid of the supply spikes.
Hope that helps.
I'm moving along with my project and now I have to make a design choice that I'm not sure which direction to take: the power supply voltage.
Here are the project facts:
All of this can be easily done with a 5V power supply except for the last one. To get 0-10V I need to amplify a 0-3.3v analog output (that I generate either via an external DAC or by adding a RC filter on a PWM port) with an opamp, this will require a power supply slightly above 10V.
Given that a separated power supply for this part alone is the least preferred option what would you recommend? My limited head proposed to me so far: 1) a 12V power supply with a switching step-down to 5V which will drive everything and let 12V directly into the opamp. 2) a 5V power supply to drive everything and a step-up circuit just to drive the 0-10V opamps.
I'm open to all ideas :)
Thanks
Silvio