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 needed. #37

Open
LieutenantThanon opened this issue Sep 5, 2023 · 3 comments
Open

Help needed. #37

LieutenantThanon opened this issue Sep 5, 2023 · 3 comments

Comments

@LieutenantThanon
Copy link

LieutenantThanon commented Sep 5, 2023

Hello, I'm a beginner to C++. My question is how can I edit the code to adapt it for use with the following components :
MAX9814
PAM8403
And also for the NRF24L01 Antennas as I may need the extended range.

Thanks in advance.

@FedericoBusero
Copy link
Collaborator

It looks like both microphone and amplifier are analogue.
So USE_I2S_MIC_INPUT and USE_I2S_SPEAKER_OUTPUT may not be defined (check platformio.ini and config.h).

But the audio quality is maybe better when using i2s modules instead of analogue.

The microphone pin is defined by
// Analog Microphone Settings - ADC1_CHANNEL_7 is GPIO35
#define ADC_MIC_CHANNEL ADC1_CHANNEL_7

The analogue output pin is fixed in the chip. (DAC).

Your module NRF24L01 cannot be used in this project, I think. For more info on extending the range of ESPnow, check youtube from the creator of this project or from the guy with the swiss accent.

Anyhow, if you need more help, you need to tell which chip you are using exactly.

@LieutenantThanon
Copy link
Author

LieutenantThanon commented Sep 5, 2023

The board I am using for the project is the 38 pin NodeMCU-32S.

@FedericoBusero
Copy link
Collaborator

This should work the way I described in my previous post

Platformio.ini:

[env:nodemcu-32s]
board = nodemcu-32s
platform = [email protected]
build_flags = -Ofast -D USE_ESP_NOW
lib_ignore = indicator_led_pico

In config.h: delete folowing line
#define USE_I2S_SPEAKER_OUTPUT

Then you have
Analog out on D25 and/or D26
Analog in on D35
Button on D23

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