Show Posts
Pages: 1 ... 34 35 [36] 37 38 ... 85
526  Using Arduino / Audio / Re: HELP ME!!! I need some advice for a Piezo-MIDI Arduino project on: June 26, 2013, 11:11:59 pm
What code have you already written?

The steps you describe are bascially correct, except that you need to deal with more than one piezo and you need to make sure that all the piezo's are serviced (so no using delay() anywhere).

Each Piezo has a small circuit associated with it (1 MOhm resistor and a 5.1V zener) to make sure you don't blow up the AVR port. Lots of examples of these if you Google. I assume that your drum kit thing is just a few of these, and I woudld bet they have sample code for processing a piezo on their web site.

Once you have the magnitude of a the hit from analogRead() you need to convert that into a velocity. The drum that is hit determines the type of instrument that you want for that input. The two together will get you your MIDI message parameters, which you output through a serial port.

On the MIDI side you need to make sure that you initialise the right parameters and according to MIDI rules (typically I shut down all the sound, select GM map 0, etc). Remember that you are writing to MIDI channel 10 (or 9 when it is in the MIDI message, as the ports are actually zero based) which is the default percussion channel.

Enough to get you started? As per above, Google is your friend here. This has been done many times before.
527  Using Arduino / Sensors / Re: Water level control on a model live steam boat on: June 24, 2013, 07:14:10 am
What about a mechanical float that is either connected to a water valve or a pot? If the pot is used as the pivit for the float it will give an analog signal depending on the level of the float.
528  Using Arduino / Displays / Re: Degrees symbol on lcd? on: June 22, 2013, 09:08:40 pm
The reply has already been given, which is character 0xdf.

This Wikipedia article has a link to the datasheet for the display that has a map of all the characters http://en.wikipedia.org/wiki/Hitachi_HD44780_LCD_controller.

All of the Hitachi controller LCDs I have seen are the type with the ROM set to the Japanese character set. The characters cannot be changed unless you can change the ROM on the display, which is a factory function and not dependent on the Arduino libraries.

Also has been suggested that you can define your own characters, but this is limited to just 8 (ASCII 0-7) and there are a lot of examples of how to do that on the forum and just using Google.
529  Using Arduino / Programming Questions / Re: Countdown on: June 22, 2013, 06:15:38 pm
I did a countdown timer with a 7 segment display and pot for a setpoint as an exercise some time ago. The code can be found in the code repository in my signature below. You may be able to use parts of that code to do what you need.

I agree with the others. If you need to use a goto you should probably look at restructuring your code so that you don't need it. It makes the code hard to follow and maintain.
530  Using Arduino / Audio / Re: MIDI Reset on: June 22, 2013, 06:09:23 pm
Try reading this http://www.music-software-development.com/midi-tutorial.html

Quoting from the relevant bit in section 9:
Quote
1 - Using MIDI controller 123
If you send a MIDI controller 123 on one MIDI channel, the synthesizer will stop all notes playing on that channel. To reset all MIDI channels, send that message for each channel. Please note that some synthesizer do not respond to this message.

2 -MIDI Reset message
This is a one status byte message 0xFF, without data bytes. It should reset the synthesizer to its power-on default, so it also stops all notes playing. Use this message sparingly, as it reset the full synthesizer, not only the notes playing.

3 - MIDI NOTE OFF
You can also send, for each channel (0 to 15) and each note pitch (0 to 127) one MIDI NOTE OFF message. This is the total solution, but requires a lot of MIDI messages to be sent, which may have some reaction time according to the MIDI hardware system you use.

4 - MIDI NOTE OFF - Optimized
In this case, use a table to keep track of the NOTE ON and OFF messages you send for each channel. A buffer of 128 bytes for each channel, representing the number of NOTE ON messages sent to that note, should be incremented by a NOTE ON and decremented by a NOTE OFF. Then, when you want to reset every note, simply go through that table and send a NOTE OFF to each note that is still playing.
531  Using Arduino / Audio / Re: Arduino library for WTV020-SD-16P audio module on: June 15, 2013, 12:59:51 am
Hi the-rebel-agent,

Thanks for your library. Got my unit up and running in less that 30 minutes (most of it getting the wiring right!).

I had an old 64Mb(!) micro SD card that works fine and will probably be enough for what I want to do (voice for a robot).

532  Community / Exhibition / Gallery / Re: Scrolling LED matrix display - Parola for Arduino on: June 14, 2013, 09:13:51 pm
The web site has been updated with an additional PDF file documenting the hardware BoM, component sources, and assembly of the PCB.
https://parola.codeplex.com
533  Using Arduino / Programming Questions / Re: what does #endif //ECHO_TO_SERIAL do in this code on: June 13, 2013, 08:55:04 pm
Strictly speaking it is not necessary. However, if you set the #define to 0, it has no effect on your code size as it is not compiled. If you ever need to debug the program you can turn it on again.

Having said that, there are probably better ways to do this that create less visual pollution in the code.
534  Using Arduino / Sensors / Re: Testing Color sensor on: June 13, 2013, 08:43:25 pm
I have a library that works well for these types of sensors in my code repository (link below in my signature).
535  Community / Exhibition / Gallery / Re: Scrolling LED matrix display - Parola for Arduino on: June 10, 2013, 04:48:55 pm
The section of the video showing 'Scrolling' has 12 units daisy chained and working together. That's all the boards I have made up to date. At this stage I don't expect to be building up the remaining 8 spare PCB (I had 2 lots of 10 made up), but I can't see any issues arising from having more of the units connected. Any specific reason you see 10 as a limit?

I get my 8x8 matrices from eBay. The last lot I bought were from http://www.ebay.com.au/itm/230754163950?ssPageName=STRK:MEWNX:IT&_trksid=p3984.m1439.l2649.

The controller chips come from Tayda Electronics http://www.taydaelectronics.com. They are about $1.25 each, so are probably not 'genuine' but seem to work perfectly well. Here is an interesting article about that http://tronixstuff.wordpress.com/2013/05/16/the-max7219-led-display-controller-real-or-fake/. I also get my passive components from Tayda.

536  Community / Exhibition / Gallery / Re: Scrolling LED matrix display - Parola for Arduino on: June 09, 2013, 11:41:39 pm
Quote
If one set of female headers is replaced with female right angle headers,
http://www.karlssonrobotics.com/cart/6-pin-right-angle-female-header/?gclid=CLyetIbV2LcCFYyY4Aodsj8AWQ
then adjacent boards can be plugged together.

No doubt, but then with the joined units you have the matrix, the IC and then the next matrix. The matrices do not butt up against each other so, unless I am missing something, you can't build a continuous display (ie, matrix next to matrix next to matrix with no gaps).

Edit: for the sake of clarity I am not referring to the SMD units.
537  Community / Exhibition / Gallery / Re: Scrolling LED matrix display - Parola for Arduino on: June 09, 2013, 10:39:21 pm
I did buy one of those larger units on eBay, as I started out wanting to use these 'off the shelf' type - they are pretty cheap. The problem (for me at least) is that the connections do not allow them to be joined up without cables. My design is similar but has connectors on the edges so the modules can be just plugged together.

The SMD units are more like where I would like to be at, but they are too expensive for my budget.

538  Community / Exhibition / Gallery / Re: Scrolling LED matrix display - Parola for Arduino on: June 09, 2013, 08:59:21 pm
Thanks Pedro. I am sure that it could do a lot more but I have run out of interest at the moment and want to move on to something else. Maybe if others write effects they can be built into a future release ...

Documentation is included with the library in the docs folder as an html file.

Boards are not 'for sale' as such, but it is easy enough to use the SeedStudio files to have some made. It is actually quite cheap (about AUS$15 delivered to Australia) for 10 boards, so if you have not tried doing this before, give it a go. Takes about 2 weeks from order to postman delivering.
539  Community / Exhibition / Gallery / Re: Scrolling LED matrix display - Parola for Arduino on: June 09, 2013, 01:27:06 am
Thanks. I started with the DX/eBay modules as well but they have the connector on the wrong edge so I designed my own.
540  Using Arduino / LEDs and Multiplexing / Text display project completed on: June 08, 2013, 11:42:30 pm
If you are a regular on this forum you may be interested in my latest project which is a modular scrolling text display using MAX7219/21 LED matrix display controllers. The display is made up of any number of identical modules that are plugged together to create a wider/longer display.

Main post is at http://forum.arduino.cc/index.php?topic=171056.0
Pages: 1 ... 34 35 [36] 37 38 ... 85