152 Commits

Author SHA1 Message Date
MaBecker
ae3a89f31a ESP8266: Remove osprintf for RELEASE 2017-09-15 10:40:17 +02:00
MaBecker
94031dbc65 ESP8266: move code save section to fist partition for memory mapping (fix #1240)
only fist partition is memory mapped
2017-09-14 21:54:29 +02:00
Standa Opichal
aa75f14ebb Disable startMDNS() in favor of mDNS.js
Without this the esp8266 uses the mdns port 5353 and silently ignores
any message to be received mDNS.js.
2017-08-25 23:49:43 +02:00
Standa Opichal
f3378c4a8d Added size to UDP buf header.
This is in order to be able to call several socket.send() calls
to different targets synchronously.

The format changed to host/32:port/16:size/16:[data/??].
2017-08-25 23:49:03 +02:00
Standa Opichal
54412b268a SocketType parameters in net->send/recv/createsocket
And also in their callers (netSend/Recv/CreateSocket).
2017-08-25 23:48:18 +02:00
Standa Opichal
1b139eb547 UDP host:port embedded in send/recv buf 2017-08-25 23:48:18 +02:00
Standa Opichal
ae79c96cd3 Drop big UDP packets for esp8266
This proved to be the cure for stalling the 8266 and allowed
the chip to successfully answer .local queries for more than
a day on a local network where some of the mDNS packets are
more than 1kB long.
2017-08-25 23:48:18 +02:00
Standa Opichal
bc3d4cbb46 Passing addMembership() args to net.createsocket
Limited to a single membership, handled in target specific createsocket
which is provided with the 'options' object to get multicastGroup and
multicastIp from. Also due to the way the arguments are passed to the
net.createsocket the socket.addMembership() needs to be called before
socket.bind().

Added SO_REUSEPORT so that binding e.g. to mDNS port 5353 is possible
on an osx machine.
2017-08-25 23:48:18 +02:00
Standa Opichal
5ae2923909 Working UDP on esp8266 target 2017-08-25 23:48:18 +02:00
Standa Opichal
df54f21935 Introduced SocketType ST_UDP
Initial attempt only, able to send UDP data using socket.write().
2017-08-25 23:48:18 +02:00
MaBecker
ffbc6bd8f4 fix issue #753 2017-07-21 14:46:11 +02:00
MaBecker
fdda1059c5 fix issue #1037
fix found by @iotong
2017-07-21 12:41:59 +02:00
Standa Opichal
bb13604e6b Added SocketType argument to net->createsocket() method. 2017-06-23 22:51:56 +02:00
Gordon Williams
c09739f663 Remove duplicate JSON code and WiFi functions in reference, fix #1155 2017-04-29 19:02:51 +01:00
MaBecker
7bc5093fca update ESP8266_4MB.py plus dependencies 2017-04-17 10:02:04 +02:00
MaBecker
ca820c353a update ESP8266_4MB 2017-04-16 21:22:59 +02:00
MaBecker
81204d6b15 use 0x200000 as save section and 0x300000 as flash section 2017-02-27 22:42:46 +01:00
MaBecker
6421b97f5e add save areas for FLASH_4MB_C1 2017-02-27 07:50:56 +01:00
MaBecker
096b745764 add type cases to get ride of compiler warnings 2017-02-26 22:20:37 +01:00
Gordon Williams
7be1ecf6ed Merge pull request #1032 from MaBecker/patch-1
set WIFI_DBG 0  if def RELEASE
2017-01-26 11:14:14 +00:00
Gordon Williams
ddc607b5db Merge pull request #1033 from MaBecker/patch-2
set NET_DBG 0 if def RELEASE
2017-01-25 08:58:57 +00:00
MaBecker
eabffa4032 add setIP and setAPIP 2017-01-24 14:19:46 +00:00
MaBecker
7c5c9b9004 set NET_DBG 0 if def RELEASE
do not include NET debug statements when using RELEASE=1
2017-01-23 23:28:07 +01:00
MaBecker
ee8463da9a set WIFI_DBG 0 if def RELEASE
do not include Wifi  debug statements when using RELEASE=1
2017-01-23 22:30:06 +01:00
Standa Opichal
28f5c403f7 Make sntpSync use setTime() not to break setInterval()
The setTime() properly sets the jsiLastIdleTime which is used
in the _jswrap_interface_setTimeoutOrInterval to trigger timers.

Update the time only when the mDNS returns non-null value.
2017-01-21 22:14:33 +01:00
Thorsten von Eicken
38c368422e update travis.yaml for esp8266; update readme_flash; fix #901 2016-09-16 23:33:15 -07:00
Thorsten von Eicken
8eec73937a support new esp8266 binary format and check partition on OTA upgrade 2016-09-16 23:19:58 -07:00
Thorsten von Eicken
c7cd61c59b fix ping on esp8266 2016-07-08 00:55:26 -07:00
Thorsten von Eicken
2c8c866f1b esp8266: exception code cleanup; jswsym code cleanup; eliminate compiler warnings 2016-04-17 09:46:32 -07:00
Thorsten von Eicken
4493b09eef fix esp8266 compiler warnings 2016-04-17 08:46:08 -07:00
Gordon Williams
5dd5d901d1 replace NewWithFlags with jsvNewXXX - saves a few bytes by killing repetition 2016-03-04 12:54:18 +00:00
Thorsten von Eicken
7eb6c66d90 fix #809 esp8266 socket close 2016-02-26 00:02:32 -08:00
Thorsten von Eicken
f35ac96f29 fix socket unsent data error; update esp8266 socket tests 2016-01-18 10:39:45 -08:00
Thorsten von Eicken
02ee106f97 tweaks after esp8266 improvements 2016-01-17 17:47:51 -08:00
Thorsten von Eicken
528630211c merge upstream in to esp8266 fork 2016-01-17 17:26:21 -08:00
Gordon Williams
34326d03b9 Allow different types of network to have different buffer sizes - enlarge JS, Linux and WIZnet buffers 2016-01-15 18:37:54 +00:00
Thorsten von Eicken
c3a5751d9c Always reset OneWire on select. Tweak esp8266 performance 2016-01-09 12:35:54 -08:00
Thorsten von Eicken
d8dec28a7c fix crash on exception #772; misc tweaks 2015-12-30 12:22:02 -08:00
Thorsten von Eicken
9aa07bc92d add sntp 2015-12-24 12:49:55 -08:00
Thorsten von Eicken
f210ca368f added mDNS 2015-12-24 09:17:51 -08:00
Thorsten von Eicken
c8c854e3b8 fix crash during wifi restore 2015-12-24 00:38:20 -08:00
Thorsten von Eicken
7acd4bc29c move jsExceptionHere fmt strings to flash on esp8266 2015-12-20 11:45:51 -08:00
Thorsten von Eicken
1547ee0a5c 1400 JSvars for esp8266; misc logging changes 2015-12-20 11:45:29 -08:00
Thorsten von Eicken
e5f9db8bd3 first cut at Wifi console 2015-12-19 18:39:12 -08:00
Thorsten von Eicken
de54a9e862 move some tests around 2015-12-18 21:58:23 -08:00
Thorsten von Eicken
9887c6e1e6 add in-memory debug log 2015-12-18 21:57:37 -08:00
Thorsten von Eicken
a4ec9fa2b8 small esp8266 and doc tweaks 2015-12-18 17:39:22 -08:00
Thorsten von Eicken
a1847d2fcb fix socket error handling 2015-12-14 21:56:10 -08:00
Thorsten von Eicken
a95ff12049 single error event function in socketserver 2015-12-13 12:32:09 -08:00
Thorsten von Eicken
4cd9c6e7b0 improve tests 2015-12-10 22:45:53 -08:00