Member #141822

If you’re looking for a quicker response when starting an mp3 increase the internal clock multiplier from 3 to 5 and decrease SPI clock divider to SPI_CLOCK_DIV2. Do so with the following changes to the example code:

Using the original MP3 Player Example Code I decided to create my own library for playing MP3s with this shield. I know I could use the library discussed below, but I consider it a learning experience to do it myself :) Anyway I’m having problems with declaring SD information like Sd2Card and SdFile in my MP3Player class. I get errors like Sd2Card is not valid type, SdVolume is not valid type, and same thing for SdFile. I’ve attached a very abbreviated header file below. I can’t make any sense out of this. Seems solid from C++ standpoint. I also have this library in the correct locations which is in …\libraries\MP3Player. Any help would be appreciated. Thanks.

MP3Player.h

ifndef MP3PLAYER_H

define MP3PLAYER_H

include

include

include

endif

I’m trying to gather data from four different accelerometers and use them to play back sound. So far works great using the MP3 Player shield and one accelerometer, but no idea how to gather data from all four. I can jump the SA0 pin and do it that way, but that only get me 2 accelerometers and not four. They essentially work in groups of two. 2 for arms, 2 for legs. I just wanted to register when the legs move or arms move(not which one). Is there any way to combine the results from 2 accelerometers with the same address?

1) How/where do I complete the jumper to the SA0 pin. I plan on using four of these, in 2 groups.

2) What can I do to monitor two separate accelerometers with the same address. I need a way to combine them so I can tell when one is accelerating. Doesn’t matter whether one is moving or both, just need to identify motion.

It would seem that you can do that however in the code you cannot remove:
1) Defining Pin PD
2) Declaring Pin PD as an Output
I do not know why, but you still save 4 pins which was very helpful. Thanks.

Is there anyway to accomplish this without the while loop? The reason I ask is I want to continue reading the sensors while the SFX plays. If a sensor comes back as active I want to add it to a queue to be played next. I tried creating a global boolean Playing variable which would contain the code to play the song. It doesn’t work though as it seems the global boolean value I created constantly resets itself.

SparkFun is an online retail store that sells the bits and pieces to
make your electronics projects possible. Whether it's a robot that can
cook your breakfast or a GPS cat tracking device, our products and
resources are designed to make the world of electronics more accessible.

In addition to products, SparkFun also offers
classes and online tutorials to help educate
individuals in the wonderful world of embedded electronics.