2021-06-21 13:11:24 +02:00
|
|
|
Hardware Timer didnt work https://github.com/khoih-prog/ESP8266TimerInterrupt#why-using-isr-based-hardware-timer-interrupt-is-better
|
2021-06-22 17:22:00 +02:00
|
|
|
|
2021-06-21 13:11:24 +02:00
|
|
|
=> Software Timer https://ullisroboterseite.de/esp8266-timing.html#timer
|
|
|
|
|
2021-06-22 20:25:27 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### __Zum aktivieren von GDBStub:__
|
|
|
|
```c
|
|
|
|
#include <GDBStub.h>
|
|
|
|
|
|
|
|
...
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
Serial.begin(460800);
|
|
|
|
gdbstub_init();
|
|
|
|
```
|
|
|
|
|
|
|
|
### __Achtung !__
|
|
|
|
GDB muss dafür compiled werden
|
|
|
|
GDB-Version aus Arduino Toolchain hat Support
|
|
|
|
|
|
|
|
```sh
|
|
|
|
$ ./start_xtensa_gdb_stub.sh
|
2021-06-23 01:30:28 +02:00
|
|
|
```
|
|
|
|
|
|
|
|
### __Achtung !__
|
|
|
|
Don`t forget __\r__
|
|
|
|
|
|
|
|
ESP-OTA wird von ufw oder Defender geblockt.
|
|
|
|
- Windows -> Python needs to be granted with rights
|
|
|
|
- Linux -> open udp port in ufw ->
|
|
|
|
|
|
|
|
```sh
|
|
|
|
platform.ini
|
|
|
|
upload_flags =
|
|
|
|
--host-port <PORT>
|
|
|
|
...
|
|
|
|
$ sudo ufw allow tcp/<PORT>
|
2021-06-23 02:13:48 +02:00
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
```c++
|
|
|
|
server.streamFile(f, mime::getContentType(SRH::_path), requestMethod);
|
|
|
|
|
|
|
|
=====>
|
|
|
|
|
|
|
|
const String& p = SRH::_path;
|
|
|
|
if(p.endsWith(".gzip")) {
|
|
|
|
server.sendHeader("Content-Encoding", "gzip");
|
|
|
|
server.streamFile(f, mime::getContentType(p.substring(0, p.length()-5)), requestMethod);
|
|
|
|
}
|
|
|
|
else
|
|
|
|
server.streamFile(f, mime::getContentType(SRH::_path), requestMethod);
|
2021-06-23 16:49:53 +02:00
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
Webserver on v0.3.0 now working with LittleFS
|
|
|
|
TODO:
|
|
|
|
- check dir for files automatic
|
|
|
|
- move handleNotFound to httpserver.h
|
|
|
|
- maybe compress files ?
|
|
|
|
|