ErichHeinemann / ESP32-Audio-Tests-ML

This Repository is a collection of modified Repositories created by Marcel License
GNU General Public License v3.0
14 stars 3 forks source link

No audio! LittleFS seems to not be working proprely. #1

Open fabiendostie opened 2 years ago

fabiendostie commented 2 years ago

I have been trying to figure it out but I cant't seem to find what's wrong in the code "with my limited knowledge of C++" Here's an exemple of what i'm getting in the serial monitor.

I have sucessfully uploaded the data folder with Little FS.

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0018,len:4
load:0x3fff001c,len:1216
ho 0 tail 12 room 4
load:0x40078000,len:10944
load:0x40080400,len:6388
entry 0x400806b4
E (80) psram: PSRAM ID read error: 0xffffffff
[W][esp32-hal-psram.c:30] psramInit(): PSRAM init failed!

Loading data
Firmware started successfully
Setup done
Listing directory: /0/
[E][vfs_api.cpp:64] open(): /littlefs/0/ does not exist
- failed to open directory
---
ListSamples:
ESP.getFreeHeap() 197208
ESP.getMinFreeHeap() 196796
ESP.getHeapSize() 229832
ESP.getMaxAllocHeap() 113792
Sampler_SetPlaybackSpeed: 0.67
Filter TP: 1.00, HP: 0.133856
main filter reso: 0.632
Sampler_SetPlaybackSpeed: 0.70
Filter TP: 1.00, HP: 0.307084
main filter reso: 0.945
Filter TP: 1.00, HP: 0.385824
main filter reso: 1.186
Sampler_SetPlaybackSpeed: 0.89
Filter TP: 1.00, HP: 0.417320
main filter reso: 1.312
main filter reso: 1.453
Sampler_SetPlaybackSpeed: 1.06
Sampler_SetPlaybackSpeed: 0.93
Sampler_SetPlaybackSpeed: 1.08
Sampler_SetPlaybackSpeed: 0.95
Sampler_SetPlaybackSpeed: 0.87
Sampler_SetPlaybackSpeed: 1.06
Sampler_SetPlaybackSpeed: 1.13
Sampler_SetPlaybackSpeed: 1.20
Sampler_SetPlaybackSpeed: 1.08
Sampler_SetPlaybackSpeed: 1.15
Sampler_SetPlaybackSpeed: 1.06
Sampler_SetPlaybackSpeed: 1.13
Sampler_SetPlaybackSpeed: 1.20

------------------------------------------------------

When i use most of the knobs on the Volka this happens, seems to be related to control changes: for some reason.!&!

------------------------------------------------------

Sampler_SetPlaybackSpeed: 1.03
Sampler_SetPlaybackSpeed: 0.97
Sampler_SetPlaybackSpeed: 1.01
CC A 32 60
Guru Meditation Error: Core  1 panic'ed (IntegerDivideByZero). Exception was unhandled.
Core 1 register dump:
PC      : 0x400d1697  PS      : 0x00060930  A0      : 0x800d180a  A1      : 0x3ffd4410  
A2      : 0x00000005  A3      : 0xbac4b049  A4      : 0xbac4b049  A5      : 0x3ffd1568  
A6      : 0x3ffd43cc  A7      : 0x3ffd43cc  A8      : 0x00000000  A9      : 0x3ffd4370  
A10     : 0x0000000b  A11     : 0x3ffd43cc  A12     : 0x0000000b  A13     : 0x3ffd4410  
A14     : 0x3ffd4390  A15     : 0x00000008  SAR     : 0x0000001d  EXCCAUSE: 0x00000006  
EXCVADDR: 0x00000000  LBEG    : 0x4009232c  LEND    : 0x4009233f  LCOUNT  : 0x00000000  

ELF file SHA256: 0000000000000000

Backtrace: 0x400d1697:0x3ffd4410 0x400d1807:0x3ffd4430 0x40160e7c:0x3ffd4450 0x400d2159:0x3ffd4470 0x400d2865:0x3ffd4490 0x400db15d:0x3ffd44c0 0x4009459e:0x3ffd44e0

Rebooting...
ets Jun  8 2016 00:22:57

rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0018,len:4
load:0x3fff001c,len:1216
ho 0 tail 12 room 4
load:0x40078000,len:10944
load:0x40080400,len:6388
entry 0x400806b4
E (80) psram: PSRAM ID read error: 0xffffffff
[W][esp32-hal-psram.c:30] psramInit(): PSRAM init failed!

Loading data
Firmware started successfully
Setup done
Listing directory: /0/
[E][vfs_api.cpp:64] open(): /littlefs/0/ does not exist
- failed to open directory
---
ListSamples:
ESP.getFreeHeap() 197208
ESP.getMinFreeHeap() 196796
ESP.getHeapSize() 229832
ESP.getMaxAllocHeap() 113792
ProgramChange 1 C0 
ProgramChange 1 0 
Sampler_SetPlaybackSpeed: 0.28
Filter TP: 1.00, HP: 0.070864
main filter reso: 0.576
Sampler_SetPlaybackSpeed: 0.83
Filter TP: 1.00, HP: 0.244092
main filter reso: 0.790
Sampler_SetPlaybackSpeed: 0.93
Filter TP: 1.00, HP: 0.322832
main filter reso: 0.975
Sampler_SetPlaybackSpeed: 0.99
Filter TP: 1.00, HP: 0.354328
main filter reso: 1.074
Sampler_SetPlaybackSpeed: 0.87
Sampler_SetPlaybackSpeed: 0.80
Filter TP: 1.00, HP: 0.385824
Sampler_SetPlaybackSpeed: 0.99
main filter reso: 1.186
Sampler_SetPlaybackSpeed: 1.10
Sampler_SetPlaybackSpeed: 0.93
Sampler_SetPlaybackSpeed: 0.99
Sampler_SetPlaybackSpeed: 0.93
Sampler_SetPlaybackSpeed: 1.06
Sampler_SetPlaybackSpeed: 0.91
Sampler_SetPlaybackSpeed: 0.95
Sampler_SetPlaybackSpeed: 0.85
Sampler_SetPlaybackSpeed: 1.03
Sampler_SetPlaybackSpeed: 0.97
Sampler_SetPlaybackSpeed: 1.08
Sampler_SetPlaybackSpeed: 1.01

Thank you for your help.

ErichHeinemann commented 2 years ago

Hi Fabien, did You enable PSRAM?

The first Error-Message indicates something like that.

E (80) psram: PSRAM ID read error: 0xffffffff [W][esp32-hal-psram.c:30] psramInit(): PSRAM init failed!

Does Your Board support PSRAM? I am using the cheapest ESP32 which do not have any PSRAM. Perhaps You are using the same but used the wrong switches in the Board-Settings in Arduino?

Better try to upload a „Blink“-Sketch first.

Best Regards Erich

Am 08.01.2022 um 03:02 schrieb fabiendostie @.***>:

I have been trying to figure it out but I cant't seem to find what's wrong in the code "with my limited knowledge of C++" Here's an exemple of what i'm getting in the serial monitor.

I have sucessfully uploaded the data folder with Little FS.

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT) configsip: 0, SPIWP:0xee clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00 mode:DIO, clock div:1 load:0x3fff0018,len:4 load:0x3fff001c,len:1216 ho 0 tail 12 room 4 load:0x40078000,len:10944 load:0x40080400,len:6388 entry 0x400806b4 E (80) psram: PSRAM ID read error: 0xffffffff [W][esp32-hal-psram.c:30] psramInit(): PSRAM init failed!

Loading data Firmware started successfully Setup done Listing directory: /0/ [E][vfs_api.cpp:64] open(): /littlefs/0/ does not exist

  • failed to open directory

    ListSamples: ESP.getFreeHeap() 197208 ESP.getMinFreeHeap() 196796 ESP.getHeapSize() 229832 ESP.getMaxAllocHeap() 113792 Sampler_SetPlaybackSpeed: 0.67 Filter TP: 1.00, HP: 0.133856 main filter reso: 0.632 Sampler_SetPlaybackSpeed: 0.70 Filter TP: 1.00, HP: 0.307084 main filter reso: 0.945 Filter TP: 1.00, HP: 0.385824 main filter reso: 1.186 Sampler_SetPlaybackSpeed: 0.89 Filter TP: 1.00, HP: 0.417320 main filter reso: 1.312 main filter reso: 1.453 Sampler_SetPlaybackSpeed: 1.06 Sampler_SetPlaybackSpeed: 0.93 Sampler_SetPlaybackSpeed: 1.08 Sampler_SetPlaybackSpeed: 0.95 Sampler_SetPlaybackSpeed: 0.87 Sampler_SetPlaybackSpeed: 1.06 Sampler_SetPlaybackSpeed: 1.13 Sampler_SetPlaybackSpeed: 1.20 Sampler_SetPlaybackSpeed: 1.08 Sampler_SetPlaybackSpeed: 1.15 Sampler_SetPlaybackSpeed: 1.06 Sampler_SetPlaybackSpeed: 1.13 Sampler_SetPlaybackSpeed: 1.20 Thank you for your help.

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNPRL6HP3QIWS2LYB7TUU6LJ3ANCNFSM5LQBFQLA. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you are subscribed to this thread.

fabiendostie commented 2 years ago

hello, obviously i have tried the blink sketch when i first got the board, i can flash other sketches on it, it's really just this sketch that gives me troubles. I have been using Marcel's sketches successfully, actually installed the original version of this sketch with no issues either, but I would like to install yours for the midi library used as well as the work you have done to integrate it in a Volca, I already have modded my volca but now i also want to add this "addon" because it's fucking amazing! ill give it another go and see what's up! ill keep you posted.

ErichHeinemann commented 2 years ago

If You could compile or load the sketches from Marcel Licence, - then my code should work too, as it is more simple then the code from Marcel.

What are the Error-Messages in the Arduino-IDE? Perhaps drop one of the folders with the Drum-Kits, … probably start with only one drumkit?

Best Regards Erich

Am 05.02.2022 um 10:17 schrieb fabiendostie @.***>:

hello, obviously i have tried the blink sketch when i first got the board, i can flash other sketches on it, it's really just this sketch that gives me troubles. I have been using Marcel's sketches successfully, actually installed the original version of this sketch with no issues either, but I would like to install yours for the midi library used as well as the work you have done to integrate it in a Volca, I already have modded my volca but now i also want to add this "addon" because it's fucking amazing! ill give it another go and see what's up! ill keep you posted.

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1030586652, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNO6OECBMWDB5EB5FELUZTTJPANCNFSM5LQBFQLA. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you commented.

fabiendostie commented 2 years ago

Actually that is the first thing I tried, still not working. I'll try to document what I'm doing as I'm doing this on and off when I have a few spare minutes.

I'll have some proper time this week

But I can upload and run all of marcel's sketches without a hitch. But I can't fully compile yours. I'll send you the info soon.

Thank you for your work and time on this!

ErichHeinemann commented 2 years ago

a simple Screenshot from Arduino-IDE will be enough ...

Am 05.02.2022 um 20:37 schrieb fabiendostie @.***>:

Actually that is the first thing I tried, still not working. I'll try to document what I'm doing as I'm doing this on and off when I have a few spare minutes.

I'll have some proper time this week

But I can upload and run all of marcel's sketches without a hitch. But I can't fully compile yours. I'll send you the info soon.

Thank you for your work and time on this!

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1030686558, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNKENQMB3R4RFGTT7PLUZV363ANCNFSM5LQBFQLA. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you commented.

fabiendostie commented 2 years ago

I'll send a picture of the connection from the PCM card (slightly different model than yours to my nodeMCU esp32s (cheap one too) maybe I'm doing something incorrectly. (I doubt it, but never know) and a screenshot of the error messages that the IDE gives me with your sketch.

fabiendostie commented 2 years ago

here are the pictures and all that the IDE wrote while trying to compile: Screen Shot 2022-02-09 at 9 52 46 PM

...
......
.........
5tq13ylq_jc0000gn/T/arduino_build_157319/sketch/ESP32-Volca-Beats-PCM-MOD.ino.cpp -o /var/folders/k0/hjpsy66n3hg335tq13ylq_jc0000gn/T/arduino_build_157319/sketch/ESP32-Volca-Beats-PCM-MOD.ino.cpp.o
In file included from /Users/lefab/Documents/Arduino/hardware/espressif/esp32/tools/sdk/esp32/include/driver/include/driver/i2s.h:16:0,
                 from /Users/lefab/Documents/Arduino/ESP32-Audio-Tests-ML/ESP32-Volca-Beats-PCM-MOD/i2s_interface.ino:6:
/Users/lefab/Documents/Arduino/hardware/espressif/esp32/tools/sdk/esp32/include/hal/include/hal/i2s_types.h:95:31: error: expected '}' before '__attribute__'
     I2S_COMM_FORMAT_I2S       __attribute__((deprecated)) = 0x01, /*!< I2S communication format I2S, correspond to `I2S_COMM_FORMAT_STAND_I2S`*/
                               ^
/Users/lefab/Documents/Arduino/hardware/espressif/esp32/tools/sdk/esp32/include/hal/include/hal/i2s_types.h:95:59: error: expected unqualified-id before '=' token
     I2S_COMM_FORMAT_I2S       __attribute__((deprecated)) = 0x01, /*!< I2S communication format I2S, correspond to `I2S_COMM_FORMAT_STAND_I2S`*/
                                                           ^
/Users/lefab/Documents/Arduino/hardware/espressif/esp32/tools/sdk/esp32/include/hal/include/hal/i2s_types.h:101:3: error: 'i2s_comm_format_t' does not name a type
 } i2s_comm_format_t;
   ^
/Users/lefab/Documents/Arduino/hardware/espressif/esp32/tools/sdk/esp32/include/hal/include/hal/i2s_types.h:207:1: error: expected declaration before '}' token
 }
 ^
cc1plus: warning: unrecognized command line option '-Wno-frame-address'
Multiple libraries were found for "WiFi.h"
 Used: /Users/lefab/Documents/Arduino/hardware/espressif/esp32/libraries/WiFi
 Not used: /Applications/Arduino.app/Contents/Java/libraries/WiFi
Using library FS at version 2.0.0 in folder: /Users/lefab/Documents/Arduino/hardware/espressif/esp32/libraries/FS 
Using library LittleFS_esp32 at version 1.0.6 in folder: /Users/lefab/Documents/Arduino/libraries/LittleFS_esp32 
Using library arduino_midi_library at version 5.0.2 in folder: /Users/lefab/Documents/Arduino/libraries/arduino_midi_library 
Using library WiFi at version 2.0.0 in folder: /Users/lefab/Documents/Arduino/hardware/espressif/esp32/libraries/WiFi 
exit status 1
Error compiling for board ESP32 Dev Module.
fabiendostie commented 2 years ago

first one was with dev module ( which usually works for my board) this one is with NodeMCU esp32s (which also usually works with this board

Screen Shot 2022-02-09 at 10 11 26 PM Screen Shot 2022-02-09 at 10 12 21 PM

I really do not know what to do, I cant even compile it now!

ErichHeinemann commented 2 years ago

Hi Fabien, .. I would say, it is the ESP 32S … Do you own a ESP32 without an „S“? I am not able to confirm that this is a problem but It seems that the problem comes from the I2S-Driver.

I can test with ESP32 Groom Modules because I never bought the S-Model.

Could You test with a „normal“ older ESP32 ?

Best Regards Erich

fabiendostie commented 2 years ago

I do not have one… i'll get one then/

will get back to you

On Feb 10, 2022, at 3:20 PM, Erich @.***> wrote:

Hi Fabien, .. I would say, it is the ESP 32S … Do you own a ESP32 without an „S“? I am not able to confirm that this is a problem but It seems that the problem comes from the I2S-Driver.

I can test with ESP32 Groom Modules because I never bought the S-Model.

Could You test with a „normal“ older ESP32 ?

Best Regards Erich — Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1035459063, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2KTNOA4ICFWB6FBWRLU2QMXHANCNFSM5LQBFQLA. You are receiving this because you authored the thread.

fabiendostie commented 2 years ago

I received my order, a new esp32 dev kit v1. I succeeded in compiling the code, also uploading it. uploaded wav files using littleFS.

I still don't have sound though. I have serial output when notes are played on the Volca, or when a sequence runs on it although it's not some human-readable stuff that is displayed. see picture.

Screen Shot 2022-02-14 at 3 16 30 AM

do you have any idea what could be my problem? The blue led is flashing? is that normal?

ill tell you how things are wired:

on the 5102: vcc > 5v (from the esp32) 3.3v > not used gnd-flt-dmp > bridged to ground ( from the esp32) scl > not used din > gpio 16 bck > gpio 25 lck > gpio 27 fmt > gpio 26 xmi > 3.3v (from esp32)

tell me if you want a snapshot of the IDE

and before you ask, yes I have tested the 5102 with other sketches, and i do get audio from it (tried some web radio stream sketch)

thanks for your help, i feel i'm sooooo close

ErichHeinemann commented 2 years ago

Which baud rate is used in the code for the serial interface ?

9600? >> ist should be 115200 if You want to see something readable in the Serial-Monitor….

And Your wiring is wrong…

This is the master-plan: https://github.com/marcel-licence/esp32_basic_synth/blob/main/doc/schematic_v01.png https://github.com/marcel-licence/esp32_basic_synth/blob/main/doc/schematic_v01.png

I believe You have exactly this version. Why did You connect Pin 16 to the PCM5102-Board?? 16 is used for serial data .. MIDI TX from the Volca...

Left ESP32 Right PCM5102 GPIO 25 to BCK GPIO 26 to DIN GPIO 27 to LCK 5Volts or to 3.3 Volts to VCC FMT to GND SCL to GND DMP to GND FLT to GND GND to GND

… check the picture!

I prefer to use the smaller versions of these PCM-Boards. On their backside, there are some options to make bridges between some pads to connect SCL, XMP, DMP etc. without any extra wire.

https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/blob/main/ESP32-Volca-Beats-PCM-MOD/Volca%20Beats%20PCM%20MOD.pdf https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/blob/main/ESP32-Volca-Beats-PCM-MOD/Volca%20Beats%20PCM%20MOD.pdf

Am 14.02.2022 um 09:48 schrieb fabiendostie @.***>:

I received my order, a new esp32 dev kit v1. I succeeded in compiling the code, also uploading it. uploaded wav files using littleFS.

I still don't have sound though. I have serial output when notes are played on the Volca, or when a sequence runs on it although it's not some human-readable stuff that is displayed. see picture. https://user-images.githubusercontent.com/53846121/153830241-afdd488e-b7d5-4a6d-b82c-db4a61b8610f.png do you have any idea what could be my problem? The blue led is flashing? is that normal?

ill tell you how things are wired:

on the 5102: vcc > 5v (from the esp32) 3.3v > not used gnd-flt-dmp > bridged to ground ( from the esp32) scl > not used din > gpio 16 bck > gpio 25 lck > gpio 27 fmt > gpio 26 xmi > 3.3v (from esp32)

tell me if you want a snapshot of the IDE

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1038811759, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNIVKGMN5XKLR5P626DU3C6XDANCNFSM5LQBFQLA. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you commented.

fabiendostie commented 2 years ago

Sorry itès my mistake, the GPIO16 is plugged on the midiTX of the Volca through a Homemade Midi In circuit (H11L1 Optocoupler based with a protection diode) That midi in is working 100% been using it to test various controllers and stuff.

used 9600 to upload the code, is there somewhere where it needs to be explicitly specified in the code? I can’t find any mention of Baud Rate or baud rate in the code anywhere?

I can easily do solder bridges w/o wires on the board this was just the setup to do the initial testing will be bridged correctly without extra wires on the final rendition.

thanks, I actually never saw that plan, even when searching for it on Marcel’s many pages… thank you so much for this!

from the formulation on your PDF, I understood that the xmt needed to be wired to 3.3v but not from IT’S Own 3.3 volt!!! so I just plugged it on the esp’s 3.3 volts… now I see my mistake.

thank you for this I’ll try all that later on today.

most likely will be working!

On Feb 14, 2022, at 7:24 PM, Erich @.***> wrote:

Which baud rate is used in the code for the serial interface ?

9600? >> ist should be 115200 if You want to see something readable in the Serial-Monitor….

And Your wiring is wrong…

This is the master-plan: https://github.com/marcel-licence/esp32_basic_synth/blob/main/doc/schematic_v01.png https://github.com/marcel-licence/esp32_basic_synth/blob/main/doc/schematic_v01.png

I believe You have exactly this version. Why did You connect Pin 16 to the PCM5102-Board?? 16 is used for serial data .. MIDI TX from the Volca...

Left ESP32 Right PCM5102 GPIO 25 to BCK GPIO 26 to DIN GPIO 27 to LCK 5Volts or to 3.3 Volts to VCC FMT to GND SCL to GND DMP to GND FLT to GND GND to GND

… check the picture!

I prefer to use the smaller versions of these PCM-Boards. On their backside, there are some options to make bridges between some pads to connect SCL, XMP, DMP etc. without any extra wire.

https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/blob/main/ESP32-Volca-Beats-PCM-MOD/Volca%20Beats%20PCM%20MOD.pdf https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/blob/main/ESP32-Volca-Beats-PCM-MOD/Volca%20Beats%20PCM%20MOD.pdf

Am 14.02.2022 um 09:48 schrieb fabiendostie @.***>:

I received my order, a new esp32 dev kit v1. I succeeded in compiling the code, also uploading it. uploaded wav files using littleFS.

I still don't have sound though. I have serial output when notes are played on the Volca, or when a sequence runs on it although it's not some human-readable stuff that is displayed. see picture. https://user-images.githubusercontent.com/53846121/153830241-afdd488e-b7d5-4a6d-b82c-db4a61b8610f.png do you have any idea what could be my problem? The blue led is flashing? is that normal?

ill tell you how things are wired:

on the 5102: vcc > 5v (from the esp32) 3.3v > not used gnd-flt-dmp > bridged to ground ( from the esp32) scl > not used din > gpio 16 bck > gpio 25 lck > gpio 27 fmt > gpio 26 xmi > 3.3v (from esp32)

tell me if you want a snapshot of the IDE

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1038811759, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNIVKGMN5XKLR5P626DU3C6XDANCNFSM5LQBFQLA. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you commented.

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1039713781, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2LKPEBYCCXT35J7BMTU3GML5ANCNFSM5LQBFQLA. You are receiving this because you authored the thread.

fabiendostie commented 2 years ago

hello, I have been doing a little bit of testing. I still am not getting any sound out of this at all... I re-tested my audio DAC, it does work, I do hear audio from a little internet radio streaming Arduino script. the i2s configuration and wiring are different on that sketch though. So I tried using that same wiring and and I2S pinout and by modifying how the i2S stuff was declared in a test version of your sketch for the Volca. It did compile, but still not working.

here is that internet radio i2S code that works on my setup (esp32 dev kit v1 + WCMCU DAC Breakout board):

#include "Arduino.h"
#include "WiFi.h"
#include "Audio.h"

// Digital I/O used
#define I2S_DOUT      25  // DIN connection
#define I2S_BCLK      27  // Bit clock
#define I2S_LRC       26  // Left Right Clock

Audio audio;

String ssid =     "#########";
String password = "#########";

void setup() {
    Serial.begin(115200);
    WiFi.disconnect();
    WiFi.mode(WIFI_STA);
    WiFi.begin(ssid.c_str(), password.c_str());
    while (WiFi.status() != WL_CONNECTED) delay(1500);
    audio.setPinout(I2S_BCLK, I2S_LRC, I2S_DOUT);
    audio.setVolume(15); // 0...21

//    audio.connecttohost("http://www.wdr.de/wdrlive/media/einslive.m3u");
//    audio.connecttohost("http://macslons-irish-pub-radio.com/media.asx");
//    audio.connecttohost("http://mp3.ffh.de/radioffh/hqlivestream.aac"); //  128k aac
//     audio.connecttohost("http://mp3.ffh.de/radioffh/hqlivestream.mp3"); //  128k mp3
      audio.connecttohost("http://vis.media-ice.musicradio.com/CapitalMP3"); //  128k mp3
//    audio.connecttospeech("Wenn die Hunde schlafen, kann der Wolf gut Schafe stehlen.", "de");
//    audio.connecttohost("http://media.ndr.de/download/podcasts/podcast4161/AU-20190404-0844-1700.mp3"); // podcast
}

void loop()
{
    audio.loop();
}

// optional
void audio_info(const char *info){
    Serial.print("info        "); Serial.println(info);
}
void audio_id3data(const char *info){  //id3 metadata
    Serial.print("id3data     ");Serial.println(info);
}
void audio_eof_mp3(const char *info){  //end of file
    Serial.print("eof_mp3     ");Serial.println(info);
}
void audio_showstation(const char *info){
    Serial.print("station     ");Serial.println(info);
}
void audio_showstreaminfo(const char *info){
    Serial.print("streaminfo  ");Serial.println(info);
}
void audio_showstreamtitle(const char *info){
    Serial.print("streamtitle ");Serial.println(info);
}
void audio_bitrate(const char *info){
    Serial.print("bitrate     ");Serial.println(info);
}
void audio_commercial(const char *info){  //duration in sec
    Serial.print("commercial  ");Serial.println(info);
}
void audio_icyurl(const char *info){  //homepage
    Serial.print("icyurl      ");Serial.println(info);
}
void audio_lasthost(const char *info){  //stream URL played
    Serial.print("lasthost    ");Serial.println(info);
}
void audio_eof_speech(const char *info){
    Serial.print("eof_speech  ");Serial.println(info);
}

Here are the parts I modified in your script to try and Finally make this work.

>>>>> I'll just put the sections where I actually changed/added things in the main sketch tab >>>>

#include <Arduino.h>
#include "FS.h"
#include <LITTLEFS.h>
#include <MIDI.h>
#include "Audio.h"
#include "WiFi.h"

#define SAMPLE_RATE 44100

// Digital I/O used
#define I2S_DOUT      25  // DIN connection
#define I2S_BCLK      27  // Bit clock
#define I2S_LRC       26  // Left Right Clock

volatile uint8_t midi_prescaler = 0;

/* constant to normalize midi value to 0.0 - 1.0f */
#define NORM127MUL  0.007874f
#define ADC_TOLERANCE 2.0f

Audio audio;

>>>>> I also added this to the main sketch tab >>>>

void setup(){
    // put your setup code here, to run once:
    delay(500);

    Serial.begin(115200);
    Serial.println();
    Serial.printf("Loading data\n");
    Serial.printf("Firmware started successfully\n");
    audio.setPinout(I2S_BCLK, I2S_LRC, I2S_DOUT);
    audio.setVolume(15); // 0...21

>>>>> I also added this to the i2S tab >>>>

 * Define and connect your PINS to DAC here
 */
#define I2S_DOUT      25  // DIN connection
#define I2S_BCLK      27  // Bit clock
#define I2S_LRC       26  // Left Right Clock

>>>>> I also finally added this to the i2S tab >>>>

#ifdef I2S_NODAC
i2s_pin_config_t pins ={
   .bck_io_num = I2S_PIN_NO_CHANGE,
   .ws_io_num =  I2S_PIN_NO_CHANGE,
   .data_out_num = 22,
   .data_in_num = I2S_PIN_NO_CHANGE
};
#else
i2s_pin_config_t pins ={
    .bck_io_num = I2S_BCLK,
    .ws_io_num =  I2S_LRC,
   .data_out_num = I2S_DOUT,
    .data_in_num = I2S_PIN_NO_CHANGE
 };
#endif

It does compile, but It does NOT produce audio, with any MIDI sources, keyboards or the actual Volca.

I am very persistent and really want this to work!!!

Any ideas, cues? I would gladly take any help I can get regarding this. I did try to wire exactly like Marcel's picture and diagram you recommended, but it is also not producing any results at all. it's quite frustrating actually, I have no clue how to figure out what's wrong with the code. esp32 is working fine with every other script I tried on it so does the DAC card. I still can compile Marcel's drum computer sketch on it fine, by the way, I hear the metronome and can send midi to it also...

Can you take a look into this please please please?

fabiendostie commented 2 years ago

Hello, I can now see notes on/off and cc's on the serial monitor. That's great... means I'm almost there. I still don't hear anything, but I think it's related to this error that I only get on the serial monitor: FAILED TO OPEN DIRECTORY

Listing directory: /0/
- failed to open directory
---
ListSamples:
ESP.getFreeHeap() 171280
ESP.getMinFreeHeap() 168980
ESP.getHeapSize() 234876
ESP.getMaxAllocHeap() 113792
Sampler_SetPlaybackSpeed: 0.28
Sampler_SetPlaybackSpeed: 0.56
Sampler_SetPlaybackSpeed: 0.63
Sampler_SetPlaybackSpeed: 0.67
Sampler_SetPlaybackSpeed: 0.71
Sampler_SetPlaybackSpeed: 0.74
Sampler_SetPlaybackSpeed: 0.78
Sampler_SetPlaybackSpeed: 0.81

NoteOn 1 31 7F
NoteOff 1 31 0

NoteOn 1 31 7F
NoteOff 1 31 0

NoteOn 1 43 7F

I did have to modify the code to be able for the esp32 to receive the midi correctly ans for the i2s to not throw any errors.

I can post the changes if you like but I'd love you to help me on the , hopefully, last error i'm getting with this code!

thanks in advance

ErichHeinemann commented 2 years ago

Hi, did You successfully upload the samples using LittleFS??

perhaps try a demo of LittleFS to check the upload-function of it.

Best Regards Erich

Am 04.03.2022 um 12:13 schrieb fabiendostie @.***>:

Hello, I can now see notes on/off and cc's on the serial monitor. That's great... means I'm almost there. I still don't hear anything, but I think it's related to this error that I only get on the serial monitor: FAILED TO OPEN DIRECTORY

Listing directory: /0/

  • failed to open directory

    ListSamples: ESP.getFreeHeap() 171280 ESP.getMinFreeHeap() 168980 ESP.getHeapSize() 234876 ESP.getMaxAllocHeap() 113792 Sampler_SetPlaybackSpeed: 0.28 Sampler_SetPlaybackSpeed: 0.56 Sampler_SetPlaybackSpeed: 0.63 Sampler_SetPlaybackSpeed: 0.67 Sampler_SetPlaybackSpeed: 0.71 Sampler_SetPlaybackSpeed: 0.74 Sampler_SetPlaybackSpeed: 0.78 Sampler_SetPlaybackSpeed: 0.81

NoteOn 1 31 7F NoteOff 1 31 0

NoteOn 1 31 7F NoteOff 1 31 0

NoteOn 1 43 7F I did have to modify the code to be able for the esp32 to receive the midi correctly ans for the i2s to not throw any errors.

I can post the changes if you like but I'd love you to help me on the , hopefully, last error i'm getting with this code!

thanks in advance

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1059069433, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNJWRHPHCBTTNJ265CLU6HV47ANCNFSM5LQBFQLA. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you commented.

fabiendostie commented 2 years ago

Yes I did, as I said earlier, I tried the audio module with different sketches involving LittleFS and everything works fine. I'll keep investigating but I did have to modify the pinout, and some 9f the code involving midi and some involving i2s for your code to actually work. Figured it out the hard way since I'm quite a novice in coding.

Almost there, but any help would be appreciated, I've been on this for months now.!

Fabien Dostie Monteur Online / Coloriste Numérique (AQTIS) Datawrangler-DIT-Video Assist (AQTIS/IATSE)

On Sat., Mar. 5, 2022, 09:54 Erich @.***> wrote:

Hi, did You successfully upload the samples using LittleFS??

perhaps try a demo of LittleFS to check the upload-function of it.

Best Regards Erich

Am 04.03.2022 um 12:13 schrieb fabiendostie @.***>:

Hello, I can now see notes on/off and cc's on the serial monitor. That's great... means I'm almost there. I still don't hear anything, but I think it's related to this error that I only get on the serial monitor: FAILED TO OPEN DIRECTORY

Listing directory: /0/

  • failed to open directory

    ListSamples: ESP.getFreeHeap() 171280 ESP.getMinFreeHeap() 168980 ESP.getHeapSize() 234876 ESP.getMaxAllocHeap() 113792 Sampler_SetPlaybackSpeed: 0.28 Sampler_SetPlaybackSpeed: 0.56 Sampler_SetPlaybackSpeed: 0.63 Sampler_SetPlaybackSpeed: 0.67 Sampler_SetPlaybackSpeed: 0.71 Sampler_SetPlaybackSpeed: 0.74 Sampler_SetPlaybackSpeed: 0.78 Sampler_SetPlaybackSpeed: 0.81

NoteOn 1 31 7F NoteOff 1 31 0

NoteOn 1 31 7F NoteOff 1 31 0

NoteOn 1 43 7F I did have to modify the code to be able for the esp32 to receive the midi correctly ans for the i2s to not throw any errors.

I can post the changes if you like but I'd love you to help me on the , hopefully, last error i'm getting with this code!

thanks in advance

— Reply to this email directly, view it on GitHub < https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1059069433>, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AIR2GNJWRHPHCBTTNJ265CLU6HV47ANCNFSM5LQBFQLA . Triage notifications on the go with GitHub Mobile for iOS < https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android < https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.

You are receiving this because you commented.

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1059778255, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2MJIDN36JSNAMFO6ILU6NYTVANCNFSM5LQBFQLA . You are receiving this because you authored the thread.Message ID: @.***>

fabiendostie commented 2 years ago

Unfortunately, the problem is not with uploading the files or little FS, the files are uploading successfully, I get a confirmation in the serial monitor, still no audio out.

Can I upload my code somewhere to show you and you can take a look at it, I<m completely out of resources now, I searched ALL the internet... I'm kidding, but I do always get to the same responses on all the boards and none of the solutions are working for me. I have re-checked with 2 different sketches if the board produces audio, and it does perfectly, just not with your code for some annoying reason!!

could I upload it to my drive so you take a look at it, please?

fabiendostie commented 2 years ago

Here's my modified sketches. I would really appreciate it if you could take a look. I'm completely out of ideas and i can't figure out why it works with all the other sketches I try it with but not yours, it's really bugging me, I need to find this out! Thanks

ESP32-Volca-Beats-PCM-FABMOD.zip

marcel-licence commented 2 years ago

I took also a quick look on the NodeMCU-32S. It seems to be equipped with the ESP-WROOM-32. With regards to https://www.espressif.com/en/products/modules/esp32 it does not support PSRAM and wouldn't be useful for the drum computer and sampler projects at all.

fabiendostie commented 2 years ago

Thanks for answering me I really appreciate it! PSRAM is disabled so this is not the issue. You must be referring to a very old post I did? I have been using a standard esp32 wroom devkit now since at least 4 months now. As I was saying a few months back. This is known by @ErichHeinemann/ESP32-Audio-Tests-ML @.***> I can compile and use all your Sketches they are fantastic. I am currently trying to modify your drum machine script to work with my volca beats but I can't figure out how to modify the midi mapping to fit with the volca's midi CC's.

Been completely unsuccessful. I'm really really getting annoyed that I can't make it work.

I'm trying to learn as much as I can, but I'm just beginning to understand the language and I'm unable to make progress on this project. I'm stuck completely. I can say I'm a little desperate for help especially that I have hooked 4 other pots and 1 button on top of the midi in.

Right now, I see midi getting sent from the volca to the esp32 on the serial monitor of Arduino IDE, but no sound! Eventhough I successfully uploaded the data using littleFS & SPIFFS.

I need help I know I'm sooooo close.

Fabien Dostie DIT/VR & Direction Technique - Coloriste Numérique - DataWrangler, DIT & V/A (AQTIS/IATSE)

On Sat., Apr. 2, 2022, 14:59 Marcel @.***> wrote:

I took also a quick look on the NodeMCU-32S. It seems to be equipped with the ESP-WROOM-32. With regards to https://www.espressif.com/en/products/modules/esp32 it does not support PSRAM and wouldn't be useful for the drum computer and sampler projects at all.

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1086702350, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2OOSS7N6ILMDGFHFE3VDCKI5ANCNFSM5LQBFQLA . You are receiving this because you authored the thread.Message ID: @.***>

fabiendostie commented 2 years ago

This is the board I now have: Esp32 DevKit v1: are you saying it's not going to work? I thought I read that I needed the DevKit v1!?!?

Features: This module has ESP32-D0WDQ6 chip, which is extendable and adaptive. Two CPU cores can be individually controlled or powered. Clock frequency adjusting range is 80 MHz to 240 MHz. Users can cut off the CPU power supply, use low-power coprocessor to constantly monitor the state of peripheral or whether some analog is beyond the threshold. ESP32 also integrates rich peripherals, including capacitive touch sensors, hall sensors, low noise sensor amplifier, SD card interface, Ethernet interface, high-speed SDIO/S P I, UART, I2S, I2C, etc. The board has CP2102 stable USB to TTL chips, to ensure the normal communication of serial port. It supports automatically download, no need to manual switch between download and run mode. It supports development on Windows (cygwin and msys32 simulation environment) and Linux system. ESP32-D0WDQ6 has two built-in low-power 32-bit LX6 MCU.

Fabien Dostie DIT/VR & Direction Technique - Coloriste Numérique - DataWrangler, DIT & V/A (AQTIS/IATSE)

On Sat., Apr. 2, 2022, 15:54 Fabien Dostie @.***> wrote:

Thanks for answering me I really appreciate it! PSRAM is disabled so this is not the issue. You must be referring to a very old post I did? I have been using a standard esp32 wroom devkit now since at least 4 months now. As I was saying a few months back. This is known by @ErichHeinemann/ESP32-Audio-Tests-ML @.***> I can compile and use all your Sketches they are fantastic. I am currently trying to modify your drum machine script to work with my volca beats but I can't figure out how to modify the midi mapping to fit with the volca's midi CC's.

Been completely unsuccessful. I'm really really getting annoyed that I can't make it work.

I'm trying to learn as much as I can, but I'm just beginning to understand the language and I'm unable to make progress on this project. I'm stuck completely. I can say I'm a little desperate for help especially that I have hooked 4 other pots and 1 button on top of the midi in.

Right now, I see midi getting sent from the volca to the esp32 on the serial monitor of Arduino IDE, but no sound! Eventhough I successfully uploaded the data using littleFS & SPIFFS.

I need help I know I'm sooooo close.

Fabien Dostie DIT/VR & Direction Technique - Coloriste Numérique - DataWrangler, DIT & V/A (AQTIS/IATSE)

On Sat., Apr. 2, 2022, 14:59 Marcel @.***> wrote:

I took also a quick look on the NodeMCU-32S. It seems to be equipped with the ESP-WROOM-32. With regards to https://www.espressif.com/en/products/modules/esp32 it does not support PSRAM and wouldn't be useful for the drum computer and sampler projects at all.

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1086702350, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2OOSS7N6ILMDGFHFE3VDCKI5ANCNFSM5LQBFQLA . You are receiving this because you authored the thread.Message ID: @.***>

marcel-licence commented 2 years ago

Ah my memories are coming back. I think the samples are directly played back from the littleFS. In that case you do not need the PSRAM. I tried to look for memory allocations. The analysis of errors is always quite challenging. Often more time consuming than writing new code. By the way there is some statement to format the littleFS first. I can also recommend running a littleFS example. I could find only the SPIFFS_Test which would be deprecated for future use. The goal is to list all stored data of the littleFS. I may also overseen something because I just cross readed the posts

fabiendostie commented 2 years ago

Thanks, but I've already successfuly tried a littleFS test on a formated memory. So I deffinetely can do it...

I think I remember seing some kind of errors on the last SPIFFS upload which I did this morning eventhough it was successful. I'll look into it when I get home soon.

I might just try to completely re-install littleFS/SPIFFS all together.

Is there any log or report that would be more useful for you to be able to help me more easily?

I really appreciate your kind help and I want to make it as easy as possible for you.

Thanks again!

If there's anything I can do to help you in any way please let me know!

Fabien Dostie DIT/VR & Direction Technique - Coloriste Numérique - DataWrangler, DIT & V/A (AQTIS/IATSE)

On Sat., Apr. 2, 2022, 17:07 Marcel @.***> wrote:

Ah my memories are coming back. I think the samples are directly played back from the littleFS. In that case you do not need the PSRAM. I tried to look for memory allocations. The analysis of errors is always quite challenging. Often more time consuming than writing new code. By the way there is some statement to format the littleFS first. I can also recommend running a littleFS example. I could find only the SPIFFS_Test which would be deprecated for future use. The goal is to list all stored data of the littleFS. I may also overseen something because I just cross readed the posts

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1086724394, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2P7DHFSS777MBQSVFLVDCZHPANCNFSM5LQBFQLA . You are receiving this because you authored the thread.Message ID: @.***>

ErichHeinemann commented 2 years ago

Hi Fabien,

Hope, this Wiring helps a bit. Hopefully, the picture will be seen …

Regards Erich

Am 02.04.2022 um 23:24 schrieb fabiendostie @.***>:

Thanks, but I've already successfuly tried a littleFS test on a formated memory. So I deffinetely can do it...

I think I remember seing some kind of errors on the last SPIFFS upload which I did this morning eventhough it was successful. I'll look into it when I get home soon.

I might just try to completely re-install littleFS/SPIFFS all together.

Is there any log or report that would be more useful for you to be able to help me more easily?

I really appreciate your kind help and I want to make it as easy as possible for you.

Thanks again!

If there's anything I can do to help you in any way please let me know!

Fabien Dostie DIT/VR & Direction Technique - Coloriste Numérique - DataWrangler, DIT & V/A (AQTIS/IATSE)

On Sat., Apr. 2, 2022, 17:07 Marcel @.***> wrote:

Ah my memories are coming back. I think the samples are directly played back from the littleFS. In that case you do not need the PSRAM. I tried to look for memory allocations. The analysis of errors is always quite challenging. Often more time consuming than writing new code. By the way there is some statement to format the littleFS first. I can also recommend running a littleFS example. I could find only the SPIFFS_Test which would be deprecated for future use. The goal is to list all stored data of the littleFS. I may also overseen something because I just cross readed the posts

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1086724394, or unsubscribe https://github.com/notifications/unsubscribe-auth/AM22A2P7DHFSS777MBQSVFLVDCZHPANCNFSM5LQBFQLA . You are receiving this because you authored the thread.Message ID: @.***>

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1086726726, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNKASWNOWG3WQVKIOT3VDC3INANCNFSM5LQBFQLA. You are receiving this because you commented.

ErichHeinemann commented 2 years ago

Hi Fabien, I believe, I have found the bug/error/big-mistake in my documentation.

I2C-Pins are wired as described here…

The previous picture was wrong. GPIO 26 and 27 were swapped! it should be connected this way!

If the wiring is already swapped and the ESP is glued into the housing of the Volca, then change the GPIO-Pinout in the File i2s_interface.ino in Lines 17,18 and 19.

/// correct:

define I2S_BCLK_PIN 25

define I2S_DOUT_PIN 26

define I2S_WCLR_PIN 27

// In the previous Documentation it was wrong!! 26/27 were swapped!

This is the right wiring:

fabiendostie commented 2 years ago

I guess this wiring is okay for your variant of the "same" DAC My wiring is okay! the DAC works I test it with a small internet radio sketch and some of marMel's sketches, it is definitely already is ok for my DAC as I mention numerous times in my communications. It does communicate between esp32 and the DAC and also produce sound. so that's not it for me. dac

The issue since I upgraded the libraries (offered by Arduino IDE) is that arduino does not find pyserial so upload don't work anymore. but i have pyserial installed on my system, on both version of python as well. Mac os x still uses pythyon 2.7 and i also need python 3.9 so i have two installs

➜  site-packages sudo -H pip2 install pyserial
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support pip 21.0 will remove support for this functionality.
Collecting pyserial
  Downloading pyserial-3.5-py2.py3-none-any.whl (90 kB)
     |████████████████████████████████| 90 kB 3.7 MB/s
Installing collected packages: pyserial
Successfully installed pyserial-3.5
WARNING: You are using pip version 20.3.1; however, version 20.3.4 is available.
You should consider upgrading via the '/System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python -m pip install --upgrade pip' command.
➜  site-packages sudo -H pip install pyserial
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
**Requirement already satisfied: pyserial in /usr/local/lib/python3.9/site-packages (3.5)**
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
➜  site-packages sudo -H pip3 install pyserial
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
**Requirement already satisfied: pyserial in /usr/local/lib/python3.9/site-packages (3.5)**
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv

I also have added the correct paths the to my .profile actually now it's my ~/.zshrc file so everything should point to the correct python.

but i still get this error:

Error downloading https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.jsonhttps://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
Chip : esp32
esptool : /Users/lefab/Library/Arduino15/packages/esp32/tools/esptool_py/3.0.0/esptool

Erasing all Flash started...
Port: /dev/cu.SLAB_USBtoUART

->esptool.py v3.0-dev
->Serial port /dev/cu.SLAB_USBtoUART
->Connecting......
->Chip is ESP32-D0WDQ6 (revision 1)
->Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
->Crystal is 40MHz
->MAC: 08:3a:f2:ac:49:7c
->Uploading stub...
->Running stub...
->Stub running...
->Erasing flash (this may take a while)...
->Chip erase completed successfully in 1.5s
->Hard resetting via RTS pin...
Chip : esp32
Using partition scheme from Arduino IDE.
Start: 0x110000
Size : 0x2f0000
mklittlefs : /Users/lefab/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/mklittlefs/mklittlefs

esptool : /Users/lefab/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/esptool.py

[LittleFS] data   : /Users/lefab/Documents/Arduino/Projects/LittleFS-SPIFS/LITEULEFES/data
[LittleFS] offset : 0
[LittleFS] start  : 1114112
[LittleFS] size   : 3008
[LittleFS] page   : 256
[LittleFS] block  : 4096
_>skipping .DS_Store
->/1/GateKeeper_Helper.command
_>skipping .DS_Store
->/4/README.md
->/3/1st_test.rns
->/2/87097072.pdf
[LittleFS] upload : /var/folders/k0/hjpsy66n3hg335tq13ylq_jc0000gn/T/arduino_build_958396/LITEULEFES.littlefs.bin
[LittleFS] address: 1114112
[LittleFS] port   : /dev/cu.SLAB_USBtoUART
[LittleFS] speed  : 921600
[LittleFS] mode   : dio
[LittleFS] freq   : 80m

->Pyserial is not installed for /Library/Developer/CommandLineTools/usr/bin/python3. Check the README for installation instructions.
_>Traceback (most recent call last):
_>  File "/Users/lefab/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/esptool.py", line 38, in <module>
_>    import serial
_>ModuleNotFoundError: No module named 'serial'
LittleFS Upload failed!

i literally have been scouring the internet all day looking for a solution, and I havent!

Oh yeah, I even have re-installed the command line tools ( needed on mac for arduino and coding in general)

ErichHeinemann commented 2 years ago

Hi, as I send the screenshots, I believe this is wrong. You can change it in Your i2s_interface.ino or change the wires.

Standard for most things from marcel: 25 > BCK 26 > DIN 27 > LCK

In Your board: 27 BCK 26 LCK 25 DIN

I think, You know that Your yellow wires are different connected than suggested by Marcel und different to the used code.

Here my last corrected Picture for the wiring … that’s how it works and should be wired..

I am watching Your breadboard which You used to mount the 2 boards to top. I hope that the PCM5102 is not mounted directly on top of the other board. Using perfboards with copper-holes, I always put the copper to the downside and not the upper side to prevent any possible shorts.

Best Regards Erich

Am 04.04.2022 um 04:19 schrieb fabiendostie @.***>:

I guess this wiring is okay for your variant of the "same" DAC My wiring is okay! the DAC works I test it with a small internet radio sketch and some of marMel's sketches, it is definitely already is ok for my DAC as I mention numerous times in my communications. It does communicate between esp32 and the DAC and also produce sound. so that's not it for me. https://user-images.githubusercontent.com/53846121/161463263-e51a1641-235f-4398-a2b4-78afcb3d76f9.jpeg The issue since I upgraded the libraries (offered by Arduino IDE) is that arduino does not find pyserial so upload don't work anymore. but i have pyserial installed on my system, on both version of python as well. Mac os x still uses pythyon 2.7 and i also need python 3.9 so i have two installs

➜ site-packages sudo -H pip2 install pyserial DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support pip 21.0 will remove support for this functionality. Collecting pyserial Downloading pyserial-3.5-py2.py3-none-any.whl (90 kB) |████████████████████████████████| 90 kB 3.7 MB/s Installing collected packages: pyserial Successfully installed pyserial-3.5 WARNING: You are using pip version 20.3.1; however, version 20.3.4 is available. You should consider upgrading via the '/System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python -m pip install --upgrade pip' command. ➜ site-packages sudo -H pip install pyserial DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621 Requirement already satisfied: pyserial in /usr/local/lib/python3.9/site-packages (3.5) DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621 WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv ➜ site-packages sudo -H pip3 install pyserial DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621 Requirement already satisfied: pyserial in /usr/local/lib/python3.9/site-packages (3.5) DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621 WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv I also have added the correct paths the to my .profile actually now it's my ~/.zshrc file so everything should point to the correct python.

but i still get this error:

Error downloading https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.jsonhttps://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json Chip : esp32 esptool : /Users/lefab/Library/Arduino15/packages/esp32/tools/esptool_py/3.0.0/esptool

Erasing all Flash started... Port: /dev/cu.SLAB_USBtoUART

->esptool.py v3.0-dev ->Serial port /dev/cu.SLAB_USBtoUART ->Connecting...... ->Chip is ESP32-D0WDQ6 (revision 1) ->Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None ->Crystal is 40MHz ->MAC: 08:3a:f2:ac:49:7c ->Uploading stub... ->Running stub... ->Stub running... ->Erasing flash (this may take a while)... ->Chip erase completed successfully in 1.5s ->Hard resetting via RTS pin... Chip : esp32 Using partition scheme from Arduino IDE. Start: 0x110000 Size : 0x2f0000 mklittlefs : /Users/lefab/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/mklittlefs/mklittlefs

esptool : /Users/lefab/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/esptool.py

[LittleFS] data : /Users/lefab/Documents/Arduino/Projects/LittleFS-SPIFS/LITEULEFES/data [LittleFS] offset : 0 [LittleFS] start : 1114112 [LittleFS] size : 3008 [LittleFS] page : 256 [LittleFS] block : 4096 _>skipping .DS_Store ->/1/GateKeeperHelper.command >skipping .DS_Store ->/4/README.md ->/3/1st_test.rns ->/2/87097072.pdf [LittleFS] upload : /var/folders/k0/hjpsy66n3hg335tq13ylq_jc0000gn/T/arduino_build_958396/LITEULEFES.littlefs.bin [LittleFS] address: 1114112 [LittleFS] port : /dev/cu.SLAB_USBtoUART [LittleFS] speed : 921600 [LittleFS] mode : dio [LittleFS] freq : 80m

->Pyserial is not installed for /Library/Developer/CommandLineTools/usr/bin/python3. Check the README for installation instructions. >Traceback (most recent call last): > File "/Users/lefab/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/tools/esptool.py", line 38, in > import serial >ModuleNotFoundError: No module named 'serial' LittleFS Upload failed! i literally have been scouring the internet all day looking for a solution, and I havent!

Oh yeah, I even have re-installed the command line tools ( needed on mac for arduino and coding in general)

— Reply to this email directly, view it on GitHub https://github.com/ErichHeinemann/ESP32-Audio-Tests-ML/issues/1#issuecomment-1087042642, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIR2GNJZATL6NPYVLGFHZRDVDJGS3ANCNFSM5LQBFQLA. You are receiving this because you commented.

ErichHeinemann commented 2 years ago

I would like to close this, because the LittleFS/Problem is not an issue caused by this project. While this issue, we discovered a bug in the documentation and I added a freehand drawn schematics to make it easier for new users.

fabiendostie commented 2 years ago

My wiring works with marcel's sketches, all of them... I can play and hear sound just perfect! Of course I change the code to reflect how my DAC needs to be wired in his sketches on the i2s page, but nothing else needs to be modified!!! As I have been mentioning since the beginning of this thread: Dieser Dac arbeitet mit 100% von Marcels Skizzen und verwendet genau diese Verkabelung. Offensichtlich muss die Pinbelegung auf der i2s-Seite seiner Skizzen an meine DAC Pinbelegung angepasst werden. Dies ist die einzige Verkabelung, die mit meinem DAC funktioniert, ich habe Ihre ausprobiert, und sie funktioniert nicht mit meinem DAC, da sie sich ein wenig von Ihrer unterscheidet. Zum Beispiel: Auf der Unterseite des Bretts ist überhaupt nichts. Kein Platz für Lötbrücken.

fabiendostie commented 2 years ago

About the perfboard, they are made specifically for arduino projects, they are "wired" exactly like a breadboard. they are double-sided with copper on each side. No danger of shorting. 81JzbcgKw7L _AC_SL1500_ Here are close-ups of the protoboard with esp32 and pcm5102, which are NOT on top of each other and are not connected through the protoboard but only by the wiring. unnamed2 unnamed1

My question to you Is : If I am able to get midi and audio (sound and communication) using this exact wiring and protoboard on other arduino sketches ( all of marcel's sketches, two different internet radio streaming for example). Why am I not able to do that using your sketch? There is definitely something not right here, don't you think?

Meine Frage an Sie lautet: Ich kann Midi und Audio (Ton und Kommunikation) mit genau dieser Verkabelung und diesem Protoboard auf anderen Arduino-Skizzen erhalten (alle Skizzen von Marcel, zum Beispiel zwei verschiedene Internetradio-Streams). Warum kann ich das nicht? das mit deiner Skizze? Da stimmt doch was nicht, findest du nicht?

fabiendostie commented 2 years ago

Also. FYI: I had already drilled holes in my Volca Before for previous mod that I did (snare , hihat and kick sound, which I now control the amount of noise and some other parameters of their sound with 3 Potentiometers)

I figured that since all the sketches from Marcel were working fine on this esp32, I figured It would be the same for yours since it's a port based 95% on his work. I was wrong. But at least No new holes we made yet and as you can see from the pictures above nothing was glued to the volca! ;)

marcel-licence commented 2 years ago

I know the question is not directly for me. But there might be a configuration difference because the time of the fork is somewhere in the past. You can try to output all used pin number using something like: Serial.printf("MIDI_RX2_PIN: %d\n", MIDI_RX2_PIN); and for all others. In addition small local changes are able to break any functionality in some cases.