Go Down

Topic: Piezo transducer and Arduino (Read 760 times) previous topic - next topic

Urianium

Aug 09, 2012, 10:48 am Last Edit: Aug 10, 2012, 04:38 am by Urianium Reason: 1
Hey guys,

I am new to Arduino, however I am pretty familiar with programing.

I have Arduino Mega and I would like to control piezo disc using my Arduino board. My question is what's the best way to do it? What's the switching frequency between LOW and HIGH levels I can get with Arduino?

Cheers,
B.

Chagrin

Make sure you see the Tone reference: http://arduino.cc/en/Reference/Tone

I'm unsure what the maximum frequency would be but it'd be well out of audible range or the capability of the piezo.

Urianium

I am looking into frequencies from 1MHz up to 5MHz, is it possible to switch between low and high state that fast?

Magician


Urianium

Thanks Magician,

Maybe 4 MHz will be good enough for my application, can I get it with tone? Or do I have to use different command?


Magician

#5
Aug 22, 2012, 02:30 pm Last Edit: Aug 22, 2012, 02:39 pm by Magician Reason: 1
No Tone, direct setting Timer control registers. I'd not advise you to read data sheet of atmega cpu here, you wouldn't find clear technical specification no real practical examples, but you could use it for reference.
Good book will help you to start:


<a href="http://www.amazon.com/gp/product/1430238828/ref=as_li_tf_tl?ie=UTF8&camp=1789&creative=9325&creativeASIN=1430238828&linkCode=as2&tag=ffanar-20">Arduino Internals</a><img src="http://www.assoc-amazon.com/e/ir?t=ffanar-20&l=as2&o=1&a=1430238828" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" />

Go Up