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

help me ,error: 'm_i2s_chan_cfg' was not declared in this scope #952

Open
genicsoft opened this issue Jan 16, 2025 · 10 comments
Open

help me ,error: 'm_i2s_chan_cfg' was not declared in this scope #952

genicsoft opened this issue Jan 16, 2025 · 10 comments

Comments

@genicsoft
Copy link

I am using esp32
The development platform is platformio
At this time, I cannot use the latest version 3.1.0 of ESP32-audioI2S
It prompts the following error,

/ESP32-audioI2S/src/Audio.cpp:177:5: error: 'm_i2s_chan_cfg' was not declared in this scope

/ESP32-audioI2S/src/Audio.cpp:178:36: error: 'I2S_ROLE_MASTER' was not declared in this scope

/ESP32-audioI2S/src/Audio.cpp:182:39: error: 'm_i2s_tx_handle' was not declared in this scope

Many, many similar errors.

I used the old 3.0.13x and it was fine.

please help me

thank you

@schreibfaul1
Copy link
Owner

I2S_ROLE_MASTER is defined in i2s_types.h.
This comes from the IDF framework and should be loaded together with Arduino V3.1.0.

@genicsoft
Copy link
Author

Thank you dear.
It seems that if I want to use the latest version, I may need to migrate to arduino3.0, and the platformio platform I am using now seems not easy to use the latest arduino3.0
I need to switch my work to esp-idf and try to see if I can use the 3.1x version.

Thank you for your work, it works very well. I will give you some surprises.

@schreibfaul1
Copy link
Owner

You could use one of these versions in platformio.ini:

;platform = https://github.com/pioarduino/platform-espressif32/releases/download/51.03.05/platform-espressif32.zip  ;Arduino 3.0.5 / IDF 5.1.4
;platform = https://github.com/pioarduino/platform-espressif32/releases/download/53.03.10-rc3/platform-espressif32.zip ;Arduino 3.1.0 / IDF 5.3.1
;platform = https://github.com/pioarduino/platform-espressif32/releases/download/51.03.07/platform-espressif32.zip   ;Arduino core 3.0.7 / IDF 5.1.4
;platform = https://github.com/pioarduino/platform-espressif32/releases/download/stable/platform-espressif32.zip ;Arduino core 3.1.0 / IDF 5.3.1

@genicsoft
Copy link
Author

thank you

It seems I need to study for a while.

@lorrainemutheu
Copy link

I2S_ROLE_MASTER is defined in i2s_types.h. This comes from the IDF framework and should be loaded together with Arduino V3.1.0.

I am having the same issue as @genicsoft. Not just with the I2S_ROLE_MASTER but also with 'm_i2s_chan_cfg' was not declared in this scope. The latest version of Arduino I can see is V2.3.4. I cannot see V3.1.0. Kindly is there a way to solve the issue without updating Arduino

@genicsoft
Copy link
Author

I2S_ROLE_MASTER is defined in i2s_types.h. This comes from the IDF framework and should be loaded together with Arduino V3.1.0.

I am having the same issue as @genicsoft. Not just with the I2S_ROLE_MASTER but also with 'm_i2s_chan_cfg' was not declared in this scope. The latest version of Arduino I can see is V2.3.4. I cannot see V3.1.0. Kindly is there a way to solve the issue without updating Arduino

schreibfaul1 give us good method but is arduino3.0+
Later I used version 3.0.13x, it is not need arduino3.0+

do you need 3.0.13x ? email me ,i send you.

@lorrainemutheu
Copy link

I2S_ROLE_MASTER is defined in i2s_types.h. This comes from the IDF framework and should be loaded together with Arduino V3.1.0.

I am having the same issue as @genicsoft. Not just with the I2S_ROLE_MASTER but also with 'm_i2s_chan_cfg' was not declared in this scope. The latest version of Arduino I can see is V2.3.4. I cannot see V3.1.0. Kindly is there a way to solve the issue without updating Arduino

schreibfaul1 give us good method but is arduino3.0+ Later I used version 3.0.13x, it is not need arduino3.0+

do you need 3.0.13x ? email me ,i send you.

@genicsoft kindly send me version 3.0.13x. My email is [email protected]. also if you have the a link or executable file of arduino ide v3.0 kindly also send

@1359450511
Copy link

;platform = https://github.com/pioarduino/platform-espressif32/releases/download/stable/platform-espressif32.zip ;Arduino core 3.1.0 / IDF 5.3.1

After using this platform, the chip keeps restarting after downloading the program. Upon checking the command line printing information, it was found that the wdt of core1 caused the cycle restart. However, I don't know how to turn off this watchdog. My chip is ESP32S3N16R8 development platform: platformIO

@Marcin-Fenger
Copy link

platform = https://github.com/pioarduino/platform-espressif32/releases/download/53.03.11/platform-espressif32.zip

[email protected] works perfectly on ESP32 n16r8
mclk x512 & oversampling x128 is set for DAC -> also works!

@schreibfaul1
Copy link
Owner

Here is an example for Platformio:
https://github.com/schreibfaul1/ESP32_Arduino_ESPIDF/blob/master/platformio.ini

If you only want to use Arduinio you can change this line
framework = arduino, espidf --> framework = arduino

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

5 participants