User manual

Table Of Contents
432
mikoC PRO for PIC32
MikroElektronika
while (1) {
if (Button(&PORTB,7,1,1)) // RB7 plays Tone1
Tone1();
while (RB7_bit); // Wait for button to be released
if (Button(&PORTB,6,1,1)) // RB6 plays Tone2
Tone2();
while (RB6_bit); // Wait for button to be released
if (Button(&PORTB,5,1,1)) // RB5 plays Tone3
Tone3();
while (RB5_bit); // Wait for button to be released
if (Button(&PORTB,4,1,1)) // RB4 plays Melody2
Melody2();
while (RB4_bit); // Wait for button to be released
if (Button(&PORTB,3,1,1)) // RB3 plays Melody
Melody();
while (RB4_bit); // Wait for button to be released
}
}
HW Connection
Example of Sound Library