Communicaton ESPNOW send-communicaton espnow rsv codec Sbc #719
-
I RUN ABOVE EXAMPLE AND ADD MAC ADDRESSES , BUT NO COMMUNCATON SUCCESS . /**
#include "AudioTools.h" uint16_t sample_rate = 32000; Sender code auto cfg = now.defaultConfig(); // Setup sine wave // start encoder Serial.println("Sender started..."); void loop() { //--------receiver code
#include "AudioTools.h" ESPNowStream now; void setup() { // setup esp-now // start I2S out.begin(config); // start decoder Serial.println("Receiver started..."); void loop() { //--------sender log //receiver log 17:38:04.336 -> mac: 0C:B8:15:C3:40:68 |
Beta Was this translation helpful? Give feedback.
Replies: 16 comments 2 replies
-
Sr , your library is working like a charm , it was my mistake in receiver of i2s pin assignment , now I can clearly listen the sine tone . But sir now i change sine generator to microphone input (INMP441) , at receiver their is huge noise . (pre test : i2s webserver is successfully working ) I try with different sampling rate 8000 , 22050 , 32000 , 44100 but no success below is my sender code #include "AudioTools.h" I2SStream i2sStream; // Access I2S as stream uint16_t sample_rate = 32000; ESPNowStream now; void setup() { // start i2s input with default configuration // start encoder Serial.println("Sender started..."); void loop() { |
Beta Was this translation helpful? Give feedback.
-
is above possible with i2s microphone (INMP441) ? I2s-> SBC encoder -> espnow -> SBC decoder -> i2S DAC |
Beta Was this translation helpful? Give feedback.
-
I don't see any reason why this should not work. Just check the SBC specification about the supported audio values |
Beta Was this translation helpful? Give feedback.
-
apology if I am missing document. And which i2s microphone you use for your testing , i have INMP441 , does this make any difference ? |
Beta Was this translation helpful? Give feedback.
-
The INMP441 creates noise on one channel if you use it with 16 bits. So you would need to filter that out or use 32 bits and convert them to 16 bits |
Beta Was this translation helpful? Give feedback.
-
yes , you are correct , when was I testing i2s webserver i get the same nose when was using 16bts , but when I change it to 32 bit then i get clear audio on webserver , Now i am using same 32 bit but still its very distorted in receiver after ESPnow , is it necessary to use 16 bit , first use 32 bit and then convert to 16 bit , in web server was using 32 bit and it work fine , same here I cant use use 32 bit directly ? THS IS SENDER CODE and receiver code is same as communication SBC decoder . #include "AudioTools.h" I2SStream i2sStream; // Access I2S as stream uint16_t sample_rate = 32000; ESPNowStream now; void setup() { // start i2s input with default configuration // start encoder Serial.println("Sender started..."); void loop() { |
Beta Was this translation helpful? Give feedback.
-
You can't use 32bit values with the codec! |
Beta Was this translation helpful? Give feedback.
-
FormatConverterStream . . give me error Is their any example were you used FormatConverterStream ? |
Beta Was this translation helpful? Give feedback.
-
Just read the error message. This class must not have any template! |
Beta Was this translation helpful? Give feedback.
-
Sir , please |
Beta Was this translation helpful? Give feedback.
-
I try to use ChannelFormatConverterStreamT . It compile but i am getting same nose in receiver . . ChannelFormatConverterStreamT<int16_t> conv(i2sStream); I Also search in your GITHUB repository you never use in any examples this FormatConverterStream for your conversion . can you please share any example related to this ? Also once you said the latest library also support 24 bit i2s stream and if 24bit values support the codec! , then n ths case may be we don't need conversion ? Further which i2s microphone you used for codecs ? I also try some thing like this but it did not help either |
Beta Was this translation helpful? Give feedback.
-
Sir if you pls help me in converting 32bit to 16 bit for encoder , i will really thank full , as i tried all my attempts . Or if you have related example i will really than full |
Beta Was this translation helpful? Give feedback.
-
I have extended the documentation: https://github.com/pschatzmann/arduino-audio-tools/wiki/Converting-the-Data-Format Please note this uses the functionality of the latest version. In your installed version you will have the following differences:
These changes should make the skeches shorter and clearer... |
Beta Was this translation helpful? Give feedback.
-
yes it look nice and show passionate about your work. after fresh library download i run example * @brief Sending encoded audio over ESPNow it will not work directly ? gives below errors . |
Beta Was this translation helpful? Give feedback.
-
Below code i try for i2s microphone INMP441 . receiver is silent ,No audio Out . i thing in sender their is some missing part . Pre test : #include "AudioTools.h" StreamCopy copier(encoder, conv); const char *peers[] = {"0C:B8:15:C3:40:68"}; auto cfg = now.defaultConfig(); now.begin(cfg); // start i2s input with default configuration Serial.println("Sender started..."); void loop() { /////////////////////////// mac: 94:E6:86:04:89:44 mac: 94:E6:86:04:89:44 |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
#745