142#include <avr/pgmspace.h>
149#include <SoftwareSerial.h>
361 SpeakJet(uint8_t txPin = 2, uint8_t resetPin = 3, uint8_t readyPin = 4);
Driver object for SpeakJet chips such as on SparkFun VoiceBox shield https://www.sparkfun....
Definition SpeakJet.h:160
bool init()
Definition SpeakJet.cpp:28
bool speakDigits(const char *digits)
Definition SpeakJet.cpp:133
bool speakWordFromDictionary(const char *word, const DictionaryEntry *dict)
Definition SpeakJet.cpp:87
bool speakNumber(uint32_t n)
Definition SpeakJet.cpp:198
void waitReady()
Definition SpeakJet.cpp:47
bool speakNumber999(uint16_t n)
Definition SpeakJet.cpp:173
bool reset()
Definition SpeakJet.cpp:34
bool speakWordsFromDictionary(char *words, const DictionaryEntry *dict)
Definition SpeakJet.cpp:99
void speakCodes(uint8_t *codes)
Definition SpeakJet.cpp:67
CommandCodes
Definition SpeakJet.h:183
@ Phoneme_KE
55ms Voiceless Stop
Definition SpeakJet.h:279
@ Fast
Next phoneme at 0.5 speed.
Definition SpeakJet.h:191
@ Phoneme_DO
45ms Voiced Stop
Definition SpeakJet.h:260
@ Pause0
Pause 0ms.
Definition SpeakJet.h:184
@ DTMF_9
DTMF 9 95ms.
Definition SpeakJet.h:339
@ Sound_C1
300ms Biological
Definition SpeakJet.h:320
@ EndOfPhrase
End of phrase marker. Required at end of code arrays.
Definition SpeakJet.h:347
@ Phoneme_TH
40ms Voiceless Fricative
Definition SpeakJet.h:275
@ Phoneme_LO
70ms Voiced Resonate
Definition SpeakJet.h:231
@ Phoneme_OWWW
131ms Voiced Diphthong
Definition SpeakJet.h:249
@ Pause5
Pause 60ms.
Definition SpeakJet.h:189
@ Phoneme_DE
45ms Voiced Stop
Definition SpeakJet.h:259
@ Sound_C4
175ms Biological
Definition SpeakJet.h:323
@ Phoneme_IYRR
200ms Voiced R Color Vowel
Definition SpeakJet.h:234
@ Pause1
Pause 100ms.
Definition SpeakJet.h:185
@ Sound_A7
600ms Alarm
Definition SpeakJet.h:304
@ Phoneme_EYRR
200ms Voiced R Color Vowel
Definition SpeakJet.h:235
@ Phoneme_EK
55ms Voiceless Stop
Definition SpeakJet.h:281
@ Phoneme_BO
45ms Voiced Stop
Definition SpeakJet.h:256
@ Phoneme_NO
70ms Voiced Nasal
Definition SpeakJet.h:227
@ Sound_B0
200ms Beep
Definition SpeakJet.h:308
@ Repeat
Next octet is repeat count. 0 to 255.
Definition SpeakJet.h:203
@ Sound_R0
80ms Robot
Definition SpeakJet.h:286
@ Relax
Next phoneme with relaxation.
Definition SpeakJet.h:194
@ Phoneme_AXUW
170ms Voiced Diphthong
Definition SpeakJet.h:246
@ Phoneme_OHIY
200ms Voiced Diphthong
Definition SpeakJet.h:240
@ DTMF_0
DTMF 0 95ms.
Definition SpeakJet.h:330
@ Phoneme_ZH
70ms Voiced Fricative
Definition SpeakJet.h:253
@ Sound_B8
270ms Beep
Definition SpeakJet.h:316
@ Phoneme_OW
70ms Voiced Long Vowel
Definition SpeakJet.h:222
@ DTMF_3
DTMF 3 95ms.
Definition SpeakJet.h:333
@ Sound_A4
530ms Alarm
Definition SpeakJet.h:301
@ Sound_C5
350ms Biological
Definition SpeakJet.h:324
@ Sound_B3
260ms Beep
Definition SpeakJet.h:311
@ Phoneme_GE
55ms Voiced Stop
Definition SpeakJet.h:263
@ Sound_A6
135ms Alarm
Definition SpeakJet.h:303
@ Volume
Next octet is volume 0 to 127. Default 96.
Definition SpeakJet.h:197
@ Phoneme_GO
55ms Voiced Stop
Definition SpeakJet.h:264
@ Sound_M1
Pistol shot 250ms.
Definition SpeakJet.h:344
@ Delay
Next octet is delay in multiples of 10ms. 0 to 255.
Definition SpeakJet.h:206
@ Phoneme_CH
70ms Voiceless Affricate
Definition SpeakJet.h:267
@ Sound_B2
280ms Beep
Definition SpeakJet.h:310
@ Sound_R1
80ms Robot
Definition SpeakJet.h:287
@ DTMF_5
DTMF 5 95ms.
Definition SpeakJet.h:335
@ Phoneme_FF
70ms Voiceless Fricative
Definition SpeakJet.h:271
@ Sound_R9
80ms Robot
Definition SpeakJet.h:295
@ DTMF_1
DTMF 1 95ms.
Definition SpeakJet.h:331
@ Sound_R2
80ms Robot
Definition SpeakJet.h:288
@ Phoneme_VV
70ms Voiced Fricative
Definition SpeakJet.h:251
@ Pause6
Pause 90ms.
Definition SpeakJet.h:190
@ Sound_C7
260ms Biological
Definition SpeakJet.h:326
@ Phoneme_EHLE
140ms Voiced Diphthong
Definition SpeakJet.h:244
@ PortCtr
Next octet is port control value. See manual. Default is 7.
Definition SpeakJet.h:201
@ Sound_A9
250ms Alarm
Definition SpeakJet.h:306
@ Phoneme_RR
70ms Voiced Resonate
Definition SpeakJet.h:233
@ Phoneme_EH
70ms Voiced Long Vowel
Definition SpeakJet.h:216
@ Sound_M2
WOW 530ms.
Definition SpeakJet.h:345
@ Phoneme_UW
70ms Voiced Long Vowel
Definition SpeakJet.h:224
@ DTMF_STAR
DTMF * 95ms.
Definition SpeakJet.h:340
@ Phoneme_OHIH
185ms Voiced Diphthong
Definition SpeakJet.h:242
@ Sound_C9
75ms Biological
Definition SpeakJet.h:328
@ Bend
Next octet is frequency bend to 15. Default is 5.
Definition SpeakJet.h:200
@ Phoneme_IYUW
180ms Voiced Diphthong
Definition SpeakJet.h:245
@ Phoneme_EYIY
165ms Voiced Diphthong
Definition SpeakJet.h:239
@ Phoneme_OB
10ms Voiced Stop
Definition SpeakJet.h:258
@ Phoneme_SH
50ms Voiceless Fricative
Definition SpeakJet.h:274
@ Phoneme_JH
70ms Voiced Affricate
Definition SpeakJet.h:250
@ Phoneme_NGO
70ms Voiced Nasal
Definition SpeakJet.h:229
@ Sound_R4
80ms Robot
Definition SpeakJet.h:290
@ Phoneme_WW
70ms Voiced Resonate
Definition SpeakJet.h:232
@ DTMF_6
DTMF 6 95ms.
Definition SpeakJet.h:336
@ Phoneme_AWRR
200ms Voiced R Color Vowel
Definition SpeakJet.h:237
@ Phoneme_PO
99ms Voiceless Stop
Definition SpeakJet.h:284
@ Sound_A0
300ms Alarm
Definition SpeakJet.h:297
@ Sound_A2
102ms Alarm
Definition SpeakJet.h:299
@ Phoneme_OG
55ms Voiced Stop
Definition SpeakJet.h:266
@ Sound_R7
80ms Robot
Definition SpeakJet.h:293
@ Phoneme_UH
70ms Voiced Long Vowel
Definition SpeakJet.h:223
@ Phoneme_NE
70ms Voiced Nasal
Definition SpeakJet.h:226
@ Phoneme_HO
70ms Voiceless Fricative
Definition SpeakJet.h:269
@ Phoneme_EG
55ms Voiced Stop
Definition SpeakJet.h:265
@ Slow
Next phoneme at 1.5 speed.
Definition SpeakJet.h:192
@ Phoneme_IY
70ms Voiced Long Vowel
Definition SpeakJet.h:213
@ GotoPhrase
Next octet is EEPROM phgrase to go to. See manual.
Definition SpeakJet.h:205
@ Phoneme_EY
70ms Voiced Long Vowel
Definition SpeakJet.h:215
@ Phoneme_OD
10ms Voiced Stop
Definition SpeakJet.h:262
@ Phoneme_BE
45ms Voiced Stop
Definition SpeakJet.h:255
@ Phoneme_OWIY
225ms Voiced Diphthong
Definition SpeakJet.h:241
@ Sound_A3
540ms Alarm
Definition SpeakJet.h:300
@ Phoneme_UX
70ms Voiced Long Vowel
Definition SpeakJet.h:219
@ Phoneme_ED
10ms Voiced Stop
Definition SpeakJet.h:261
@ Phoneme_KO
55ms Voiceless Stop
Definition SpeakJet.h:280
@ Sound_B6
104ms Beep
Definition SpeakJet.h:314
@ Phoneme_DH
70ms Voiced Fricative
Definition SpeakJet.h:254
@ Reset
Reset Volume Speed, Pitch, Bend to defaults.
Definition SpeakJet.h:207
@ Phoneme_EB
10ms Voiced Stop
Definition SpeakJet.h:257
@ Sound_B5
100ms Beep
Definition SpeakJet.h:313
@ Sound_C0
160ms Biological
Definition SpeakJet.h:319
@ Sound_R6
80ms Robot
Definition SpeakJet.h:292
@ Sound_C8
95ms Biological
Definition SpeakJet.h:327
@ Phoneme_SO
40ms Voiceless Fricative
Definition SpeakJet.h:273
@ DTMF_7
DTMF 7 95ms.
Definition SpeakJet.h:337
@ Phoneme_ZZ
70ms Voiced Fricative
Definition SpeakJet.h:252
@ DTMF_4
DTMF 4 95ms.
Definition SpeakJet.h:334
@ Phoneme_IHWW
170ms Voiced Diphthong
Definition SpeakJet.h:247
@ Phoneme_OWRR
185ms Voiced R Color Vowel
Definition SpeakJet.h:238
@ DTMF_HASH
DTMF # 95ms.
Definition SpeakJet.h:341
@ Sound_R8
80ms Robot
Definition SpeakJet.h:294
@ DTMF_8
DTMF 8 95ms.
Definition SpeakJet.h:338
@ Phoneme_LE
70ms Voiced Resonate
Definition SpeakJet.h:230
@ Sound_A1
101ms Alarm
Definition SpeakJet.h:298
@ Phoneme_MM
70ms Voiced Nasal
Definition SpeakJet.h:225
@ Sound_R5
80ms Robot
Definition SpeakJet.h:291
@ Port
Next octet is Port Output Value. See manual. Default is 0.
Definition SpeakJet.h:202
@ Phoneme_OH
70ms Voiced Long Vowel
Definition SpeakJet.h:220
@ Phoneme_IH
70ms Voiced Long Vowel
Definition SpeakJet.h:214
@ Speed
Next octet is speed 0 to 127. Default 114.
Definition SpeakJet.h:198
@ Phoneme_HE
70ms Voiceless Fricative
Definition SpeakJet.h:268
@ Phoneme_AY
70ms Voiced Long Vowel
Definition SpeakJet.h:217
@ Pause2
Pause 200ms.
Definition SpeakJet.h:186
@ Phoneme_TS
170ms Voiceless Stop
Definition SpeakJet.h:278
@ Sound_C2
182ms Biological
Definition SpeakJet.h:321
@ Sound_M0
Sonar ping 125ms.
Definition SpeakJet.h:343
@ Pause3
Pause 700ms.
Definition SpeakJet.h:187
@ Sound_B9
262ms Beep
Definition SpeakJet.h:317
@ Sound_B7
100ms Beep
Definition SpeakJet.h:315
@ Wait
Stops and waits for a Start (see manual)
Definition SpeakJet.h:195
@ Phoneme_SE
40ms Voiceless Fricative
Definition SpeakJet.h:272
@ Sound_C3
120ms Biological
Definition SpeakJet.h:322
@ Phoneme_IYEH
170ms Voiced Diphthong
Definition SpeakJet.h:243
@ Pitch
Next octet is pitch in Hz = to 255.
Definition SpeakJet.h:199
@ CallPhrase
Next octet is EEPROM phrase to play and return. See manual.
Definition SpeakJet.h:204
@ Sound_A5
500ms Alarm
Definition SpeakJet.h:302
@ Phoneme_WH
70ms Voiceless Fricative
Definition SpeakJet.h:270
@ Sound_B4
300ms Beep
Definition SpeakJet.h:312
@ Sound_R3
80ms Robot
Definition SpeakJet.h:289
@ Phoneme_AW
70ms Voiced Long Vowel
Definition SpeakJet.h:221
@ Sound_A8
300ms Alarm
Definition SpeakJet.h:305
@ Phoneme_NGE
70ms Voiced Nasal
Definition SpeakJet.h:228
@ Phoneme_AX
70ms Voiced Long Vowel
Definition SpeakJet.h:218
@ Phoneme_PE
99ms Voiceless Stop
Definition SpeakJet.h:283
@ Phoneme_OK
45ms Voiceless Stop
Definition SpeakJet.h:282
@ Phoneme_TT
50ms Voiceless Stop
Definition SpeakJet.h:276
@ Phoneme_AYWW
200ms Voiced Diphthong
Definition SpeakJet.h:248
@ Stress
Next phoneme with some stress.
Definition SpeakJet.h:193
@ Soft
Stops and waits for a Start (see manual)
Definition SpeakJet.h:196
@ DTMF_2
DTMF 2 95ms.
Definition SpeakJet.h:332
@ Phoneme_TU
70ms Voiceless Stop
Definition SpeakJet.h:277
@ Sound_C6
160ms Biological
Definition SpeakJet.h:325
@ Phoneme_AXRR
190ms Voiced R Color Vowel
Definition SpeakJet.h:236
@ Pause4
Pause 30ms.
Definition SpeakJet.h:188
@ Sound_B1
270ms Beep
Definition SpeakJet.h:309
bool speakWords(char *words)
Definition SpeakJet.cpp:119
bool speakNumber99(uint8_t n)
Definition SpeakJet.cpp:154
bool speakWord(const char *word)
Definition SpeakJet.cpp:113
bool speakDictionaryEntry(const DictionaryEntry *dict)
Definition SpeakJet.cpp:73
bool isReady()
Definition SpeakJet.cpp:42
void speakCode(uint8_t code)
Definition SpeakJet.cpp:54
Structure for translating text words into SpeakJet codes.
Definition SpeakJet.h:173
const uint8_t * codes
Array of speakjet control codes. End with EndOfPhrase (0xff) (must be in PROGMEM)
Definition SpeakJet.h:175
const char * word
ASCII text of word to speak (must be in PROGMEM)
Definition SpeakJet.h:174