yes, I'm using a level shifter.
I followed the second circuit. Resistor values are 4k7 and 10k.
If I supply my level shifter with 5 volts, the drop across 10k with respect to ground is around 3.37 to 3.4 volts.
This means that my level shifter is OK.
If I turn on my crapduino, what voltage should I read from the SPI pins?
Can you take a picture of your setup and post it here?
Are you using an SD Card or a Micro SD Card in an adaptor?
What's the error code thrown out by the BareMininumWithDebug example, error code: 1 or error code: 08?
if it is error code 1, if your not using a shield, check your connections and contacts with the SD-Card pins. if it is error code 8, try level shifting using 1.8k and 3.3k resistor.
I recently had a problem with my setup above using CD4050. So i ditched that setup and use resistor divider with above values. I am using a micro-sd on an adaptor.
also if no error code and it is saying in the serial monitor "Initialising SD card...Wiring is correct and a card is present....... playing EXAMPLE.AFM.found.playing" lean-in, or put the speaker, closer to your ear, the audio volume is quite low. that it can be unnoticeable when your in a noisy environment.
and my *duino is even more crappier than yours XD XD and it's from five years ago...
Hi, it seems that is still something wrong, either with wiring or something else.
Regarding post 145: If you build your voltage dividers correctly and assuming that you are not driving MISO as output you should not measure more than 3.3 - 3.6v anywhere on the SD card.
Please also check:
You use a SD or SDHC card, but not SDXC. Old MMC cards may work - not tested.
You use Arduino IDE 1.0 or up to 1.0.3, but not 1.5 (the beta version only for Due)
If you use a ATmega328 based Arduino, even a clone, you should use an unpatched Arduino IDE and program the Arduino using one of the boards-setting that came already with the standard IDE.
If all is ok, check if your Arduino is still working on all ports used by the SD card. Set ports to output and high and you should measure 3.3v at appropriate SD pins.
I have some SD cards that just won't initialise in my card reader. I have two cards exactly the same, 2gb and same make and model, and only one will work with the reader. Both work in the pc. I also have some microSD that won't work either, where others do.
Hi,
it is not foreseen yet to change the pitch yet, at least not in fine amounts. You can select between half or full-rate, but that's all. If you want to change the playback speed in finer amounts, it is not possible with that library yet and you wont get usable result just by changing the timer rate because the timer already runs at relatively high speed allowing only massive pitch changes.
The easiest way to do such things might be to prepare multiple files on the card each with a different pitch and play those. You can do this using an audio editor like Audacity to prepare such files.
If you really want to go the hard way it should be possible to modify the library to support different playback rates - at least two options came in mind for me, changing the playback-interrupt function or the worker-function. The worker-function is written in plain C and should be easier to modify but with rate-changing it would not be longer operating at sector boundaries. In the playback function rate changing only have influence over buffer empty speed but it is harder to understand as it is written in Asm. The algorithm I would prefer is a phase-accumulator that decides if and how many samples are skipped or repeated for every target sample...
Thank you tuttut for the reply.
OK, I take the easy way you have mentioned.
One more question. I need to play a 5sec audio as a seamless loop:indefinitely .Though I am able to accomplish that with the "Bare minimum" you have provided,there occurs an audio glitch at the end-to-beginning of the file played. The file has perfect zero-crossing at the beginning and in the end.Could you please suggest anything to avoid this problem.
(My gadget: Ardiuno Atmega 328+LC studio SDcard breakout board).
Thank you again.
Hi,
Sorry, that patch did not work.
Result : Audio file not played.Instead, there were lot of glitches-only glitches.I have noticed that the glitches came out as a stream (loudest at the start and diminished along the time line and died in few seconds).But that was from "Bare minimum" sketch.
When I tried the " Bare minimum with Debug", it gave a continuous tone of 125 hz approx.(No audio file content played).
But, sketch examples with worker (bare minimum with worker,bare minimum with worker with debug),worked normally,of course with the glitch.
Could you please explain what exactly the patch modifies.
Anyway, thank you for trying to help me.