0

My question is simple. Is the following possible?

I am using one Arduino Mega 2560 board and its SPI functionality to adjust voltages (0-4.096V) through a 12-bit DAC (MCP4822).

I would like to measure the output voltages from the DAC by feeding them through a 12-bit ADC and back to the Arduino. The DAC's output voltages that will be directly measured by the ADC will be displayed on an LCD and on LabVIEW.

Is this possible, given that both the DAC and the ADC have to be connected to the same SDI and SCK pins on the Arduino for SPI to work?

2

Yes, perfectly possible. Just provide two separate CS pins to select between the two devices.

  • Perfect.. Given that the DAC and ADC have to be connected to the same SCK and SDI pins, I'm assuming that the ADC cannot update the voltages (send data) until the CS pin on the DAC is inactive (low with the MCP4822). The CS pins on both the DAC and the ADC cannot be active at the same time, correct? – user3720702 Jan 20 '16 at 18:31
  • That is correct. You set the DAC first then read the voltage second. – Majenko Jan 20 '16 at 18:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.