DAC in Audio Codec Shield

Re: DAC in Audio Codec Shield

Postby guest » Thu May 15, 2014 3:15 pm

you might be able to do it with the code. the codec has an adjustable input gain. these are set with:

LINVOL
RINVOL

before the #include <AudioCodec.h>
put the following
Code: Select all
#define LINVOL 20
#define RINVOL 20


you can adjust the value till you get something that works for your range. the value can be anything between 0 and 31.

once you get that working, you might need to adjust the output to match. the lineout does not have a gain adjust, but the headphone out does. that is set with LHPVOL and RHPVOL. you can take a look at all the setting parameters in the .h file in the library.
guest
Site Admin
 
Posts: 449
Joined: Thu May 20, 2010 11:58 pm

Re: DAC in Audio Codec Shield

Postby rputra » Mon Jul 07, 2014 4:33 am

One of the replies mentioned the same problem but I don't quite get the solution. I intended to generate 16 kHz tone with the DAC but beyond 14 kHz the audio codec just went mute. I tried changing the sample rate to 88 kHz but it made no difference. What seems to be the problem?
rputra
 
Posts: 3
Joined: Thu Apr 10, 2014 10:42 pm

Re: DAC in Audio Codec Shield

Postby guest » Mon Jul 07, 2014 10:15 am

how are you generating the 16kHz tone? are you using the sine_generator example?

how are you testing for the tone? are you using an oscilloscope, or headphones plugged directly into the HP_OUT on the codecshield? or are you going through another amp?
guest
Site Admin
 
Posts: 449
Joined: Thu May 20, 2010 11:58 pm

Previous

Return to Audio Codec Shield

Who is online

Users browsing this forum: No registered users and 1 guest


cron