It's not my library, i just want to publish my program.

Fork of PWM_Tone_Library by justin kim

Committer:
Lapita
Date:
Fri Mar 31 14:51:06 2017 +0000
Revision:
3:b3ee09f3ff8f
Parent:
0:d06af372d384
recepcion de datos del iphone, and buzzer activado desactivado

Who changed what in which revision?

UserRevisionLine numberNew contents of line
justinkim 0:d06af372d384 1 /* Includes ------------------------------------------------------------------*/
justinkim 0:d06af372d384 2 #include "mbed.h"
justinkim 0:d06af372d384 3
justinkim 0:d06af372d384 4 /* Private typedef -----------------------------------------------------------*/
justinkim 0:d06af372d384 5 /* Private define ------------------------------------------------------------*/
justinkim 0:d06af372d384 6 #define Do3 131 //C octave3
justinkim 0:d06af372d384 7 #define Do3s 139 //C#
justinkim 0:d06af372d384 8 #define Re3 147 //D
justinkim 0:d06af372d384 9 #define Re3s 156//D#
justinkim 0:d06af372d384 10 #define Mi3 165 //E
justinkim 0:d06af372d384 11 #define Fa3 175 //F
justinkim 0:d06af372d384 12 #define Fa3s 185 //F#
justinkim 0:d06af372d384 13 #define So3 196 //G
justinkim 0:d06af372d384 14 #define So3s 208 //G#
justinkim 0:d06af372d384 15 #define La3 220 //A
justinkim 0:d06af372d384 16 #define La3s 233 //A#
justinkim 0:d06af372d384 17 #define Ti3 247 //B
justinkim 0:d06af372d384 18 #define Do4 262 //C octave4
justinkim 0:d06af372d384 19 #define Do4s 277 //C#
justinkim 0:d06af372d384 20 #define Re4 294 //D
justinkim 0:d06af372d384 21 #define Re4s 311//D#
justinkim 0:d06af372d384 22 #define Mi4 330 //E
justinkim 0:d06af372d384 23 #define Fa4 349 //F
justinkim 0:d06af372d384 24 #define Fa4s 370 //F#
justinkim 0:d06af372d384 25 #define So4 392 //G
justinkim 0:d06af372d384 26 #define So4s 415 //G#
justinkim 0:d06af372d384 27 #define La4 440 //A
justinkim 0:d06af372d384 28 #define La4s 466 //A#
justinkim 0:d06af372d384 29 #define Ti4 494 //B
justinkim 0:d06af372d384 30 #define Do5 523 //C octave5
justinkim 0:d06af372d384 31 #define Do5s 554 //C#
justinkim 0:d06af372d384 32 #define Re5 587 //D
justinkim 0:d06af372d384 33 #define Re5s 622//D#
justinkim 0:d06af372d384 34 #define Mi5 659 //E
justinkim 0:d06af372d384 35 #define Fa5 699 //F
justinkim 0:d06af372d384 36 #define Fa5s 740 //F#
justinkim 0:d06af372d384 37 #define So5 784 //G
justinkim 0:d06af372d384 38 #define So5s 831 //G#
justinkim 0:d06af372d384 39 #define La5 880 //A
justinkim 0:d06af372d384 40 #define La5s 932 //A#
justinkim 0:d06af372d384 41 #define Ti5 988 //B
justinkim 0:d06af372d384 42
Lapita 3:b3ee09f3ff8f 43
Lapita 3:b3ee09f3ff8f 44
Lapita 3:b3ee09f3ff8f 45 #define NOTE_B0 31
Lapita 3:b3ee09f3ff8f 46 #define NOTE_C1 33
Lapita 3:b3ee09f3ff8f 47 #define NOTE_CS1 35
Lapita 3:b3ee09f3ff8f 48 #define NOTE_D1 37
Lapita 3:b3ee09f3ff8f 49 #define NOTE_DS1 39
Lapita 3:b3ee09f3ff8f 50 #define NOTE_E1 41
Lapita 3:b3ee09f3ff8f 51 #define NOTE_F1 44
Lapita 3:b3ee09f3ff8f 52 #define NOTE_FS1 46
Lapita 3:b3ee09f3ff8f 53 #define NOTE_GS1 52
Lapita 3:b3ee09f3ff8f 54 #define NOTE_A1 55
Lapita 3:b3ee09f3ff8f 55 #define NOTE_AS1 58
Lapita 3:b3ee09f3ff8f 56 #define NOTE_B1 62
Lapita 3:b3ee09f3ff8f 57 #define NOTE_C2 65
Lapita 3:b3ee09f3ff8f 58 #define NOTE_CS2 69
Lapita 3:b3ee09f3ff8f 59 #define NOTE_D2 73
Lapita 3:b3ee09f3ff8f 60 #define NOTE_DS2 78
Lapita 3:b3ee09f3ff8f 61 #define NOTE_E2 82
Lapita 3:b3ee09f3ff8f 62 #define NOTE_F2 87
Lapita 3:b3ee09f3ff8f 63 #define NOTE_FS2 93
Lapita 3:b3ee09f3ff8f 64 #define NOTE_G2 98
Lapita 3:b3ee09f3ff8f 65 #define NOTE_GS2 104
Lapita 3:b3ee09f3ff8f 66 #define NOTE_A2 110
Lapita 3:b3ee09f3ff8f 67 #define NOTE_AS2 117
Lapita 3:b3ee09f3ff8f 68 #define NOTE_B2 123
Lapita 3:b3ee09f3ff8f 69 #define NOTE_C3 131
Lapita 3:b3ee09f3ff8f 70 #define NOTE_CS3 139
Lapita 3:b3ee09f3ff8f 71 #define NOTE_D3 147
Lapita 3:b3ee09f3ff8f 72 #define NOTE_DS3 156
Lapita 3:b3ee09f3ff8f 73 #define NOTE_E3 165
Lapita 3:b3ee09f3ff8f 74 #define NOTE_F3 175
Lapita 3:b3ee09f3ff8f 75 #define NOTE_FS3 185
Lapita 3:b3ee09f3ff8f 76 #define NOTE_G3 196
Lapita 3:b3ee09f3ff8f 77 #define NOTE_GS3 208
Lapita 3:b3ee09f3ff8f 78 #define NOTE_A3 220
Lapita 3:b3ee09f3ff8f 79 #define NOTE_AS3 233
Lapita 3:b3ee09f3ff8f 80 #define NOTE_B3 247
Lapita 3:b3ee09f3ff8f 81 #define NOTE_C4 262
Lapita 3:b3ee09f3ff8f 82 #define NOTE_CS4 277
Lapita 3:b3ee09f3ff8f 83 #define NOTE_D4 294
Lapita 3:b3ee09f3ff8f 84 #define NOTE_DS4 311
Lapita 3:b3ee09f3ff8f 85 #define NOTE_E4 330
Lapita 3:b3ee09f3ff8f 86 #define NOTE_F4 349
Lapita 3:b3ee09f3ff8f 87 #define NOTE_FS4 370
Lapita 3:b3ee09f3ff8f 88 #define NOTE_G4 392
Lapita 3:b3ee09f3ff8f 89 #define NOTE_GS4 415
Lapita 3:b3ee09f3ff8f 90 #define NOTE_A4 440
Lapita 3:b3ee09f3ff8f 91 #define NOTE_AS4 466
Lapita 3:b3ee09f3ff8f 92 #define NOTE_B4 494
Lapita 3:b3ee09f3ff8f 93 #define NOTE_C5 523
Lapita 3:b3ee09f3ff8f 94 #define NOTE_CS5 554
Lapita 3:b3ee09f3ff8f 95 #define NOTE_D5 587
Lapita 3:b3ee09f3ff8f 96 #define NOTE_DS5 622
Lapita 3:b3ee09f3ff8f 97 #define NOTE_E5 659
Lapita 3:b3ee09f3ff8f 98 #define NOTE_F5 698
Lapita 3:b3ee09f3ff8f 99 #define NOTE_FS5 740
Lapita 3:b3ee09f3ff8f 100 #define NOTE_G5 784
Lapita 3:b3ee09f3ff8f 101 #define NOTE_GS5 831
Lapita 3:b3ee09f3ff8f 102 #define NOTE_A5 880
Lapita 3:b3ee09f3ff8f 103 #define NOTE_AS5 932
Lapita 3:b3ee09f3ff8f 104 #define NOTE_B5 988
Lapita 3:b3ee09f3ff8f 105 #define NOTE_C6 1047
Lapita 3:b3ee09f3ff8f 106 #define NOTE_CS6 1109
Lapita 3:b3ee09f3ff8f 107 #define NOTE_D6 1175
Lapita 3:b3ee09f3ff8f 108 #define NOTE_DS6 1245
Lapita 3:b3ee09f3ff8f 109 #define NOTE_E6 1319
Lapita 3:b3ee09f3ff8f 110 #define NOTE_F6 1397
Lapita 3:b3ee09f3ff8f 111 #define NOTE_FS6 1480
Lapita 3:b3ee09f3ff8f 112 #define NOTE_G6 1568
Lapita 3:b3ee09f3ff8f 113 #define NOTE_GS6 1661
Lapita 3:b3ee09f3ff8f 114 #define NOTE_A6 1760
Lapita 3:b3ee09f3ff8f 115 #define NOTE_AS6 1865
Lapita 3:b3ee09f3ff8f 116 #define NOTE_B6 1976
Lapita 3:b3ee09f3ff8f 117 #define NOTE_C7 2093
Lapita 3:b3ee09f3ff8f 118 #define NOTE_CS7 2217
Lapita 3:b3ee09f3ff8f 119 #define NOTE_D7 2349
Lapita 3:b3ee09f3ff8f 120 #define NOTE_DS7 2489
Lapita 3:b3ee09f3ff8f 121 #define NOTE_E7 2637
Lapita 3:b3ee09f3ff8f 122 #define NOTE_F7 2794
Lapita 3:b3ee09f3ff8f 123 #define NOTE_FS7 2960
Lapita 3:b3ee09f3ff8f 124 #define NOTE_G7 3136
Lapita 3:b3ee09f3ff8f 125 #define NOTE_GS7 3322
Lapita 3:b3ee09f3ff8f 126 #define NOTE_A7 3520
Lapita 3:b3ee09f3ff8f 127 #define NOTE_AS7 3729
Lapita 3:b3ee09f3ff8f 128 #define NOTE_B7 3951
Lapita 3:b3ee09f3ff8f 129 #define NOTE_C8 4186
Lapita 3:b3ee09f3ff8f 130 #define NOTE_CS8 4435
Lapita 3:b3ee09f3ff8f 131 #define NOTE_D8 4699
Lapita 3:b3ee09f3ff8f 132 #define NOTE_DS8 4978
Lapita 3:b3ee09f3ff8f 133
Lapita 3:b3ee09f3ff8f 134
justinkim 0:d06af372d384 135 /* Private variables ---------------------------------------------------------*/
justinkim 0:d06af372d384 136 /* Private function prototypes -----------------------------------------------*/
justinkim 0:d06af372d384 137 void Tune(PwmOut name, int period, int beat);
justinkim 0:d06af372d384 138 void Auto_tunes(PwmOut name, int period, int beat);
justinkim 0:d06af372d384 139 void Stop_tunes(PwmOut name);
justinkim 0:d06af372d384 140
justinkim 0:d06af372d384 141 /* Private functions ---------------------------------------------------------*/