Hello, I am new to AVR programming and have a question about how to use the ADC and DAC. What I would like to do is take an input from the ADC, and based on this input, output a voltage on the DAC. However, the output on the DAC doesn't correspond directly to the ADC input.
For example lets say I have an input voltage to the ADC of 0 to 3 volts. For the range of 0 to 1.5 volts, I would like the DAC to output a respective range of 0 to 1 volts, At 1.5 volts the DAC should output 0 volts, and for the range of 1.5 to 3 volts the DAC should again output a respective range of 0 to 1 volts.
I was wondering if anyone would be so kind as to point me at any tutorials or code examples that could help me? Thanks in advance!