Skip to content
This repository has been archived by the owner on Feb 4, 2023. It is now read-only.

Commit

Permalink
v2.1.3 not to reconnect after connected
Browse files Browse the repository at this point in the history
### Releases v2.1.3

1. Not try to reconnect to the same host:port after connected. Check [setReuse feature #12](#12)
  • Loading branch information
khoih-prog authored Oct 18, 2022
1 parent 0935d6f commit d100dde
Show file tree
Hide file tree
Showing 15 changed files with 98 additions and 75 deletions.
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ Please ensure to specify the following:
Arduino IDE version: 1.8.19
ESP32 Core Version 2.0.5
OS: Ubuntu 20.04 LTS
Linux xy-Inspiron-3593 5.15.0-46-generic #49~20.04.1-Ubuntu SMP Thu Aug 4 19:15:44 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
Linux xy-Inspiron-3593 5.15.0-50-generic #56~20.04.1-Ubuntu SMP Tue Sep 27 15:51:29 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
Context:
I encountered an endless loop while trying to connect to Local WiFi.
I encountered a crash when using this library
Steps to reproduce:
1. ...
Expand Down
6 changes: 6 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
## Table of Contents

* [Changelog](#changelog)
* [Releases v2.1.3](#releases-v213)
* [Releases v2.1.2](#releases-v212)
* [Releases v2.1.1](#releases-v211)
* [Releases v2.1.0](#releases-v210)
Expand All @@ -30,6 +31,11 @@

## Changelog

### Releases v2.1.3

1. Not try to reconnect to the same host:port after connected. Check [setReuse feature #12](https://github.com/khoih-prog/AsyncHTTPSRequest_Generic/issues/12)


### Releases v2.1.2

1. Fix bug
Expand Down
6 changes: 3 additions & 3 deletions examples/AsyncHTTPSRequest_ESP/AsyncHTTPSRequest_ESP.ino
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@
#error This code is intended to run on the ESP8266 or ESP32 platform! Please check your Tools->Board setting.
#endif

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.3"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001003

// Level from 0-4
#define ASYNC_HTTPS_DEBUG_PORT Serial

#define _ASYNC_TCP_SSL_LOGLEVEL_ 1
#define _ASYNC_HTTPS_LOGLEVEL_ 2
#define _ASYNC_HTTPS_LOGLEVEL_ 1

// 300s = 5 minutes to not flooding
#define HTTPS_REQUEST_INTERVAL 60 //300
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@
#error This code is intended to run on the ESP8266 or ESP32 platform! Please check your Tools->Board setting.
#endif

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.3"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001003

// Level from 0-4
#define ASYNC_HTTPS_DEBUG_PORT Serial

#define _ASYNC_TCP_SSL_LOGLEVEL_ 1
#define _ASYNC_HTTPS_LOGLEVEL_ 2
#define _ASYNC_HTTPS_LOGLEVEL_ 3

// 300s = 5 minutes to not flooding
#define HTTPS_REQUEST_INTERVAL 60 //300
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,11 @@
#error This code is intended to run on the ESP8266 or ESP32 platform! Please check your Tools->Board setting.
#endif

#define ESP_ASYNC_WIFIMANAGER_VERSION_MIN_TARGET "ESPAsync_WiFiManager v1.14.1"
#define ESP_ASYNC_WIFIMANAGER_VERSION_MIN 1014001
#define ESP_ASYNC_WIFIMANAGER_VERSION_MIN_TARGET "ESPAsync_WiFiManager v1.15.0"
#define ESP_ASYNC_WIFIMANAGER_VERSION_MIN 1015000

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.3"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001003

/////////////////////////////////////////////////////////

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@
#error This code is intended to run on the ESP8266 or ESP32 platform! Please check your Tools->Board setting.
#endif

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.3"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001003

#define ASYNC_HTTP_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPRequest_Generic v1.9.1"
#define ASYNC_HTTP_REQUEST_GENERIC_VERSION_MIN 1009001
Expand All @@ -64,8 +64,10 @@

int status; // the Wifi radio's status

const char* ssid = "your_ssid";
const char* password = "your_pass";
const char* ssid = "HueNet1";
const char* password = "jenniqqs";
//const char* ssid = "your_ssid";
//const char* password = "your_pass";

#if (ESP8266)
#include <ESP8266WiFi.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@
#error This code is intended to run on the ESP32 platform! Please check your Tools->Board setting.
#endif

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.3"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001003
/////////////////////////////////////////////////////////

// Use larger queue size if necessary for large data transfer. Default is 512 bytes if not defined here
Expand Down
4 changes: 2 additions & 2 deletions examples/multiFileProject/multiFileProject.ino
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
#error This code is intended to run on the ESP32 platform! Please check your Tools->Board setting.
#endif

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN_TARGET "AsyncHTTPSRequest_Generic v2.1.3"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MIN 2001003

#include "multiFileProject.h"

Expand Down
4 changes: 2 additions & 2 deletions library.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name":"AsyncHTTPSRequest_Generic",
"version": "2.1.2",
"version": "2.1.3",
"description":"Simple Async HTTPS Request library, supporting GET, POST, PUT, PATCH, DELETE and HEAD, on top of AsyncTCP_SSL library for ESP32 (including ESP32_S2, ESP32_S3 and ESP32_C3), WT32_ETH01 (ESP32 + LAN8720). Supporting in the future for RP2040W, ESP8266, Portenta_H7, STM32 with built-in LAN8742A Ethernet, etc. Now you can send HTTP / HTTPS requests to multiple addresses and receive responses from them.",
"keywords":"communication, async, tcp, https, ssl, tls, ESP8266, ESP32, ESP32-S2, wt32-eth01, ESPAsyncTCP, AsyncTCP, stm32, ethernet, wifi, lan8742a, lan8720, f407ve, nucleo-144, stm32f7",
"authors": [
Expand Down Expand Up @@ -51,7 +51,7 @@
{
"owner": "khoih-prog",
"name": "ESPAsync_WiFiManager",
"version": ">=1.14.1",
"version": ">=1.15.0",
"platforms": ["espressif8266", "espressif32"]
}
],
Expand Down
4 changes: 2 additions & 2 deletions library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=AsyncHTTPSRequest_Generic
version=2.1.2
version=2.1.3
author=Bob Lemaire,Khoi Hoang <khoih.prog@gmail.com>
maintainer=Khoi Hoang <khoih.prog@gmail.com>
license=GPLv3
Expand All @@ -8,5 +8,5 @@ paragraph=Supporting in the future for RP2040W, ESP8266, Portenta_H7, STM32 with
category=Communication
url=https://github.com/khoih-prog/AsyncHTTPSRequest_Generic
architectures=*
depends=AsyncTCP_SSL, WebServer_WT32_ETH01, AsyncHTTPRequest_Generic
depends=AsyncTCP_SSL, WebServer_WT32_ETH01, AsyncHTTPRequest_Generic, ESPAsync_WiFiManager
includes=AsyncHTTPSRequest_Generic.h,AsyncHTTPSRequest_Generic.hpp
4 changes: 2 additions & 2 deletions platformio/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@ lib_deps =
; AsyncTCP_SSL@>=1.3.1
; AsyncHTTPRequest_Generic@>=1.9.1
; WebServer_WT32_ETH01@>=1.5.1
; ESPAsync_WiFiManager@>=1.14.1
; ESPAsync_WiFiManager@>=1.15.0
; PlatformIO 5.x
khoih-prog/AsyncTCP_SSL@>=1.3.1
khoih-prog/AsyncHTTPRequest_Generic@>=1.9.1
khoih-prog/WebServer_WT32_ETH01@>=1.5.1
khoih-prog/ESPAsync_WiFiManager@>=1.14.1
khoih-prog/ESPAsync_WiFiManager@>=1.15.0


build_flags =
Expand Down
3 changes: 2 additions & 1 deletion src/AsyncHTTPSRequest_Debug_Generic.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
You should have received a copy of the GNU General Public License along with this program.
If not, see <https://www.gnu.org/licenses/>.
Version: 2.1.2
Version: 2.1.3
Version Modified By Date Comments
------- ----------- ---------- -----------
Expand All @@ -33,6 +33,7 @@
2.1.0 K Hoang 30/08/2022 Fix bug. Improve debug messages. Optimize code
2.1.1 K Hoang 09/09/2022 Fix ESP32 chipID for example `AsyncHTTPSRequest_ESP_WiFiManager`
2.1.2 K Hoang 18/09/2022 Fix bug and compiler error in some cases
2.1.3 K Hoang 18/10/2022 Not try to reconnect to the same host:port after connected
*****************************************************************************************************************************/

#pragma once
Expand Down
3 changes: 2 additions & 1 deletion src/AsyncHTTPSRequest_Generic.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
You should have received a copy of the GNU General Public License along with this program.
If not, see <https://www.gnu.org/licenses/>.
Version: 2.1.2
Version: 2.1.3
Version Modified By Date Comments
------- ----------- ---------- -----------
Expand All @@ -33,6 +33,7 @@
2.1.0 K Hoang 30/08/2022 Fix bug. Improve debug messages. Optimize code
2.1.1 K Hoang 09/09/2022 Fix ESP32 chipID for example `AsyncHTTPSRequest_ESP_WiFiManager`
2.1.2 K Hoang 18/09/2022 Fix bug and compiler error in some cases
2.1.3 K Hoang 18/10/2022 Not try to reconnect to the same host:port after connected
*****************************************************************************************************************************/

#pragma once
Expand Down
9 changes: 5 additions & 4 deletions src/AsyncHTTPSRequest_Generic.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
You should have received a copy of the GNU General Public License along with this program.
If not, see <https://www.gnu.org/licenses/>.
Version: 2.1.2
Version: 2.1.3
Version Modified By Date Comments
------- ----------- ---------- -----------
Expand All @@ -33,6 +33,7 @@
2.1.0 K Hoang 30/08/2022 Fix bug. Improve debug messages. Optimize code
2.1.1 K Hoang 09/09/2022 Fix ESP32 chipID for example `AsyncHTTPSRequest_ESP_WiFiManager`
2.1.2 K Hoang 18/09/2022 Fix bug and compiler error in some cases
2.1.3 K Hoang 18/10/2022 Not try to reconnect to the same host:port after connected
*****************************************************************************************************************************/

#pragma once
Expand All @@ -44,13 +45,13 @@
#error This AsyncHTTPSRequest library is currently supporting only ESP32
#endif

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION "AsyncHTTPSRequest_Generic v2.1.2"
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION "AsyncHTTPSRequest_Generic v2.1.3"

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MAJOR 2
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_MINOR 1
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_PATCH 2
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_PATCH 3

#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_INT 2001002
#define ASYNC_HTTPS_REQUEST_GENERIC_VERSION_INT 2001003

#include <Arduino.h>

Expand Down
Loading

0 comments on commit d100dde

Please sign in to comment.