@rfbrw has helpfully pointed out that this DAC works on straight binary (unipolar) whereas audio DACs get given a bipolar (twos complement) input signal. So you'll want to invert the MSB between the HC595 and the AD768.
I missed this earlier, sorry. So, the solution would be to place a logic IC between the HC595 and AD768 to perform the inversion?
Yes, just an HC04 (assuming its fast enough which probably it is unless you want to run insanely fast sample rates!).
Surely flipping the MSB gets you complementary offset binary ? The issue as I see it is the sign bit used to signify positive and negative. Straight binary does not have one as it is only positive.
Last edited:
I haven't worked it out with pencil and paper, just imagined it in my head. Which is fraught with opportunities for error 😀
Here is a useful document - https://www.ti.com/lit/an/sbaa042a/sbaa042a.pdf
Scrolling down to p8 of the above document it shows an MSB inverter is able to convert between BTC and BOB. Now BOB isn't exactly the code that the AD768 accepts, rather its USB (first coding example). Which differs only from BOB in that BOB is bipolar, otherwise the code mapping is the same. So I reckon the MSB inverter should work (famous last words!).
Here is a useful document - https://www.ti.com/lit/an/sbaa042a/sbaa042a.pdf
Scrolling down to p8 of the above document it shows an MSB inverter is able to convert between BTC and BOB. Now BOB isn't exactly the code that the AD768 accepts, rather its USB (first coding example). Which differs only from BOB in that BOB is bipolar, otherwise the code mapping is the same. So I reckon the MSB inverter should work (famous last words!).
Last edited:
This may be a stupid question, but given that HC04 is a hex inverter, does that mean it will invert 6 bits and therefore I would need to use three of them to invert the 16 parallel bits going into the AD768?
The HC04 is a hex, but you only need use one instance within it to invert the MSB. Perhaps others will come in handy for the latching logic to drive the HC595s.
Will the Toshiba 74AC04P work for inverting the MSB? Just want to double check before I order.
I take it these chips are industry standard and the [SIZE=-1]Logic IC Base Number: 7404 is what counts so all the plethora of 74**04 chips are all basically the same in functionality?
[/SIZE]
I take it these chips are industry standard and the [SIZE=-1]Logic IC Base Number: 7404 is what counts so all the plethora of 74**04 chips are all basically the same in functionality?
[/SIZE]
... all the plethora of 74**04 chips are all basically the same in functionality?
The same functionality, except for a few differences.
74HCT04 accepts TTL input logic levels
74HC04 accepts CMOS
I would use HCT (or AHCT) everywhere, because most USB/I2S devices works with TTL signals 🙂
Here is the relationship between different DAC input formats (as abraxalito said, just invert the MSB)
Yes + delay LE for 1 BCK if I2S used. I think that format is left justified. I did the same with one of my diskrete dac input shift register with I2S.
.
220r maybe will be too high value use 100-120ohm. Or better meassure with scope for proper signal integrity.
I have used resistor arrays in DIP sockets so I can very simply change them if 220 proves to be too high.
Also this setup with 2x8bit shifr register is for 16bits LE length. BUT all contemporry digital iterfaces use 32bit word LE length. Maybe 4 x 8bit register should use and employ only first 16 bits.
.
I will try to sketch SCH
.
I will try to sketch SCH
- Home
- Source & Line
- Digital Line Level
- AD768 as audio DAC