So I have an Arduino Uno set up with a wave shield working just great right now. It's triggered by a glove with 4 buttons on the finger tips to play different sounds. I would also like to integrate an accelerometer without getting rid of the glove option. Are there enough inputs on the wave shield to use both? It took me a while but I finally figured out how the digital ins work on the right side (with power and USB facing down), bu I see there are other possible pins on the left side, but I'm not sure if they are capable to be used as inputs or not. Is there a schematic of what goes where for the PCB? Also, It's been over a year since I put this all together so my understanding of the whole process is a bit fuzzy if my explanation doesn't make sense.

Is your reply missing a link? I actually have http://www.adafruit.com/products/163 sitting in front of me right now while I try and figure out how to incorporate it. I don't want to solder anything to it until I understand how it needs to be integrated. I currently have digital ins (numbered I dont recall...) soldered to a cable wit ha 6 pin phone adapter on the end, and then my glove clicks into that. I could probably pretty easily wire a similar connector on the end of the accelerometer, but then it would replace the glove, and I'd rather use both at the same time.

The microphone requires one analog input pin. The voice changer code relies on the ADC 'free run' mode, which means no other analog inputs are available (but the pins can still be used for digital I/O), so an analog accelerometer won't work in this case, you'll need an I2C variety such as either of these:

I2C devices have to go on pins A4 and A5. This still leaves three pins on the analog side (though as mentioned above, only usable for digital input when voice-changing), and a few pins on the digital side...I think 6, 7, 8 and 9 are all available. So yeah, that's seven available pins, even with the mic and accelerometer on there.

So, it looks like you've got the wave shield jumpered according to the tutorial. That leaves D0, D1, D6, D7, D8, and D9 available. A0 thru A5 can be used either for analog input or for digital I/O.

The PID 1231 accelerometer will take A4 and A5. The microphone will take any one of A0 thru A3. That leaves you with 3 pins on the analog side and 6 pins on the digital side which you can use for your glove and whatever else you might want to add.

Thanks so much for the comments. So it's gonna take me a few minutes to translate what you guys are saying into "I have very little electronics experience, and I just BARELY managed to get this thing working in the first place" english. But to make sure I at least get the gist:

Using the microphone will disable all analog inputs, correct? But I can still use digital inputs for buttons, but NOT an accelerometer?The accelerometer I have is different than the ones you linked?Can I get a caveman explanation of I2C? It converts a multiple cable requirement down to just 2??There are digital inputs 0-13 on the left, and Analog inputs 0-5 on the right (or top and bottom I guess how you read them...)? Can I call any of these in a sketch? What are the differences?

You mentioned my board is "jumpered" like in the tutorial? What is the reason for that? I kind of just blindly followed along, and crossed my fingers it would work. But now that I'm thinking of adding more functionality, I'm thinking it might be better to remove all the soldered in wires and solder pin headers to all of the inputs instead. Am I correct in that line of thinking? Also, I kind of destroyed the connecter on A4 when soldering (my first soldering job....) Does that preclude me from ever using any IC2 items?

So I found this FAQ (http://www.ladyada.net/make/waveshield/faq.html), which is saying many of the pins are used for the SD card. Is that what the jumpers are for? Meaning I DONT want to undo those, correct? And even though pins 13,12, and 11 are open, they are technically in use by the library?

keeleon wrote:Using the microphone will disable all analog inputs, correct?

No. The voice-changer sketch requires continuous use of the microphone's analog input, meaning that you can't perform analog reads on the other inputs. If you are not running that sketch, you can use the other analog inputs along with the microphone.Even if you are running the voice-changer, you an still use the other "analog" pins as digital pins.

But I can still use digital inputs for buttons, but NOT an accelerometer?

The accelerometer you already have has analog outputs. So you can't use that and the voice-changer at the same time. You can't connect your analog accelerometer to digital inputs.

The accelerometer I have is different than the ones you linked?

Yes. The ones we linked have digital outputs, not analog outputs.

Can I get a caveman explanation of I2C? It converts a multiple cable requirement down to just 2??

I2C is a digital data communications protocol which allows multiple devices to share two wires. No two devices use the wires at the same time. The arduino acts as the 'master'. The other devices speak only when spoken to. One wire streams digital data, and the other wire carries a data clock.

There are digital inputs 0-13 on the left, and Analog inputs 0-5 on the right (or top and bottom I guess how you read them...)? Can I call any of these in a sketch? What are the differences?

Yes - you can use any of them in a sketch. ALL of them are digital input and output. The ones marked 'analog' can perform analog input in addition to digital input and output.

You mentioned my board is "jumpered" like in the tutorial? What is the reason for that?

The jumper wires connect the Digital/Analog Converter (DAC - the thing that converts your wav files to sound) to the header pins. You could connect the jumper wires to any free digital pin, but just about everybody does it just like in the tutorial. Without the jumper wires, there's no way for the arduino to communicate with the DAC.

But now that I'm thinking of adding more functionality, I'm thinking it might be better to remove all the soldered in wires and solder pin headers to all of the inputs instead. Am I correct in that line of thinking?

Not really. There's no particularly good reason to do that.

Also, I kind of destroyed the connecter on A4 when soldering (my first soldering job....) Does that preclude me from ever using any IC2 items?

You destroyed it on the wave shield or on the arduino? If it's still OK on the arduino, then you can simply connect to it there.

keeleon wrote:So I found this FAQ (http://www.ladyada.net/make/waveshield/faq.html), which is saying many of the pins are used for the SD card. Is that what the jumpers are for? Meaning I DONT want to undo those, correct? And even though pins 13,12, and 11 are open, they are technically in use by the library?

I2C is a digital data communications protocol which allows multiple devices to share two wires. No two devices use the wires at the same time. The arduino acts as the 'master'. The other devices speak only when spoken to. One wire streams digital data, and the other wire carries a data clock.

This is similar to how data transfers over ethernet (TCP/IP), correct? It sends the data as a packet along with an identifier as to what to do with it?

But now that I'm thinking of adding more functionality, I'm thinking it might be better to remove all the soldered in wires and solder pin headers to all of the inputs instead. Am I correct in that line of thinking?

Not really. There's no particularly good reason to do that.

I am trying to use my one Arduino Uno and Wave shield for multiple projects that seem to require different pin configurations. I was thinking if I just soldered a female pin header to all of the inputs, then I could just make plugs out of the things I wanted to attach (buttons, accelerometer, microphone) thus making it more modular so I didn't have to unsolder things every time I changed the project. Is there a better connector to do it this way? How I have it now with the phone connector seems to work fine, but I wanted something maybe a little cleaner and more "adaptable" if that makes sense.

You destroyed it on the wave shield or on the arduino? If it's still OK on the arduino, then you can simply connect to it there.

On the wave shield. I actually have it soldered to the top of the header going down to the arduino, which I assume is still correct.

keeleon wrote:This is similar to how data transfers over ethernet (TCP/IP), correct? It sends the data as a packet along with an identifier as to what to do with it?

Wellll...technically, I2C is almost exactly nothing like ethernet. But, it's not a bad way to think about it - everybody shares the same wire, and the whole mess gets straightened out because everybody has a unique address and they're only allowed to talk one at a time.

There are a few different ways you can approach the problem of multiple projects. You could get some prototyping shields, and dedicate one to each different project. You could also go cheap with a few DIY Shield kits.

If your projects mostly just involve wires, you might be able to use a Wingshield instead, which has screw terminals that make it easy to attach wires.

I'm thinking that the Patch Shield might be just the ticket for you. You plug stuff into it via standard RJ-45 cables.

You can stack any of those shields with your wave shield by using stacking headers instead of regular pin headers.

Wellll...technically, I2C is almost exactly nothing like ethernet. But, it's not a bad way to think about it - everybody shares the same wire, and the whole mess gets straightened out because everybody has a unique address and they're only allowed to talk one at a time.

I do get that they aren't really alike, I just like to use metaphors and similes to verify what I am trying to understand against what I don't understand. And actually I should have said fiber optic cable as opposed to ethernet, since it is a 2 strand system that can send data from hundreds of different sources who can only talk one at a time.

Not like money is a huge concern, but considering I'm already salivating waiting for my order to show up in like 2 days to start working on this project, it'll kill me to have to order something else and wait even longer. >.<

Stacking headers are exactly what I was thinking of, I just didn't know the name. Unfortunately, the generic proto shield I bought at radio shack yesterday didn't come with any stacking headers, although I think I can make my own using what I have. However, I will then run into an issue of height. The main use for this project is a sound system for my Predator costume, and the Arduino sits inside my gauntlet. I don't think it will fit if it get's any higher. :(

So my new thinking is to stick with the directly soldered phone plug and replace it with an ethernet cable to get more wires out. And then I think, to do this on the other side with the digital pins. So I guess my new question is what all would be important to have in a single line on either side?

Currently I have wired out are:A0A1A2A3A4A5GNDto one cable (I'm not sure how I wired 7 lines into a 6 pin connector, but it has been working, so I'm not going to question it...)

And I plan on doing the same thing on the other side with:D0D1D6D7D8D9GNDto a seperate cable.

I will then connect the glove to the digital pin cable, and run the mic up to my mouth with the analog cable. Is there anything else I should run out to the cable? Most of the scripts I have seen for verifying buttons only require a connection to ground. Would it be a good idea to wire in 3v or 5v along with it? What is VIN? I understand there is no "correct" way to do this, because it all depends on how I code it, but I want to pull as many options away from the board as possible using the tools I have. and I am a much better ethernet crimper than I am a solderer.

And then in the voice changing tutorial it says to connect AREF to 3.3v. I tried looking that up, and it seems like it has to have a reference to 3.3v to be functional. Is there a reason it isn't connected that way on the PCB? Do I basically just solder a jumper cable from that pin to the 3v pin?

And then another mostly unrelated question, but based on the same project and picture, if I'm using a separate power source for the amplifier, do I need to run it through the microphone as well, or can't I just power it on it's own and plug it into the audio out jacks of the wave board. Does it not supply it's own ground, or does wiring that into the same ground remove noise?

And then in the voice changing tutorial it says to connect AREF to 3.3v. I tried looking that up, and it seems like it has to have a reference to 3.3v to be functional. Is there a reason it isn't connected that way on the PCB?

Ok, I did find a tutorial (http://tronixstuff.wordpress.com/2010/12/07/tutorial-arduino-and-the-aref-pin/) on AREF that I think cleared it up a bit, bu let me make sure I understand it. It's not hardwired because you can set it to whatever reference voltage you want? and it's defaulted to 5v? The reason I am referencing 3v, is to make my steps smaller, and to be more accurate in reading the microphone?

The microprocessor provides internal reference voltages of either 1.1V or Vcc (5V on a Uno). Providing a reference voltage through AREF is strictly optional.

The microphone can run on 2.4V - 5V, and you match AREF to the supply voltage. We recommend using the 3.3V source on the arduino because it is the 'quietest'. That is, for analog measurements, the 5V supply is not quite as stable a reference as the 3.3V.

Regarding the grounding, I don't think you'll need a common ground between the audio amplifier and the arduino.