bojanjurca / esp32_oscilloscope Goto Github PK
View Code? Open in Web Editor NEWESP32 oscilloscope - see the signals through Web browser the way ESP32 sees them
License: Creative Commons Zero v1.0 Universal
ESP32 oscilloscope - see the signals through Web browser the way ESP32 sees them
License: Creative Commons Zero v1.0 Universal
I'm trying to build Esp32_oscilloscope.ino
using Arduino-IDE 2.3.2 and I'm getting somthing like this:
(output has scrolled out of the output window, so I cannot see where the error initially occurs.
| ^~~~~~~~
/Users/kuku/Esp32_oscilloscope/fsString.h:46:13: note: candidate expects 1 argument, 2 provided
/Users/kuku/Esp32_oscilloscope/fsString.h:44:13: note: candidate: 'fsString<N>::fsString() [with unsigned int N = 300]'
44 | fsString () {} // for declarations like fsString<15> a;
| ^~~~~~~~
/Users/kuku/Esp32_oscilloscope/fsString.h:44:13: note: candidate expects 0 arguments, 2 provided
exit status 1
Compilation error: expected nested-name-specifier
Memory leak is caused by sendBufferSemaphore = xSemaphoreCreateMutex in oscilloscope.h which creates a new semaphore on the heap each time oscilloscope is run.
This is replaced by xSemaphoreCreateBinaryStatic which creates semaphore on the stack.
I'll keep this issue opened until the next release. Meanwhile please replace oscilloscope.h file from release package with the latest one found in repository.
The use of continuous ADC conversions would allow for consistent measurement windows. This would reduce jitter, and also potentially allow for more datapoints to be measured within a single period. (A typical value for a DSO is 1000 points, vs. this project's 128 points.)
The architecture of this project is too complex for me to instantly see if this would work or not, but looking at oscilloscope.h
it seems like a DMA transfer ought to be a compatible replacement for the delayMicroseconds()
approach.
Hello!
I'm really interested in your work but I can't manage to compile your project.
Indeed, I receive the following error:
webServer.hpp:71:12: fatal error: hwcrypto/sha.h: No such file or directory
I googled around and found it should be replaced by esp32/sha.h.
But this leads to more errors.
I've got the feeling I'm missing some prerequisites here: library to install, settings in Arduino IDE, ...
Any idea what could it be?
board=esp32doit-devkit-v1 boardsmanager.additional.urls=https://github.com/stm32duino/BoardManagerFiles/raw/main/package_stmicroelectronics_index.json,https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json,https://arduino.esp8266.com/stable/package_esp8266com_index.json,https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.json
Thank you very much in advance!
Could you explain how to get this done? I do not see the option when the board NodeMCU 32S is chosen.
If i chose some of the other options, the partition tool becomes available, but then I cannot compile sketch.
Thanks
Hi, looks like a great project, but I'm having a few issues getting going with it - although I'm new to Arduino IDE...
I'm using IDE 2.2.1 and a DFRobot Firebeetle ESP32
When compiling the sketch, it doesn't like the const "OVERFLOW" - some googling suggested it was reserved and should be something else. I renamed it and the references I could find to OVERFLO - there are some other "warnings" also - is there a recommended IDE version I should be using? Apologies if I missed it.
When the ESP starts up and I try FTP'ing to it, it rejects the request.
Suggestions?
Thanks in advance,
One solution may be to increase the CPU frequency of ESP32.
The other solution is to disable the watchdog.
First
#include <soc/rtc_wdt.h>
then (in setup function)
void setup () {
rtc_wdt_protect_off ();
rtc_wdt_disable ();
If you are using an Esp32 oscilloscope as a stand alone solution this may be perfectly OK. But if it is just a part of your project, disabling the watchdog may not really be what you desire.
One solution may be to increase the CPU frequency of ESP32.
The other solution is to disable the watchdog.
First
#include <soc/rtc_wdt.h>
then (in setup function)
void setup () {
rtc_wdt_protect_off ();
rtc_wdt_disable ();
If you are using an Esp32 oscilloscope as a stand alone solution this may be perfectly OK. But if it is just a part of your project, disabling the watchdog may not really be what you desire.
I change the wifi ssid and password correctly.
But ESP32 cannot connect to the WiFi.
[network] starting WiFi 12:00:00.019 -> [ 947] [network] [STA] connecting STAtion to router using DHCP 12:00:00.115 -> [ 1061] [network] [STA] WiFi client started 12:00:00.115 -> [ 1070] [httpServer] started 12:00:00.115 -> [ 1071] [ftpServer] started 12:00:02.172 -> [ 3112] [network] [STA] disconnected from WiFi 12:00:14.952 -> [ 15913] Could not find NTP server by its name. 12:00:14.952 -> [ 15914] Could not find NTP server by its name. 12:00:15.000 -> [ 15915] Could not find NTP server by its name.
Hope to know what the problem is. Thank you very much.
Hello,
I would like to use your very nice code to test some sensors, at home but also at other places.
For this, it would be really helpful, if I could change the wifi settings "on the fly", with a library like IotWebConf, for instance.
Have you ever thought of this?
Kind Regards, Dieter
Hello,
Thanks a lot for feedback Bojan: I will update the code, best wishes for 2021.
Thanks for the nice project.
I've been able to deploy the oscilloscope on the web server.
But nothing can be observed when activating a GPIO connecting to a PWN on Arduino: there is no wave observable at screen, activating the gpio seems ok as there is slight oscillations, but nothing chances if the GPIO is connectef to Arduino PWM
cloned your repo and tried to compile, running into this
In file included from /home/poc/workspace/Esp32_oscilloscope/Esp32_oscilloscope.ino:26:0: file_system.h:27:12: fatal error: SPIFFS.h: No such file or directory #include <SPIFFS.h> ^~~~~~~~~~ compilation terminated. exit status 1 SPIFFS.h: No such file or directory
any idea?
Nice project and thanks for sharing. In regard to this comment of yours:
I do not know how to digitalRead PWM signals directly from GPIOs that output them. Any useful idea would be greatly appreciated.
In my project FastAccelStepper, the mcpwm are used to output stepper signals. Those pulses are read back from the pin and fed into the pcnt modules. Perhaps similar approach works for your issue. The relevant code is:
void StepperQueue::connect_mcpwm_pcnt() {
const struct mapping_s *mapping = (const struct mapping_s *)driver_data;
mcpwm_unit_t mcpwm_unit = mapping->mcpwm_unit;
mcpwm_gpio_init(mcpwm_unit, mapping->pwm_output_pin, _step_pin);
// Doesn't work with gpio_matrix_in
// gpio_matrix_in(step_pin, mapping->input_sig_index, false);
gpio_iomux_in(_step_pin, mapping->input_sig_index);
}
The key is gpio_iomux_in()
. Via github search could not see, that you use this function. Perhaps new to you and a direction towards a solution. even though, no turn-key solution.
I am trying to install the oscilloscope but it is giving formatting error.
[ 43] [file system] formatting, please wait ...
[ 43] [file system] formatting failed.
[ 44] [network] file system not mounted, can't read or write configuration files.
Can you help me ?
I get the following error:
In file included from c:\users\frede\dropbox\min computer (classic-app-pc)\documents\arduinodata\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-80-g6c4433a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\algorithm:60:0,
from C:\Users\Frede\Dropbox\Min computer (Classic-App-PC)\Documents\ArduinoData\packages\esp32\hardware\esp32\1.0.4\cores\esp32/Arduino.h:142,
from sketch\Esp32_oscilloscope.ino.cpp:1:
c:\users\frede\dropbox\min computer (classic-app-pc)\documents\arduinodata\packages\esp32\tools\xtensa-esp32-elf-gcc\1.22.0-80-g6c4433a-5.2.0\xtensa-esp32-elf\include\c++\5.2.0\utility:68:28: fatal error: bits/c++config.h: No such file or directory
compilation terminated.
exit status 1
Error compiling for board ESP32 Dev Module.
It is not clear to me where to put the library?
Is it possible to integrate an https server so that I can use it as an iframe in an IoT project?
thanks
ralph
is there any progress of i2s for fast ADC sampling?
Is there a way to have a BIN file for ESP32 WROOM32?
Or a quick way to make one?
hello,
i get the error: Ftp : 421 file system not mounted. i have formatted it in fat.
Pls help
Please release the flashable bin files for the main ESP32 versions.
So we can flash it using web esptool.
made the build, uploaded it with my wifi credentials changed before and run into the stackoverflow, when i try to connect to port 80, maybe you can see it already? If you need more information let me know!
'
ets Jun 8 2016 00:22:57
rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0018,len:4
load:0x3fff001c,len:1216
ho 0 tail 12 room 4
load:0x40078000,len:9720
ho 0 tail 12 room 4
load:0x40080400,len:6352
entry 0x400806b8
[ 32] [network] [STA] connecting STAtion to router using DHCP ...
[ 105] [network] WiFi interface ready.
[ 105] [network] [STA] WiFi client started.
[ 106] [file system] mounting SPIFFS ...
[ 202] [file system] SPIFFS mounted.
[ 204] [ftpServer] started on 0.0.0.0:21.
[ 204] FTP server has started.
[ 215] [httpServer] started on 0.0.0.0:80.
[ 215] WEB server has started.
[ 251] [network] [STA] connected to WiFi **************.
[ 260] [network] [STA] obtained IP address nnn.nnn.nnn.nnn.
ERROR A stack overflow in task TcpConnection has been detected.
abort() was called at PC 0x4008ca48 on core 1
Backtrace: 0x4008c800:0x3ffce530 0x4008ca31:0x3ffce550 0x4008ca48:0x3ffce570 0x40089b14:0x3ffce590 0x4008b778:0x3ffce5b0 0x4008b72e:0xfefefefe
Rebooting...
'
I love this project, it's absolutely awesome. One thing I find myself instantly missing is the ability to see the deep resolution I get with ~1000 points per image. What is the current bottleneck on points per update, and what would it take to go past that?
Weird little issue, running the bog standard code (just added wifi credentials) and no matter what ADC1 GPIO i use i always get a high signal from analog read even with nothing connected to the selected pin. When pulling the selected pin down to ground the scope displays 4095, when pulling the pin high to 3.3v i get 0 across the board.
According to the readme 'analog values from 0 to 4095 <...> correspond to 0 V to 3.3 V' this is the opposite of what it is doing for me. Am i misunderstanding how this is supposed to work?
When compiling this project for an Adafruit ESP32 feather board, I get hundreds of was "not declared in this scope;" errors.
There is a minor memory leak in LwIP sockets for IDF < 4, see: espressif/esp-idf#8168
Minor memory leak causes just a minor problem in single-threaded environment but in multi-threaded environment it causes more serious memory fragmentation.
A workaround is engaging each of the available sockets at the very beginning (by calling HTTP server 10 times through local loopback) so there are not going to be any memory leaks afterwards and hence also no memory fragmentation.
I'll keep this issue opened until the next release. Meanwhile please replace Esp32_oscilloscope.ino file from release package with the latest one found in repository.
This is not an issue.
Thank you for comprehensive multi web server piece of software. I am enjoying testing it.
If time allows can you just create a repository with just websocket server for ESP32?
No FTP server, no HTTP server , no time related code. Just plain websocket server which can communicate with javascript client in web browser and may be display a graph from couple of variables like you show for freeheap and uptime on index page of your Esp32_web_ftp_telnet_server_template.
It should be barebone template where it is simple and people like me can understand and use it in their small project like home automation without complexity of all in one software.
Thank you.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.