Pages: [1] 2   Go Down
Author Topic: Do not follow Simple Audio Player example - DAC0 now non-functional on DUE  (Read 8358 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 2
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Just to let everyone know - do not follow the Arduino Due Simple Audio Player example and connect a speaker direct to DAC0 without resistors.  My DAC is now damaged.

Is there anyway to get a replacement?  I know it is normally experimenter beware, but I was just following directions in the official IDE...
« Last Edit: December 29, 2012, 03:40:54 pm by jknighton » Logged

Poland, Lodz
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino Due & Leonardo
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Did you use a 8-Ohm speaker?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 15
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I once read that the Due DAC's highest voltage is about 2.55 V, with 8 Ohm I get about 318 mA. Isn't that already too high for the uC?
Possible options: 318 mA are no problem or it isn't 8 Ohm because the impedance depends on the frequency.
Another related question: If 8 Ohm Speakers work without a resistor, is it then possible to use 4 Ohm Speakers and simply add a 4 Ohm resistor? I'm hoping for appropriate help smiley

Greetings
decrux
Logged

St. Petersburg, FL
Offline Offline
Jr. Member
**
Karma: 1
Posts: 61
Retired physicist
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

You need an audio amplifier chip between the Due and the speaker. There are many but the LM380 or LM383 would work nicely.
Logged

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 513
Posts: 31529
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
318 mA are no problem
Yes it is.
Quote
it isn't 8 Ohm because the impedance depends on the frequency.
True but the impedance is still too low for the pin.

Quote
is it then possible to use 4 Ohm Speakers and simply add a 4 Ohm resistor?
No.
The current limit on a Due is about 15mA so a 220R resistor is about as small as you can go. At that there will be so little current trough the speaker I doubt if you can hear anything. I would recommend a headphone ear piece, a 1uF capacitor and a 470R resistor all in series. Or an external amplifier.
Logged

Forum Administrator
Offline Offline
God Member
*****
Karma: 47
Posts: 629
I find plain exciting
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

That tutorial is clearly wrong and I am sorry it slipped past the QA process..
It's being removed now.
jknighton please write to support (at) arduino.cc explaining the situation and you'll get a new board

I'm sorry for the inconvenient

m
Logged

0
Offline Offline
Full Member
***
Karma: 2
Posts: 109
ArduiYES!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

for what it's worth, I have had good success creating sound using a *powered* PC speakerset.

just find the (green) plug of the speakerset and connect ground and a channel to the gnd and dac pin respectively. 

Logged

Dubai, UAE
Offline Offline
Edison Member
*
Karma: 21
Posts: 1670
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
My DAC0 has also just died, in my case the Arduino was connected to an LM386 amp. I cannot find any problems with the amp, I am posting in case others have similar experiences.

Can I also suggest that any future DAC related tutorials include a series current limiting resistor - I was not using one, but if the issue was one my side it might have same my DAC0.

Duane B

rcarduino.blogspot.com
« Last Edit: January 02, 2013, 02:54:01 pm by DuaneB » Logged


St. Petersburg, FL
Offline Offline
Jr. Member
**
Karma: 1
Posts: 61
Retired physicist
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The LMxxx amps have an input bias voltage. If the impedance of this voltage source is low enough, it could feed back into the DAC and damage it's output driver. I've measured the LM383 and find 0.6V. There should be at least a series coupling capacitor. Also, a current limiting resistor would certainly be appropriate for testing purposes.
Logged

0
Offline Offline
Full Member
***
Karma: 2
Posts: 109
ArduiYES!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,

if the DAC seems to have given up the ghost,
could you please try this simple test sketch ?

I was messing with the Simple Audio Player too, and did not get any signal from the dac. might have been me,
but just maybe there is a problem in the simple audio player code, instead of a hardware failure..

this sketch outputs a ramp on both dac channels forever. if you have no oscilloscope, you should see a non-zero voltage (i measured about 2.3 volts) on a multimeter.

Code:
void setup() {
Serial.begin(19200);
Serial.println("program start");
}

void loop() {
  for (int i = 0; i <256; i++) analogWrite(DAC0,i);
  for (int j = 0; j <256; j++) analogWrite(DAC1,j);
}
Logged

Venezuela
Offline Offline
Sr. Member
****
Karma: 12
Posts: 434
Ground.......ground........always ground
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The very first sketch I ran in my DUE was the "Simple Audio Player" and it worked great with a Seeed SD card shield and a 16 ohm RadioShack speaker (made in China). I haven't tried again since then. May be I was lucky. 
Logged

Offline Offline
God Member
*****
Karma: 32
Posts: 506
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

 My DAC0 doesn't work either. I don't think I've ever had it connected to anything though (until now, obviously!) It's one of the early boards where DAC0 is marked as "DAC2", and I've only ever used DAC1, which works fine. Very strange smiley-confuse
Logged


Dubai, UAE
Offline Offline
Edison Member
*
Karma: 21
Posts: 1670
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
   I was using my own DDS Code - http://rcarduino.blogspot.com/2012/12/arduino-due-dds-part-1-sinewaves-and.html - against an LM386 circuit which I have used extensively on UNO's and Mega's. DAC0 is dead, as a quick test I tried DAC1 and its still working, I do not want to use it though until I know why DAC0 has failed.

My board has the DAC outputs labelled DAC1 and DAC0 .

Duane B

rcarduino.blogspot.com

Logged


Offline Offline
Newbie
*
Karma: 0
Posts: 1
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hi,

my DAC0 also died smiley-sad but DAC1 is still working.. why is it the DAC0 only dies and not the DAC1??
is that a hardware failure? or something else?

and what do do now? van this be fixed somehow?

Floris
Logged

Dubai, UAE
Offline Offline
Edison Member
*
Karma: 21
Posts: 1670
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

DAC0 is the one you learn on, DAC1 is the one you then take care of.

Duane B
Logged


Pages: [1] 2   Go Up
Jump to: