VS1053 loads plugin but never records

Writing software for systems that use VLSI Solution's devices as slave codecs to a host microcontroller.
Post Reply
umar.techboy
User
Posts: 3
Joined: Thu 2017-06-01 9:14

VS1053 loads plugin but never records

Post by umar.techboy » Fri 2017-06-16 22:08

I've tested 4 brand new VS1053 modules but have faced the same issue which clearly gives me a hint that it is a problem with my setup, not the VS.

The issue is strange. I can load the recorder plugin successfully. I can begin the recording, save data and play it successfully using all media players under windows. But the problem is that the audio is Plain Silent!! I've tried several quality plugins but had the same result. The only sound is continuous very low intensity Humm and extremely low frequency GRRR every 3-4 seconds for half a second..... this gurr sounds different for each modules.

CLOCKF is 0xC000 coz my crystal is 12.288Mhz
here is the part of code I use to begin recording. (I need the default mic)


sciWrite(VS1053_REG_MODE, VS1053_MODE_SM_ADPCM | VS1053_MODE_SM_SDINEW);
sciWrite(VS1053_SCI_AICTRL0, 1024);
sciWrite(VS1053_SCI_AICTRL1, 1024);
sciWrite(VS1053_SCI_AICTRL2, 0);
sciWrite(VS1053_SCI_AICTRL3, 0);

sciWrite(VS1053_SCI_AIADDR, 0x34);
delay(1);
while (!readyForData());

Another note!!! some other of my modules show the same behavior as I described, others have another strange issue. I can load the plugin successfully, acquire any register correctly which shows that VS is not dead. I can acquire and verify the status reg as well. But these modules don't get a readyForData() after beginning the recording. There is 0 Volt on DREQ pin. These modules used to work a couple of days ago and I'm afraid that the other modules I talked about earlie are also gonna turn into zombie. Also, this second group of modules can't Run any kind of file using the same working codes. The chips seem to be feeding data at normal speeds but output only a shrill kurrrr sound.

This is what I've tried so far but have no change AT ALL.
Reducing SPI wire lengths.
Confirming a noiseless power to the system.
Confirmed 3.3 and 1.8V on the voltage regulators of the modules.
Re-sold the crystals.
Changed the main PCB
Tried different quality plugins.

I've checked in default adafruit codes that while resetting, it sets CLOCKF to 0x6000. Shouldn't this be 0xC000?

User avatar
Panu
VLSI Staff
Posts: 2418
Joined: Tue 2010-06-22 13:43

Re: VS1053 loads plugin but never records

Post by Panu » Sat 2017-06-17 18:47

Hmm.. there may be two independent different issues.

First is the no audio problem - have you checked is the recorder set up to record from the line input or from the mic input?

Second is the indication that the modules start to malfunction... can you confirm what is happening? Are all the grounds together, in all the modules? Can you confirm that you never try to connect GBUF to the ground? Are you sure there are no 5 volt signals anywhere?

Please take a look at the "MCU Howto" and other links below, in my signature in case you notice something.

-Panu
Info: Line In and Line Out, VS1000 User interface, Overlay howto, Latest VSIDE, MCU Howto, Youtube
Panu-Kristian Poiksalo, VLSI Solution Oy

umar.techboy
User
Posts: 3
Joined: Thu 2017-06-01 9:14

Re: VS1053 loads plugin but never records

Post by umar.techboy » Tue 2017-06-20 10:07

is the recorder set up to record from the line input or from the mic input?
Yes, the recorder is setup to mic input with internal gain. As i confirmed earlier, the same Code has once seen to be recording properly.
Are all the grounds together, in all the modules? Can you confirm that you never try to connect GBUF to the ground?
I've checked my circuits and seen that the grounds are together however, I see that GBUF IS CONNECTED to the Gnd. I did it because I thought, intuitively, that the speaker outs were differential and pulling the common to ground won't be a problem.

Surprisingly, I have seen my modules to be playing through the speakers perfectly in this scheme as well. Please note that I've two modules hooked simultaneously, one for recording, one for playing. GBUF on my audio player is short with ground, the Recorder module's GBUF is NOT connected to the ground and the recorder seems to Die MORE OFTEN. (Although I often switch the places of the two modules during debugging, but the GBUF of recorder still remains unconnected from GND coz grounding scheme is in the pcb. As shown in below image.)


I think GBUF to GND also justifies little heating problem of the IC as well, doesn't it?
can you confirm what is happening?
The only thing I've discovered from my last post is that I may have connected my electret mic in wrong polarity. I haven't tested if this solves my problem yet.

Although I've turned 6 of my modules into zombies, still I'm unable to find a particular pattern of the problem occurring. That is why I had to contact this forums (I'm extremely grateful that you replied, coz with all my other components of the product all set to go, I'm stuck with this issue for above a month now.)

I think, I should share my device scheme at this point.

My Arduino Mega requires a continuous In-Stream of digital OGG data of the mic sound while SIMULTANEOUSLY, it requires to play back digital mp3 data. That is why I've connected two of these modules http://www.ebay.com/itm/VS1053-MP3-Modu ... 0645105092 on my SPI bus. These modules have equivalent schematics as the Adafruit VS1053 Shield. The DON'T have any 3.3-5V conversion, not even resistors.
Here is a preview of my wiring. http://imgur.com/a/9Vyhx Image

User avatar
pasi
VLSI Staff
Posts: 1412
Joined: Thu 2010-07-15 16:04

Re: VS1053 loads plugin but never records

Post by pasi » Wed 2017-06-21 11:14

GBUF has short-circuit protection, so although it will stop driving when connected to GND, it is not healthy. The LEFT and RIGHT outputs are biased to 1.2V (or 1.65V), so you should probably have DC block when connected to an amplifier. (See the line out thread.)

Wrong microphone polarity can affect the level considerably. Also check that the LINE bit in SCI_MODE is written to '0'. It is set to '1' by default.

What's the IO voltage of you controller? If it is higher than 3.6V, then the protection diodes of vs10xx will sink current from your IO pins. This would cause the chips to get warm or hot, depending on how much current the IO pins are able to drive. If the current is high enough, the chip can enter latch-up state, which will in effect short-circuit the chip and normal state can only be restored by power-cycling. Failure risk is high.
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

umar.techboy
User
Posts: 3
Joined: Thu 2017-06-01 9:14

Re: VS1053 loads plugin but never records

Post by umar.techboy » Sun 2017-07-16 14:38

OK. that cleared a lot of confusions. But created another question. By now, the only guess I had made for mysteriously dying Chips was GBUG shortage with the ground. . . . From your answer, it seems that GBUG connected to ground cannot damage the IC.

As for as I remember, the output pins from the controller have 1K impedance (AVR default), so for 5V, its 5mA. I don't think it is enough to heat up any of the IC significantly. 2ndly, most of the people are using it as it is without having problems.

Lastly, can you point me to the URL of the line out thread you are talking about? since i disconnected GBUF from the ground, I can't get my LM386 to amplify anything.

User avatar
pasi
VLSI Staff
Posts: 1412
Joined: Thu 2010-07-15 16:04

Re: VS1053 loads plugin but never records

Post by pasi » Mon 2017-07-17 17:28

Headphone/line out/etc. connections: viewtopic.php?f=9&t=69
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

Post Reply

Who is online

Users browsing this forum: No registered users