Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No sound with Esp32 Audio Kit 2.2 es8388 #117

Open
ramainen opened this issue Apr 29, 2024 · 1 comment
Open

No sound with Esp32 Audio Kit 2.2 es8388 #117

ramainen opened this issue Apr 29, 2024 · 1 comment

Comments

@ramainen
Copy link

I have a Esp32 Audio Kit 2.2, and I have no sound.
I uncommented #define BOARD_ESP32_AUDIO_KIT_ES8388 and add #define ESP32_AUDIO_KIT
I connected MIDI keyboard, and when pressing keys, red LED is flashing.
I read #71 and write ES8388_CFG_I2C / ES8388_CFG_I2S. Actualy, I tried all possible combinations, and finally found my board exactly model and name, and put right pins from datasheet (ES8388_CFG_I2C = 2 and ES8388_CFG_I2S = 1 in my case), exactly as in #71 issue.

(from datasheet:)
DOUT IO35
DIN IO25
LRCK IO26
BCLK IO27
MCLK 0

SCL 32
SDA IO33

finally, I uncomment #define NOTE_ON_AFTER_SETUP but still nothing.

I connected earphones in "Earphones" jack, also I connect speaker to LOUT and ROUT. In earphones always silence, in speaker - silent white noise.

I using just esp32_basic_synth with default z_config, but as I believe, with NOTE_ON_AFTER_SETUP this is not matters.

Switchers in 1 2 3 position (as in photo below):

image

But! If I connect midi to IO21 (instead of IO22), loud white noise starting from earphones (red led not flashing when i pressing keys)

In serial console I see next:

 esp32_basic_synth  Copyright (c) 2023  Marcel Licence
This program comes with ABSOLUTELY NO WARRANTY;
This is free software, and you are welcome to redistribute it
under certain conditions; 
Initialize Synth Module
Initialize I2S Module
Connect to ES8388 codec...
  SDA: 33
   SCL: 32
  freq: 400000
0x00: 0x05
0x01: 0x40
AdcCh1!
MixChAMPL!
ES8388 setup finished!
Reg 0x00 = 0x05
Reg 0x01 = 0x40
Reg 0x02 = 0x00
Reg 0x03 = 0x00
Reg 0x04 = 0x3c
Reg 0x05 = 0x00
Reg 0x06 = 0x00
Reg 0x07 = 0x7c
Reg 0x08 = 0x00
Reg 0x09 = 0x88
Reg 0x0a = 0x50
Reg 0x0b = 0x02
Reg 0x0c = 0x0c
Reg 0x0d = 0x02
Reg 0x0e = 0x30
Reg 0x0f = 0x20
Reg 0x10 = 0x00
Reg 0x11 = 0x00
Reg 0x12 = 0x16
Reg 0x13 = 0xb0
Reg 0x14 = 0x32
Reg 0x15 = 0x06
Reg 0x16 = 0x00
Reg 0x17 = 0x18
Reg 0x18 = 0x02
Reg 0x19 = 0x22
Reg 0x1a = 0x00
Reg 0x1b = 0x02
Reg 0x1c = 0x08
Reg 0x1d = 0x00
Reg 0x1e = 0x1f
Reg 0x1f = 0xf7
Reg 0x20 = 0xfd
Reg 0x21 = 0xff
Reg 0x22 = 0x1f
Reg 0x23 = 0xf7
Reg 0x24 = 0xfd
Reg 0x25 = 0xff
Reg 0x26 = 0x1b
Reg 0x27 = 0xb8
Reg 0x28 = 0x28
Reg 0x29 = 0x28
Reg 0x2a = 0xb8
Reg 0x2b = 0x80
Reg 0x2c = 0x00
Reg 0x2d = 0x00
Reg 0x2e = 0x1e
Reg 0x2f = 0x1e
Reg 0x30 = 0x1e
Reg 0x31 = 0x1e
Reg 0x32 = 0x00
Reg 0x33 = 0xaa
Reg 0x34 = 0xaa
I2S configured using following pins:
    BCLK,BCK: 27
    WCLK,LCK: 26
    DOUT: 25
    DIN: 35
rev: 15329, 15329
Reverb is ready!
MIDI listen on Serial with 115200 baud
Setup Serial2 with 31250 baud with rx: IO21 only
Setup MidiPort2 using Serial2
ESP.getFreeHeap() 83772
ESP.getMinFreeHeap() 83740
ESP.getHeapSize() 286852
ESP.getMaxAllocHeap() 51188
Total heap: 286852
Free heap: 83772
Total PSRAM: 0
Free PSRAM: 0
Firmware started successfully
@marcel-licence
Copy link
Owner

Hi, looks like the ES8388 codec was found (I2C configuration is correct).
You could activate the #define OUTPUT_SAW_TEST. That will bypass the synth and just test the audio output. If it does not work the I2S configuration may be incorrect.
GPIO0 might be left open.
Regarding the DIP switches: 1 or 2 should be placed in the down position. Otherwise KEY2 and DATA2 are both connected to IO13 which may lead to problems when using the SD card.
Hope this helps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants