Skip to content

Master811129/MicroTone

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MicroTone: A high-performance library with super tiny flash usage to create a pulse train without any CPU usage

Installing

The library can be installed manually (by unzipping and copying the files to the desired directory) or using the Arduino Library installer, there is nothing to care about.

Supported Platforms

this library was designed for attiny13A/L and Atmega8/A MCU you can build using Arduino IDE or avr-g++.

Functions

This function initializes the library

MicroTone.begin();

you can also use the begin function to set the prescaler (default = 3)

MicroTone.begin();//1-5


This function creates a pulse train on the OCR0A pin note that the parameter (like any write() function) MUST be an 8-bit value (0-255) lower value gives highier frequency

MicroTone.write(value);


This function stops the pulse train (like noTone() function)

MicroTone.stop();


This function changes the prescaler anytime you want! the given value must be from 1 to 5 for Attiny13 and 1 to 7 for Atmega8

MicroTone.setPrescaler();

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages