请问可以提供2M sps 速率运行的内置ADC的例子吗?
2Msps single channel 有小幅锯齿波噪声叠加
大家好:按照ESP_houwenxiang提供的模板,我已搞定android wifi wave capture-display, 2Msps 4channel & 2Msps 2channel action perfectly, 但是 2Msps single channel 有小幅锯齿波噪声叠加 ,不久前我在Arduino IDE中以i2s模式进行AD单通道采样时------.mode = (i2s_mode_t)(I2S_MODE_MASTER | I2S_MODE_RX | I2S_MODE_ADC_BUILT_IN), 其sample rate 仅能达到78.125Ksps------也遭遇到小幅锯齿波噪声叠加,疑似只要进行AD单通道采样时就有小幅锯齿波噪声叠加,与采样速率无关,多通道scan就正常。我怀疑单通道AD采样值被i2s模块切成左右声道,输出时前后顺序错位,i2s改为单声道可能就OK了。另外小幅锯齿波噪声只有用信号发生器输入正弦波时才能看到,直流信号无锯齿,这更加说明AD数据输出前后顺序可能错位。虽然我对目前的结果已十分满意,毕竟双通道1Msps/channel 的速率省掉了两片AD7476的开销,但还是希望乐鑫能够核查并解决此bug, 圆我一个2Msps/channel的小梦想!!
Re: 请问可以提供2M sps 速率运行的内置ADC的例子吗?
您好,我尝试了这个例子,无法使用,我的idf版本为4.2.1,请问可不可以发一个与4.2.1适配的i2s多通道高速采样adc的例子?谢谢!ESP_houwenxiang wrote: ↑Sat Dec 15, 2018 5:20 amHi, 附件是 ADC 2M AD 采样的示例配置. 2M 是采样率, 4通道平均下来是500K. 采样频率可以降低, 计算公式是 rate = 4M/clkm, 必须是整除, 不然时钟不稳可能会有问题. 由于有些 API 在 IDF 还没有更新, 所以需要手动替换一下
components/driver/rtc_module.c 文件.
Re: 请问可以提供2M sps 速率运行的内置ADC的例子吗?
你好,我编译的时候出现找不到这个头文件:
#include "adc1_i2s_private.h"
全局搜索源码,也找不到这个文件。
#include "adc1_i2s_private.h"
全局搜索源码,也找不到这个文件。
Re: 请问可以提供2M sps 速率运行的内置ADC的例子吗?
参考以上代码和做法,遇到如下错误(找不到头文件:adc1_i2s_private.h):
CC build/driver/rmt.o
CC build/driver/rtc_io.o
CC build/driver/rtc_module.o
In file included from D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:18:
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/esp32/include/rom/ets_sys.h:1:2: warning: #warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead [-Wcpp]
#warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead
^~~~~~~
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:41:10: fatal error: adc1_i2s_private.h: No such file or directory
#include "adc1_i2s_private.h"
^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[1]: *** [/home/ThinkPad/esp/esp-idf-v4.2/make/component_wrapper.mk:292:rtc_module.o] 错误 1
make: *** [D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/make/project.mk:635:component-driver-build] 错误 2
我的版本是esp-idf-4.2
请问这个怎么解决啊?感谢。
CC build/driver/rmt.o
CC build/driver/rtc_io.o
CC build/driver/rtc_module.o
In file included from D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:18:
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/esp32/include/rom/ets_sys.h:1:2: warning: #warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead [-Wcpp]
#warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead
^~~~~~~
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:41:10: fatal error: adc1_i2s_private.h: No such file or directory
#include "adc1_i2s_private.h"
^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[1]: *** [/home/ThinkPad/esp/esp-idf-v4.2/make/component_wrapper.mk:292:rtc_module.o] 错误 1
make: *** [D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/make/project.mk:635:component-driver-build] 错误 2
我的版本是esp-idf-4.2
请问这个怎么解决啊?感谢。
Re: 请问可以提供2M sps 速率运行的内置ADC的例子吗?
i found error :
error: adc1_i2s_private.h: No such file or directory
CC build/driver/rtc_io.o
CC build/driver/rtc_module.o
In file included from D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:18:
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/esp32/include/rom/ets_sys.h:1:2: warning: #warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead [-Wcpp]
#warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead
^~~~~~~
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:41:10: fatal error: adc1_i2s_private.h: No such file or directory
#include "adc1_i2s_private.h"
^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[1]: *** [/home/ThinkPad/esp/esp-idf-v4.2/make/component_wrapper.mk:292:rtc_module.o] 错误 1
make: *** [D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/make/project.mk:635:component-driver-build] 错误 2
Anyone can help?
error: adc1_i2s_private.h: No such file or directory
CC build/driver/rtc_io.o
CC build/driver/rtc_module.o
In file included from D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:18:
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/esp32/include/rom/ets_sys.h:1:2: warning: #warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead [-Wcpp]
#warning rom/ets_sys.h is deprecated, please use esp32/rom/ets_sys.h instead
^~~~~~~
D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/components/driver/rtc_module.c:41:10: fatal error: adc1_i2s_private.h: No such file or directory
#include "adc1_i2s_private.h"
^~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[1]: *** [/home/ThinkPad/esp/esp-idf-v4.2/make/component_wrapper.mk:292:rtc_module.o] 错误 1
make: *** [D:/msys32/home/ThinkPad/esp/esp-idf-v4.2/make/project.mk:635:component-driver-build] 错误 2
Anyone can help?
Re: 请问可以提供2M sps 速率运行的内置ADC的例子吗?
esp-idf v5.1已搞定这些bug, idfv4.x有关ADC, wifi ...的库已全部作废, 几乎所有程序都得重写。
Re: 请问可以提供2M sps 速率运行的内置ADC的例子吗?
3.x到4.x,多了个netif。4.x到5.x后,adc和wifi函数又变了?
Who is online
Users browsing this forum: Google [Bot] and 97 guests