Replies: 5 comments
-
Hi, |
Beta Was this translation helpful? Give feedback.
-
Hi Marcel,
What do you mean be setting up I2S and I2C? I couldn't find any relating setting in the config.h nor in the README.md I dont know if this is relevant, but: Thank you for any help on this. I am so curious to hear some sound coming from the board. EDIT:
Can you explain how to play back a sound file form LittleFS as one shot sample from code in the main loop? Like:`play('sound.wav'); delay('1000'); |
Beta Was this translation helpful? Give feedback.
-
Hi, To playback sounds from LittleFS you can use the drumcomputer project which is capable of a direct playback. Using the sampler project you need to load the sample into the PSRAM using the code like this:
The settings for the sample will fall back to default if no binary file can be found containing the information of a loop point etc. In https://github.com/marcel-licence/esp32_midi_sampler/blob/main/z_config.ino you will find a lot of connected functions which are used to control the sampler. There was a discussion in the past with some details how to set up a sound without any midi controller. Best regards, |
Beta Was this translation helpful? Give feedback.
-
Hi Marcel, The midi sampler sampler loads a maximum of also 4MB from either sd card or the littleFs to the PSRAM for playback. I am just rethinking if the littleFs can really hold 4MB or is it 4MB - size of program? I am seeing the Partition scheme Setting of the Arduino Ide: Default 4MB with Spiffs (1.2MB App / 1.5MB SPiffs) |
Beta Was this translation helpful? Give feedback.
-
SPIFFS does contain a kind of file system. So you would have a bit less memory of raw data. In case of storing 16bit 44100 samples it would end up by approx 15 seconds. |
Beta Was this translation helpful? Give feedback.
-
EDIT: I think the reason of getting no sound has to to with code from ES8388_Setup() as I get the following output in the serial console on boot:
Hi, I have a ESP32 Audio Kit V2.2 2957 board with ES8388 Codec and i just want to make it play a sound through the headphone output (later also through speakers) when i push one of the 6 buttons. To do so I implemented basic button reads by adding
//Edit to config.h: #define AUDIO_KIT_BUTTON_DIGITAL instead of #define AUDIO_KIT_BUTTON_ANALOG
Then i implemented it as follows in the esp32_audio_kit_module.h file. I receive the button events up and down, but I cannot really play the samples i uploaded the data folders contents to the psram using the mylittlefs plugin for the arduino ide already.
I tried to get it act like this: https://www.youtube.com/watch?v=r0af0DB1R68
In the end i want to read sensors and playback samples as they reach a treshold...
Edits to z_config.h to implement digital button input :
Change
Edits to esp32_audio_kit_module.h to implement digital button input :
Beta Was this translation helpful? Give feedback.
All reactions