Paul Sokolovsky
09ed5bcbbb
extmod/modlwip: Rework getaddrinfo() data passing.
...
The code is based on Damien George's implementation for esp8266 port,
avoids use of global variables and associated re-entrancy issues, and
fixes returning stale data in some cases.
2016-03-12 10:50:51 +07:00
Paul Sokolovsky
e5b047369b
extmod/modlwip: Use MICROPY_EVENT_POLL_HOOK for event polling if defined.
...
Instead of just delaying 100ms if event isn't yet ready.
So far applies only to default, "infinite" socket timeout.
2016-03-11 09:32:07 +07:00
Paul Sokolovsky
43d497592f
extmod/modlwip: Factor out "socket connected" check to a function.
...
Same code repeated for each send*() and recv*() function.
2016-03-09 12:43:09 +07:00
Paul Sokolovsky
fda874e406
extmod/modlwip: Support non-blocking recv().
2016-03-09 12:39:33 +07:00
Paul Sokolovsky
7379be3673
extmod/modlwip: Add .write() stream method.
2016-03-09 12:35:43 +07:00
Damien George
4f64f6bfd3
extmod/modlwip: Still process remaining incoming data of a closed socket.
...
It can happen that a socket gets closed while the pbuf is not completely
drained by the application. It can also happen that a new pbuf comes in
via the recv callback, and then a "peer closed" event comes via the same
callback (pbuf=NULL) before the previous event has been handled. In both
cases the socket is closed but there is remaining data. This patch makes
sure such data is passed to the application.
2016-03-09 12:31:25 +07:00
Damien George
6d2e9e70b3
extmod/modlwip: Check for state change during recv busy-wait loop.
...
For example, the peer may close the connection while recv is waiting for
incoming data.
2016-03-09 12:29:40 +07:00
Paul Sokolovsky
6185dc5f3d
extmod/modlwip: Add stream .read() and .readline() methods.
2016-03-09 09:20:22 +07:00
Paul Sokolovsky
f1919b7c98
extmod/modlwip: Add dummy .makefile() method.
2016-03-09 09:14:45 +07:00
Paul Sokolovsky
c7fb87caff
extmod/modlwip: Add stream protocol read method.
2016-03-09 09:12:32 +07:00
Paul Sokolovsky
ed593780bf
extmod/modlwip: Implement dummy setsockopt().
2016-03-08 14:24:49 +07:00
Paul Sokolovsky
f8d42da104
extmod/modlwip: Add .print() method.
2016-03-08 11:37:15 +07:00
Paul Sokolovsky
04a9ac7f38
extmod/modlwip: Update make_new() arguments for recent refactor.
2016-03-08 10:31:21 +07:00
Paul Sokolovsky
65405247a0
extmod/vfs_fat_lexer: Add func prototype for pedantic warnings.
2016-03-03 14:53:36 +02:00
Paul Sokolovsky
3aa0f2eed3
extmod/vfs_fat_lexer: Make conditional on FatFs support enabled.
2016-03-03 14:08:27 +02:00
Paul Sokolovsky
453a2a3d7c
extmod/vfs_fat: Add lexer, move from stmhal port for reuse.
2016-03-03 13:25:44 +02:00
Paul Sokolovsky
e0821830b0
extmod/vfs_fat: Add .rename() method.
2016-02-29 01:23:53 +02:00
Paul Sokolovsky
09e363316f
extmod/vfs_fat_misc: Fix cc3200 port build.
2016-02-29 01:15:19 +02:00
Paul Sokolovsky
08fed6992f
extmod/vfs_fat_misc: Add func prototype for pedantic warnings.
2016-02-29 00:48:45 +02:00
Paul Sokolovsky
6ef65e70af
extmod/vfs_fat: Add fat_vfs_import_stat(), reusable import stat routine.
...
Moved from stmhal.
2016-02-29 00:44:32 +02:00
Paul Sokolovsky
bbe832a0b2
extmod/vfs_fat: Add .mkdir() method.
2016-02-29 00:03:20 +02:00
Paul Sokolovsky
6f469209e9
extmod/vfs_fat: Fix unused param warning/error.
2016-02-28 20:45:51 +02:00
Paul Sokolovsky
19749db7bf
extmod/vfs_fat: Add .remove() method.
...
Based on stmhal implementation - rather small, so just duplicating.
2016-02-28 20:30:07 +02:00
Paul Sokolovsky
cd6d189f48
extmod/vfs_fat: Move listdir() method from stmhal for reuse.
2016-02-28 17:17:24 +02:00
Paul Sokolovsky
4cd45f48b1
cc3200: Fix breakage after VfsFat refactor.
2016-02-15 10:39:56 +02:00