I want to display a sine wave signal in a software program that I apply to the analog audio input of the codec. I get the data in the receive buffer, then convert it from a fixed-point format to a 32-bit floating-point format, but I do not know how to convert this data into an effective signal (amplitude in volts). Thank you.

Parents
• Hello Jerca,

First you have to realize that it is just a number, it does not represent anything real outside of the digital world. First we have to assign some sort of standard to what full-scale is. The DAC is what assigns what the voltage will be. So a full scale number will produce a full scale voltage out of the DAC. In the case of the AD1938 the full scale voltage is 0.88V rms or 2.48Vp-p. Then you can divide this by the number of possible values, 2^24, to get the voltage of a single bit. So the same digital number will produce a different voltage out of different DACs depending on their internal reference.

For a 24 bit number that is in 2's compliment form,  the max number will be 0x7FF in hex for a positive number and 0x800 for a maximum negative number. Now this does not mean that the DAC will produce a negative voltage. Some do but many do not. Many DACs, the AD1938 included, have outputs raised up to a common mode voltage. This voltage will be the voltage of a zero in the data. So send out a 000 to the AD1938 and you will get 1.5V out of the DAC. A positive number into the DAC will produce a more positive voltage than 1.5V and a negative number sent to the DAC will produce a DC level less than 1.5V but never less than zero. Actually, I don't think it will be able to reach zero.

So if you need to output DC out of the converter, you will need to reference the external Op-amps to the common mode voltage then translate it to what is required for the application.

The same applies to the ADC side of things. Just as Tyler explained.

I hope this helps.

Dave T

• Hello Jerca,

First you have to realize that it is just a number, it does not represent anything real outside of the digital world. First we have to assign some sort of standard to what full-scale is. The DAC is what assigns what the voltage will be. So a full scale number will produce a full scale voltage out of the DAC. In the case of the AD1938 the full scale voltage is 0.88V rms or 2.48Vp-p. Then you can divide this by the number of possible values, 2^24, to get the voltage of a single bit. So the same digital number will produce a different voltage out of different DACs depending on their internal reference.

For a 24 bit number that is in 2's compliment form,  the max number will be 0x7FF in hex for a positive number and 0x800 for a maximum negative number. Now this does not mean that the DAC will produce a negative voltage. Some do but many do not. Many DACs, the AD1938 included, have outputs raised up to a common mode voltage. This voltage will be the voltage of a zero in the data. So send out a 000 to the AD1938 and you will get 1.5V out of the DAC. A positive number into the DAC will produce a more positive voltage than 1.5V and a negative number sent to the DAC will produce a DC level less than 1.5V but never less than zero. Actually, I don't think it will be able to reach zero.

So if you need to output DC out of the converter, you will need to reference the external Op-amps to the common mode voltage then translate it to what is required for the application.

The same applies to the ADC side of things. Just as Tyler explained.

I hope this helps.

Dave T

Children
No Data