Emits asynchroneous tone output.
#include <cgnuino.h>
|
| CgnTone (byte) |
| Consructor. More...
|
|
void | update () |
| Stop the tone when finished determined time length of output. More...
|
|
void | out (uint32_t, uint16_t=440) |
| Starts a tone out from a pin for determined time length. More...
|
|
CgnTone::CgnTone |
( |
byte |
p | ) |
|
- Parameters
-
p | Pin number for digital-out to a piezo buzzer. |
void CgnTone::out |
( |
uint32_t |
l, |
|
|
uint16_t |
f = 440 |
|
) |
| |
- Parameters
-
l | Time length of output in [ms]. |
f | Frequency of tone output in [Hz]. |
- Note
- For a normal usage, this method is intended to be called once inside
loop
function.
The documentation for this class was generated from the following files: