SubSub page: Resistor DAC
Introduction:
Connecting a weighted resistor network to binairy outputs creates a DAC.
The microprocessor simply does a portwrite command to write the value.
8 resistors would create an 8 bit DAC (256 values).
Being short on pins I made a version that needs 6 pins and 6 resistors to get 216 values (close to 8 bit).
This is what I called a "BiTriDAC.
It is a combination of 3 binairy (2 positions) and 3 trinairy (3 positions) weighted outputs.
This way you get 2x2x2x3x3x3=216 values.
The trinairy 3 value output is created by using: output-high/input/output-low positions.
For this you need to make 2 tables: one for the output value that you write to the port
and one for the data direction register (ddr) for that port.
I made it such that for each value 0-255 I have 2 corresponding table inputs.
Each input value (0-255) is mapped to the 216 table values by adding a softclip curve at both ends.
This adds an analog style smooth-clipping to the input data.
This BiTriDAC is used in the MonoVoks2, the Monoladder1 and the PRBSynth1.
Here are the conversion table and the resistor ratios:
More text will be added here