Giter Club home page Giter Club logo

esphttpd-freertos's People

Contributors

chmorgan avatar davidantliff avatar jkent avatar m0hai avatar pabbott-lumitec avatar paulfreund avatar phatpaul avatar spritetm avatar tidklaas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

esphttpd-freertos's Issues

httpdFreertosStart shutdown/deinit

Hello,

Can't find any documentation how to deinit httpd instance, it causes StoreProhibited error wen trying to esp_wifi_stop(); and esp_wifi_deinit(); after httpdFreertosStart was called, resulting in no possibility to turn off wifi dynamically with httpd server.

'ln' is not recognized as.... ninja failed with exit code 1

Hi,

I have just started to learn how to use the esp32. This project would be a great help.
So I tried to build it on windows 10 using esp-idf 4.0 stable. My setup seems to work correctly with other projects and examples.

Running idf.py build on this one, the first issue was:

[665/686] Performing install step for 'mkespfsimage'
[0/1] Install the project...
-- Install configuration: ""
-- Installing: C:/Users/Egon/esp/esphttpd-freertos/build/esp-idf/espfs/mkespfsimage/mkespfsimage.exe
[667/686] Generating node_modules
FAILED: esp-idf/espfs/node_modules
cmd.exe /C "cd /D C:\Users\Egon\esp\esphttpd-freertos\build\esp-idf\espfs && npm install --save-dev @babel/core @babel/cli @babel/preset-env babel-preset-minify html-minifier uglifycss"
'npm' is not recognized as an internal or external command,
operable program or batch file.
ninja: build stopped: subcommand failed.
ninja failed with exit code 1

Fixed it by installing: https://nodejs.org/en/
Unfortunately I got stuck at the following:

[839/857] Generating bin/uglifycss
FAILED: esp-idf/espfs/bin/uglifycss
cmd.exe /C "cd /D C:\Users\Egon\esp\esphttpd-freertos\build\esp-idf\espfs && ln -fs ../node_modules/.bin/uglifycss bin/"
'ln' is not recognized as an internal or external command,
operable program or batch file.
[840/857] Generating bin/babel
FAILED: esp-idf/espfs/bin/babel
cmd.exe /C "cd /D C:\Users\Egon\esp\esphttpd-freertos\build\esp-idf\espfs && ln -fs ../node_modules/.bin/babel bin/"
'ln' is not recognized as an internal or external command,
operable program or batch file.
[841/857] Generating bin/html-minifier
FAILED: esp-idf/espfs/bin/html-minifier
cmd.exe /C "cd /D C:\Users\Egon\esp\esphttpd-freertos\build\esp-idf\espfs && ln -fs ../node_modules/.bin/html-minifier bin/"
'ln' is not recognized as an internal or external command,
operable program or batch file.
ninja: build stopped: subcommand failed.
ninja failed with exit code 1

As I just started to learn esp32 stuff and I am not an experienced c++ / linux programmer I don't know how to fix that one.
My guess is that the cmake scripts use linux commands.
I am a bit sad about it since the esphttpd library seems to be just what I was looking for. Also this example seems very usefull.

I would really appreciate your advise.
Egon :-)

Incorrect path in ROUTE_REDIRECT?

In the ROUTE_REDIRECTs below, was it intended that the second one should instead be ROUTE_REDIRECT("/test/", "/test/index.html"),?

Lines 173..175 in user_main.c

	ROUTE_REDIRECT("/test", "/test/index.html"),
	ROUTE_REDIRECT("/test", "/test/index.html"),
	ROUTE_CGI("/test/test.cgi", cgiTestbed),

Project does not compile

I can not get the stock project to compile targeting the ESP32. I am using git commit 2cd29cb of this project and the release/v4.0 branch of the ESP-IDF @ 463a9d8.

Procedure to reproduce:

  1. Clone the repository, cd into the new folder and run the git submodule update command specified in the README
  2. Run make
  3. Once the 'menuconfig' menu appears, change nothing, just save the default config and exit

The following error will occur:

AR build/espcoredump/libespcoredump.a
CC build/espfs/src/espfs.o
CC build/espfs/src/espfs_vfs.o
CC build/espfs/heatshrink/src/heatshrink_decoder.o
▐ ╢░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
WARN engine [email protected]: wanted: {"node":">=6.4.0"} (current: {"node":"4.2.6","npm":"3.5.2"})
WARN engine @babel/[email protected]: wanted: {"node":">=6.9.0"} (current: {"node":"4.2.6","npm":"3.5.2"})
WARN engine [email protected]: wanted: {"node":">=6"} (current: {"node":"4.2.6","npm":"3.5.2"})
WARN engine [email protected]: wanted: {"node":">=6.4.0"} (current: {"node":"4.2.6","npm":"3.5.2"})
WARN engine @babel/[email protected]: wanted: {"node":">=6.9.0"} (current: {"node":"4.2.6","npm":"3.5.2"})
loadDep:chokidar → 304    ▌ ╢█████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
loadDep:chokidar → resolv ▄ ╢█████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
WARN engine [email protected]: wanted: {"node":">=6"} (current: {"node":"4.2.6","npm":"3.5.2"})
loadDep:urix → request    ▄ ╢█████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
loadDep:semver → request  ▀ ╢███████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
loadDep:resolve → addName ▌ ╢████████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
WARN engine [email protected]: wanted: {"node":">=6.9.0"} (current: {"node":"4.2.6","npm":"3.5.2"})
WARN engine @babel/[email protected]: wanted: {"node":">=6.0.0"} (current: {"node":"4.2.6","npm":"3.5.2"})
loadDep:levenary → resolv ▄ ╢███████████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
loadDep:leven → request   ▐ ╢███████████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░╟
npm WARN saveError ENOENT: no such file or directory, open '/home/jgaluska/develop/esp32/esphttpd-freertos/build/espfs/package.json'
/home/jgaluska/develop/esp32/esphttpd-freertos/build/espfs
├─┬ @babel/[email protected] 
│ ├─┬ [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ ├─┬ [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │   ├── [email protected] 
│ │ │ │ │   └── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ ├── [email protected] 
│ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │   └── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │ │   ├── [email protected] 
│ │ │ │ │ │   └── [email protected] 
│ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ └── [email protected] 
│ │ │ │ │ └── [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ └── [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ └── [email protected] 
│ │ │ └─┬ [email protected] 
│ │ │   └── [email protected] 
│ │ ├── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ ├── [email protected] 
│ │ │ ├── [email protected] 
│ │ │ ├─┬ [email protected] 
│ │ │ │ └── [email protected] 
│ │ │ ├─┬ [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │   └── [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ └── [email protected] 
│ │ │ ├── [email protected] 
│ │ │ ├── [email protected] 
│ │ │ ├─┬ [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ │ └── [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │ │ │   └── [email protected] 
│ │ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ │ └── [email protected] 
│ │ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ │ └── [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │ │   └─┬ [email protected] 
│ │ │ │ │ │     ├── [email protected] 
│ │ │ │ │ │     └── [email protected] 
│ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │ │   ├── [email protected] 
│ │ │ │ │ │   └─┬ [email protected] 
│ │ │ │ │ │     ├── [email protected] 
│ │ │ │ │ │     ├── [email protected] 
│ │ │ │ │ │     └── [email protected] 
│ │ │ │ │ ├── [email protected] 
│ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │ │   ├── [email protected] 
│ │ │ │ │ │   └── [email protected] 
│ │ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ │ ├── [email protected] 
│ │ │ │ │ │ └── [email protected] 
│ │ │ │ │ └── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ └── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │   ├─┬ [email protected] 
│ │ │ │ │   │ └── [email protected] 
│ │ │ │ │   ├─┬ [email protected] 
│ │ │ │ │   │ └── [email protected] 
│ │ │ │ │   └── [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ ├── [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ ├── [email protected] 
│ │ │ │ │ ├── [email protected] 
│ │ │ │ │ ├── [email protected] 
│ │ │ │ │ ├── [email protected] 
│ │ │ │ │ └── [email protected] 
│ │ │ │ └── [email protected] 
│ │ │ ├─┬ [email protected] 
│ │ │ │ ├─┬ [email protected] 
│ │ │ │ │ └─┬ [email protected] 
│ │ │ │ │   ├── [email protected] 
│ │ │ │ │   └── [email protected] 
│ │ │ │ └─┬ [email protected] 
│ │ │ │   └── [email protected] 
│ │ │ ├── [email protected] 
│ │ │ └─┬ [email protected] 
│ │ │   └─┬ [email protected] 
│ │ │     └── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ ├── [email protected] 
│ │ │ └── [email protected] 
│ │ ├── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ └── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ └── [email protected] 
│ │ ├── [email protected] 
│ │ ├── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ ├── [email protected] 
│ │ │ └─┬ [email protected] 
│ │ │   ├── [email protected] 
│ │ │   ├── [email protected] 
│ │ │   ├── [email protected] 
│ │ │   ├── [email protected] 
│ │ │   └── [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├─┬ [email protected] 
│ │ ├── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ └── [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ └─┬ [email protected] 
│ │ │   ├── [email protected] 
│ │ │   └── [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ └── [email protected] 
├─┬ @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └─┬ @babel/[email protected] 
│ │   ├─┬ [email protected] 
│ │   │ ├─┬ [email protected] 
│ │   │ │ └─┬ [email protected] 
│ │   │ │   └── [email protected] 
│ │   │ ├── [email protected] 
│ │   │ └─┬ [email protected] 
│ │   │   └── [email protected] 
│ │   └── [email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └── [email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ ├─┬ [email protected] 
│ │ │ └── [email protected] 
│ │ └── [email protected] 
│ ├─┬ @babel/[email protected] 
│ │ ├── [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ └── [email protected] 
├─┬ @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └─┬ @babel/[email protected] 
│ │   └── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └─┬ @babel/[email protected] 
│ │   └─┬ [email protected] 
│ │     ├── [email protected] 
│ │     ├── [email protected] 
│ │     ├── [email protected] 
│ │     ├─┬ [email protected] 
│ │     │ └── [email protected] 
│ │     ├─┬ [email protected] 
│ │     │ ├── [email protected] 
│ │     │ └── [email protected] 
│ │     └── [email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ └─┬ @babel/[email protected] 
│ │   └── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └─┬ @babel/[email protected] 
│ │   └── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ └─┬ [email protected] 
│ │   └─┬ [email protected] 
│ │     ├── [email protected] 
│ │     ├── [email protected] 
│ │     ├── [email protected] 
│ │     └── [email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ ├── @babel/[email protected] 
│ │ └── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └─┬ [email protected] 
│ │   └── [email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ @babel/[email protected] 
│ │ └── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├── @babel/[email protected] 
│ ├─┬ [email protected] 
│ │ ├── [email protected] 
│ │ ├── [email protected] 
│ │ └─┬ [email protected] 
│ │   └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ └─┬ [email protected] 
│   └── [email protected] 
├─┬ [email protected] 
│ ├── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ ├── [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├─┬ [email protected] 
│ │ ├── [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ └── [email protected] 
├─┬ [email protected] 
│ ├─┬ [email protected] 
│ │ ├─┬ [email protected] 
│ │ │ └── [email protected] 
│ │ └── [email protected] 
│ ├─┬ [email protected] 
│ │ └── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ ├── [email protected] 
│ └─┬ [email protected] 
│   ├── [email protected] 
│   └── [email protected] 
└── [email protected] 

npm WARN optional Skipping failed optional dependency /chokidar/fsevents:
npm WARN notsup Not compatible with your operating system or architecture: [email protected]
npm WARN enoent ENOENT: no such file or directory, open '/home/jgaluska/develop/esp32/esphttpd-freertos/build/espfs/package.json'
npm WARN espfs No description
npm WARN espfs No repository field.
npm WARN espfs No README data
npm WARN espfs No license field.
Traceback (most recent call last):
  File "/home/jgaluska/develop/esp32/esphttpd-freertos/components/espfs/tools/build-image.py", line 36, in <module>
    os.mkdir(dest)
TypeError: mkdir: illegal type for path parameter
/home/jgaluska/develop/esp32/esphttpd-freertos/components/espfs/component.mk:70: recipe for target 'espfs_image.bin' failed
make[1]: *** [espfs_image.bin] Error 1
/home/jgaluska/esp-idf/make/project.mk:590: recipe for target 'component-espfs-build' failed
make: *** [component-espfs-build] Error 2

OTA update over WiFi not stable

An OTA update seems to fail 50% of the time when performed over WiFi. It almost never fails via Ethernet.

Usually the WiFi connection to the esp AP disappears from my phone, then my phone tries to connect to another AP. So it seems the WiFi is unstable during the flashing process.
Has anyone else experienced this?

Perhaps it can be improved by yielding more time from the flash operation to the WiFi functions?

Cannot Build - try_compile command is not scriptable

I get this as soon as I try and build;

    Syntax error in cmake code at
      C:/VSCode/Projects/esphttpd-freertos/build/build_properties.temp.cmake:2
    when parsing string
      C:\Python\python.exe
    Invalid escape sequence \P

In the temp file I see;

set(PYTHON C:\Python\python.exe)
set(IDF_PATH c:/vscode/sdk/esp8266/esp8266_rtos_sdk)

How can I get this script to use double backslashes or a forward slash? This should be mandatory in the build script to catch Windows environments

Large filesystem issue with esp_partition_mmap

Hi there,

I'm trying to separate the webpage data into a different 8MB partition. I sadly running into the same problem with the size of the filesystem (ESP_ERR_NO_MEM) than in following topic:
espressif/esp-idf#1184

Does anyone has a workaround for this or are there any examples available for how to adapt a SPIFFS fs with the esphttpd-freertos example?
Thanks,

Example not working

Hello, using latest esp-idf and latest libesphttpd this example does nothing, monitor says everything is ok, but trying to connect via browser or telnet, 80 port is timing out. Monitor:

I (0) cpu_start: App cpu up.
I (374) heap_init: Initializing. RAM available for dynamic allocation:
I (381) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM
I (387) heap_init: At 3FFD2C18 len 0000D3E8 (52 KiB): DRAM
I (393) heap_init: At 3FFE0440 len 00003BC0 (14 KiB): D/IRAM
I (399) heap_init: At 3FFE4350 len 0001BCB0 (111 KiB): D/IRAM
I (406) heap_init: At 400903D8 len 0000FC28 (63 KiB): IRAM
I (412) cpu_start: Pro cpu start user code
I (95) cpu_start: Starting scheduler on PRO CPU.
I (0) cpu_start: Starting scheduler on APP CPU.
I (97) httpd-freertos: address 0.0.0.0, port 80, maxConnections 32, mode non-ssl

I (97) httpd-freertos: init
I (127) wifi: wifi driver task: 3ffda44c, prio:23, stack:3584, core=0
I (137) wifi: wifi firmware version: 4c398ce
I (137) wifi: config NVS flash: enabled
I (137) wifi: config nano formating: disabled
I (137) system_api: Base MAC address is not set, read default base MAC address f
rom BLK0 of EFUSE
I (147) system_api: Base MAC address is not set, read default base MAC address f
rom BLK0 of EFUSE
I (187) wifi: Init dynamic tx buffer num: 32
I (187) wifi: Init data frame dynamic rx buffer num: 32
I (187) wifi: Init management frame dynamic rx buffer num: 32
I (187) wifi: Init static rx buffer size: 1600
I (197) wifi: Init static rx buffer num: 10
I (197) wifi: Init dynamic rx buffer num: 32
E (207) wifi: esp_wifi_disconnect 943 wifi not start
I (267) phy: phy_version: 3910, c0c45a3, May 21 2018, 18:07:06, 0, 0
I (267) wifi: mode : softAP (24:0a:c4:81:5f:75)

Ready
I (277) user_main: ~~~~~~~~~~~
I (277) user_main: IP:192.168.4.1
I (277) user_main: MASK:255.255.255.0
I (277) user_main: GW:192.168.4.1
I (287) user_main: ~~~~~~~~~~~
I (21377) wifi: n:1 1, o:1 0, ap:1 1, sta:255 255, prof:1
I (21377) wifi: station: c0:4a:00:12:6f:8f join, AID=1, bgn, 40U
I (21377) user_main: station:c0:4a:00:12:6f:8f join,AID=1

I (21467) tcpip_adapter: softAP assign IP to station,IP is: 192.168.4.2

Loading Partitions Info Table Not Working

Hi,
I am using ESP-IDF v4.1, the application compiles and flashes correctly, however selecting perform OTA firmware does nothing, it does not display the partitions table, nor does it accept to reboot!
Apperantly the cgiGetFlashInfo is not called due to bad java script in html file, cannot read localStorage!

Thanks,

git clone fails for project

Trying to run git clone, I get the following; any suggestions? Similar error on Linux. Thanks.

"C:\Program Files (x86)\Git\bin\git.exe" clone -v --recurse-submodules --progress "https://github.com/chmorgan/esphttpd-freertos.git" "c:/dev/esphttpd-freertos"
Cloning into 'c:/dev/esphttpd-freertos'...
POST git-upload-pack (175 bytes)
remote: Enumerating objects: 25, done.
remote: Counting objects: 100% (25/25), done.
remote: Compressing objects: 100% (23/23), done.
remote: Total 227 (delta 7), reused 14 (delta 2), pack-reused 202Receiving ob
Receiving objects: 100% (227/227), 189.25 KiB | 1.32 MiB/s, done.
Resolving deltas: 100% (101/101), done.
Submodule 'components/espfs' (https://github.com/jkent/esp32-espfs.git) registered for path 'components/espfs'
Submodule 'components/libesphttpd' (https://github.com/chmorgan/libesphttpd.git) registered for path 'components/libesphttpd'
Cloning into 'C:/dev/esphttpd-freertos/components/espfs'...
remote: Enumerating objects: 50, done.
remote: Counting objects: 100% (50/50), done.
remote: Compressing objects: 100% (38/38), done.
remote: Total 50 (delta 17), reused 43 (delta 11), pack-reused 0
Cloning into 'C:/dev/esphttpd-freertos/components/libesphttpd'...
remote: Enumerating objects: 15, done.
remote: Counting objects: 100% (15/15), done.
remote: Compressing objects: 100% (10/10), done.
remote: Total 2749 (delta 5), reused 11 (delta 5), pack-reused 2734
Receiving objects: 100% (2749/2749), 1011.39 KiB | 595.00 KiB/s, done.
Resolving deltas: 100% (1861/1861), done.
Submodule path 'components/espfs': checked out 'b87f89adcda2d15c60f078b9dcc20dea3fcbd116'
Submodule 'heatshrink' (https://github.com/atomicobject/heatshrink.git) registered for path 'components/espfs/heatshrink'
Cloning into 'C:/dev/esphttpd-freertos/components/espfs/heatshrink'...
remote: Enumerating objects: 442, done.
remote: Total 442 (delta 0), reused 0 (delta 0), pack-reused 442
Receiving objects: 100% (442/442), 177.36 KiB | 532.00 KiB/s, done.
Resolving deltas: 100% (264/264), done.
Submodule path 'components/espfs/heatshrink': checked out 'ffd95059ff9155fa373b3e6276854db3ad7b4e3c'
error: Server does not allow request for unadvertised object 587d987efa5ab2473cf1e61c0e6f7a93cfce1f67
Fetched in submodule path 'components/libesphttpd', but it did not contain 587d987efa5ab2473cf1e61c0e6f7a93cfce1f67. Direct fetching of that commit failed.
Done

Syntax error in cmake code at when parsing string Invalid escape sequence \d

I used the 4.0 esp idf with python 3.8 at windows 10 with visual studio code:

`Make Error at C:/dev/ESP32/esp-idf/esp-idf/tools/cmake/component.cmake:222 (message):
CMake Warning (dev) at build_properties.temp.cmake:2 (set):

Syntax error in cmake code at



  C:/dev/ESP32/esphttpd-freertos/build/bootloader/build_properties.temp.cmake:2



when parsing string



  c:\dev\ESP32\tools\python_env\idf4.0_py3.8_env\Scripts\python.exe



Invalid escape sequence \d



Policy CMP0010 is not set: Bad variable reference syntax is an error.  Run
"cmake --help-policy CMP0010" for policy details.  Use the cmake_policy
command to set the policy and suppress this warning.

Call Stack (most recent call first):

C:/dev/ESP32/esp-idf/esp-idf/tools/cmake/scripts/component_get_requirements.cmake:1 (include)

This warning is for project developers. Use -Wno-dev to suppress it.

CMake Error at
C:/dev/ESP32/tools/tools/cmake/3.13.4/share/cmake-3.13/Modules/CheckCSourceCompiles.cmake:98
(try_compile):

try_compile command is not scriptable

Call Stack (most recent call first):

C:/dev/ESP32/tools/tools/cmake/3.13.4/share/cmake-3.13/Modules/CheckCCompilerFlag.cmake:50 (CHECK_C_SOURCE_COMPILES)
C:/dev/ESP32/esp-idf/esp-idf/components/libesphttpd/CMakeLists.txt:8 (check_c_compiler_flag)
C:/dev/ESP32/esp-idf/esp-idf/components/libesphttpd/CMakeLists.txt:15 (enable_c_compiler_flag_if_supported)
C:/dev/ESP32/esp-idf/esp-idf/tools/cmake/scripts/component_get_requirements.cmake:60 (include)
C:/dev/ESP32/esp-idf/esp-idf/tools/cmake/scripts/component_get_requirements.cmake:76 (__component_get_requirements)

Call Stack (most recent call first):
C:/dev/ESP32/esp-idf/esp-idf/tools/cmake/build.cmake:404 (__component_get_requirements)
C:/dev/ESP32/esp-idf/esp-idf/tools/cmake/project.cmake:348 (idf_build_process)
CMakeLists.txt:27 (project)

-- Configuring incomplete, errors occurred!
See also "C:/dev/ESP32/esphttpd-freertos/build/bootloader/CMakeFiles/CMakeOutput.log".
[76/274] Building C object esp-idf/newlib/CMakeFiles/__idf_newlib.dir/time.c.obj
ninja: build stopped: subcommand failed.

PlatformIO can not compile espfs_image.c not found

Hi I am trying to compile your example code in platformio and get the following error
Compiling .pio\build\esp32doit-devkit-v1\esp-idf\espfs\src\espfs.c.o
*** [.pio\build\esp32doit-devkit-v1.pio\build\esp32doit-devkit-v1\esp-idf\espfs\src\espfs_image.c.o] Source .pio\build\esp32doit-devkit-v1\esp-idf\espfs\src\espfs_image.c' not found, needed by target .pio\build\esp32doit-devkit-v1.pio\build\esp32doit-devkit-v1\esp-idf\espfs\src\espfs_image.c.o'.

I have no idea what that means and how to fix it, some guidance would be greatly appreciated

Assertion failure when switching to station only mode

There is an assertion failure on line 284 in file main/user_main.c when ever attempting to switch to standalone STA mode. This issue is seen in git commit #ffffd5c.

Instructions to reproduce:

  1. On an ESP32, Checkout, compile, flash, and monitor version #ffffd5c.
  2. Connect to the 'ESP' WiFi AP, browse to http://192.168.4.1, and select 'Configure your WIFI Network' option.
  3. Click on the 'Go to AP+STA mode' button. Wait for the screen to refresh.
  4. Enter your SSID (or click the scan button and select your SSID), enter your password, and click on the 'Connect!' button. After the screen has changed, click on the 'here' button to use the ESP's new IP address.
  5. Re-select 'Configure your WIFI Network' option.
  6. Click on the "Go to standalone STA mode' button, The esp will assert on line 284 in file main/user_main.c

Additional Information:
Modifying line 284 from:

ESP_ERROR_CHECK( esp_wifi_ap_get_sta_list(&sta_list));

to

esp_wifi_ap_get_sta_list(&sta_list);

apparently makes the software work, but I am too new to this project to know if this is the correct way to fix this issue.

Also, the error return from function esp_wifi_ap_get_sta_list is ESP_ERR_WIFI_MODE (0x305) and
sta_list.num is equal to 1 upon this functions return.

Build of the project for ESP32/EPS8266 - comments

There are a couple of comments on build the project

Initialization of submodules.

After cloning the repository and initializing the submodules:

git submodule update --init --recursive

There are no latest commits in the "espfs" and "libesphttpd" submodules (this can be seen by looking at the log of the submodules), so the project not build. If updating submodules from remote:

git submodule update --init --recursive --remote

The latest commits appear in the "espfs" and "libesphttpd" submodules. But a build error occurs on the "heatshrink" submodule. To get the necessary commits in all submodules, needed to run two commands:

git submodule update --init --recursive
git submodule update --remote

After such initialization, the project for ESP32 ESP-IDF (master) is built without problems.

Build the project for ESP8266.

I managed to build and run this project for ESP8266 ESP8266_RTOS_SDK (master). But it was necessary to change the code of the project and the submodules "espfs", "libesphttpd". As I understand it, the old SDK was used for the ESP8266.
For example, in the file "components/libesphttpd/include/libesphttpd/esp.h":

#ifdef ESP_PLATFORM // only set in esp-idf
#define FREERTOS 1
#define ESP32 1
...

The assumption that "ESP_PLATFORM" declared only in ESP-IDF is not true.
For which version of the ESP8266 SDK is a project build expected?

STA Mode problem

After flashing the firmware, I can successfully connect to 192.168.4.1, associate the ESP to my WiFi network. All the pages work.

If I switch to STA Mode only and reboot, I can no longer ping the ESP.

I am using esp-idf v4.0

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.