ArminJo / Talkie

Refurbished Arduino version of the Talkie library from Peter Knight.
GNU General Public License v3.0
214 stars 52 forks source link

ESP32 - Crashes after first word #39

Closed ArminJo closed 1 year ago

ArminJo commented 1 year ago

Originally posted by addelovein February 3, 2023 I hear the first word (LOW) Since i have bno amplifier...

Connected 3.3v - 26 Speaker to GND and 25

After first Say:

[ 1559][E][esp32-hal-cpu.c:110] addApbChangeCallback(): duplicate func=0x400d27d8 arg=0x3ffbdb6c E (1544) timer_group: timer_isr_callback_add(236): register interrupt service failed

ArminJo commented 1 year ago

Add check for NULL

 if(sTalkieSampleRateTimer == NULL) {
        sTalkieSampleRateTimer = timerBegin(1, APB_FREQUENCY_DIVIDER, true);
        timerAttachInterrupt(sTalkieSampleRateTimer, timerInterrupt, true);
        timerAlarmWrite(sTalkieSampleRateTimer, (getApbFrequency() / APB_FREQUENCY_DIVIDER) / SAMPLE_RATE, true);
    }