10000 WEBSOCKETS_NETWORK_TYPE exteral definition · NodeMCU-Zero/arduinoWebSockets@7361e2b · GitHub
[go: up one dir, main page]

Skip to content

Commit 7361e2b

Browse files
WEBSOCKETS_NETWORK_TYPE exteral definition
Making possible to define WEBSOCKETS_NETWORK_TYPE as a compile parameter.
1 parent 1961ddc commit 7361e2b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/WebSockets.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,15 @@
5252
// max size of the WS Message Header
5353
#define WEBSOCKETS_MAX_HEADER_SIZE (14)
5454

55+
#if !defined(WEBSOCKETS_NETWORK_TYPE)
5556
// select Network type based
5657
#if defined(ESP8266) || defined(ESP31B)
5758
#define WEBSOCKETS_NETWORK_TYPE NETWORK_ESP8266
5859
//#define WEBSOCKETS_NETWORK_TYPE NETWORK_ESP8266_ASYNC
5960
#else
6061
#define WEBSOCKETS_NETWORK_TYPE NETWORK_W5100
6162
#endif
63+
#endif
6264

6365
#if (WEBSOCKETS_NETWORK_TYPE == NETWORK_ESP8266_ASYNC)
6466

0 commit comments

Comments
 (0)
0