Pages: [1] 2   Go Down
Author Topic: really need help!!  (Read 644 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i have seen this project and would like to make it as well. however, i am new to arduino and cant seem to tell what pins to connect my piezos too neither the sensor for the hi hat pedal.

here is the project:
http://blog.georgmill.de

if anyone can help then it would be really really appreciated.
the code is:

http://sourceforge.net/projects/yaamidrum/

please if anyone can help me get a working schematic i would be eternally grateful.

many thanks

marc
Logged

Croatia
Offline Offline
Sr. Member
****
Karma: 11
Posts: 432
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Wouldn't that be obvious from the code?
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

how so? this project uses the a Mux shield and that has a lot of inputs but as still new im not sure how to locate them.

any input??

thanks

marc
Logged

Croatia
Offline Offline
Sr. Member
****
Karma: 11
Posts: 432
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Just as a simple button needs a pin defined for an input, so does any other sensor. Look at the top of the code to find out which ones.
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

but doesnt it differ with multiplexers???
Logged

Croatia
Offline Offline
Sr. Member
****
Karma: 11
Posts: 432
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Then the code will tell you which pins the multiplexers are connected to.
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i still dont see how it does, i am still very new so please ignore my lack of knowledge, would you mind taking a look and seeing if you could help??

many thanks
marc
Logged

Offline Offline
God Member
*****
Karma: 27
Posts: 829
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It doesn't really matter what inputs you connect them to. The code just scans all of them anyway. You connect the channels to instruments in your MIDI software on the computer.

A piezo generates electricity when pressure is applied to it, so you would connect one end to gnd on the shield and the other end into an input.

I can't promise that would work, because normally you would want a preamp on a piezo to condition the signal (the voltage output is likely in microvolts), but he didn't give any indication in his project that he was doing that.
Logged

Offline Offline
God Member
*****
Karma: 27
Posts: 829
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Something like this. If your piezo does output millivolts, then you can probably just read it directly with the arduino.

http://itp.nyu.edu/physcomp/sensors/Schematics/LM358OpAmp
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

so effectively i could just connect them all up and put them in ascending order???
Logged

Offline Offline
God Member
*****
Karma: 27
Posts: 829
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

However you want. You map them in your midi software. Ascending order makes sense so that you can know what channel is what when you set up the software.
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

so effectively the MUX shield is just looking for any kind of input voltage from the piezo and connecting them to any of the pins means that they would get read ???

Logged

Offline Offline
God Member
*****
Karma: 27
Posts: 829
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes. The code you linked to just scans all of the multiplexed channels and dumps them all to the computer as MIDI channel data. So, in your MIDI software you map the channels that you have populated to instruments. It looks like it reads 48 inputs on the mux shield and 4 from the rest of the analog input pins (A1-A5.) So 52 MIDI channels are sent.

To keep things logical, start with channel 1 when you hook them up so you know which channels are connected when you go to map them.
Logged

Offline Offline
Jr. Member
**
Karma: 0
Posts: 62
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

any idea what the A0 is being used for from looking at the code??
Logged

Offline Offline
God Member
*****
Karma: 27
Posts: 829
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

A0 is the analog pin that all those 48 pins on the muxshield are being sent to. So, the mux shield works by addressing a channel (one of the 48 inputs.) This connects that input to A0.
Logged

Pages: [1] 2   Go Up
Jump to: