I am new to electrical engineering and the first project I would like to do is making a digital to analog audioconverter. I've found out that a good way to do this is to use an R-2R structure for the conversion.
I'd like to challenge myself and start from scratch with the digital part of the circuit, besides the fact that I can't really find any solutions on the web to help building it. I've got a circuit simulation program and started designing, while searching the web for all different kinds of electronics you might use for it.
Now I think I might be somewhere in the neighbourhood of understanding the principle of a DAC, but it would be helpful if someone experienced could help me check if I do in fact get it. Is this a right place to ask for that?
I have used a shift register with output latch for each channel and linked Q7S from one to the other to feed the data. Is it right that audio files alternate left and right channel, or vice versa, in blocks? e.g. in an 8-bit file: 0010 0111 for left following 0010 0110 for right?
The shift registers I've used here are 74HC595s. When shifting-in bits non of the pins will be (momentarily) be active. When the latch [STCP pin] is triggered the bits get transferred from the shift register into the storage register, where they will directly output their value to the corresponding pins and stay active until the next 16 bits are allowed in.
Then there is the crystal, for which I've used a square wave signal to imitate one with the right oscillating frequency: 24,576MHz. It feeds the counter in which the frequency gets divided to output the frequencies my DAC needs. In this case the sample frequency has to be 192.000kHz and therefore the frequency at which the data is shifted in has to be 3.02MHz (192.000 x 16 bit). The 192.000kHz clock speed is used to trigger STCP.
The next thing I want to do is to figure out how to load data from a source (Raspberry for example) through maybe I2C into a buffer in the DAC and from there clock the bits out into the circuit you see here.
If you think I am or I am not on the right way, it would be very helpful to let me know.
By the way, I forgot to mention that the DAC I would like to build is at least 24-bit per channel at 96kHZ. It just takes up a lot of space on this threat and shouldn't be difficult to add them afterwards. It's the same principle.