Jim Mussared
a61bfc1460
aioble/README.md: Add l2cap example.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-12 13:35:50 +11:00
Jim Mussared
3ea74867f3
aioble: Add l2cap channel disconnected().
...
Allows `await channel.disconnected()`.
This also fixes a bug where connection._l2cap_channel wasn't being set to
None on disconnect.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-12 13:35:45 +11:00
Jim Mussared
dd9b783568
aioble/multitests: Add test for subscription and notification.
...
This replicates the failure described in #453 (which is fixed by #459 .
Also adds a test for subscription.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-10 17:41:11 +11:00
Jim Mussared
9169ca6543
aioble: Add support for write-with-update.
...
This allows a server to write a characteristic and automatically
notify/indicate all subscribed clients.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-10 13:47:04 +11:00
Jim Mussared
dc03b4af4d
aioble: Fix notified/indicated event waiting.
...
After a client does a successful `await char.notified()`, then before the
next call to `notified()` a notification arrives, then they call
`notified()` twice before the _next_ notification, the second call will
return None rather than waiting.
This applies the same fix as in 5a86aa5866
which solved a similar problem for server-side `char.written()`. Using
a deque is slightly overkill here, but it's consistent with the server
side, and also makes it very easy to support having a notification queue
in the future.
Also makes the client characteristic properly flags/properties-aware (i.e.
explicitly fail operations that aren't supported).
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-08 17:34:08 +11:00
Jim Mussared
43cad17946
aioble/multitests/ble_write_capture.py: Add multitest for write capture.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-05 14:30:40 +11:00
Jim Mussared
23b3c7fe2d
aioble/multitests: Fix existing multitests.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-05 14:30:31 +11:00
Jim Mussared
5a86aa5866
aioble: Add a write queue for gatt server.
...
This fixes a bug where an incoming write before `written` is awaited causes
`written` to return None. It also introduces a mechanism for a server to
"capture" all incoming written values (instead of only having access to the
most recent value).
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-11-05 14:30:08 +11:00
Jim Mussared
3c383f6d28
aioble: Fix docs for subscribe (needs await).
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-07-12 13:38:33 +10:00
Jim Mussared
32684886ee
micropython/bluetooth/aioble: subscribe must register the connection.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-07-08 15:15:47 +10:00
Martin Komon
2e91b92413
unix-ffi/datetime: Add tzinfo.__new__ to make the package importable.
...
Add constructor to tzinfo class so that the package can be imported without
errors.
2021-06-02 00:38:42 +10:00
Damien George
a3df207934
python-stdlib/random: Add getrandbits with no limit on number of bits.
...
Thanks to Macarthur Inbody aka @133794m3r for the implementation.
Signed-off-by: Damien George <damien@micropython.org>
2021-05-30 16:04:17 +10:00
Jim Mussared
8631225b7f
micropython/aioble: Add asyncio-based wrapper for ubluetooth.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-05-28 18:26:49 +10:00
Damien George
fe975d973a
python-ecosys/iperf3: Add iperf3.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-05-28 12:47:35 +10:00
Damien George
f7f38ff2f1
python-stdlib/cgi: Apply Black formatting.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-05-27 22:42:47 +10:00
Damien George
c05ee03d5b
workflows: Add initial GitHub workflows support, with code formatting.
...
Signed-off-by: Damien George <damien@micropython.org>
2021-05-27 22:42:43 +10:00
Damien George
d093a684a4
tools: Add code formatting and CI scripts.
...
Adapted from the micropython repo.
Signed-off-by: Damien George <damien@micropython.org>
2021-05-27 22:42:36 +10:00
Jim Mussared
3a6ab0b46d
top: Remove upip-related scripts.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-05-27 16:57:06 +10:00
Jim Mussared
35e3c9e4ff
python-ecosys: Move urequests to python-ecosys.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-05-27 16:53:02 +10:00
Jim Mussared
bc2b6b0b7f
micropython/uasyncio: Remove uasyncio-v2.
...
Superceded by uasyncio-v3 in the main repo.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-05-27 16:52:16 +10:00
Jim Mussared
fa13cbbc8b
all: Run black over all code.
...
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2021-05-27 15:50:04 +10:00
Jim Mussared
af3e1aff9e
all: Update READMEs.
2021-05-27 15:41:08 +10:00
Jim Mussared
1a28fe84e8
top: Move modules into python-stdlib, unix-ffi, or micropython.
2021-05-27 15:41:08 +10:00
Jim Mussared
a1c4b5b564
binascii/hashlib: Set type to stdlib.
2021-05-27 15:41:08 +10:00
Jim Mussared
cdcce0384d
test: Remove PEP380 test (better handled by core testing).
2021-05-27 15:41:08 +10:00
Jim Mussared
caf16675cf
cpython-uasyncio: Remove as new-uasyncio is compatible with CPython.
2021-05-27 15:41:08 +10:00
Jim Mussared
b4eeaae105
top: Remove unhelpful packages.
2021-05-27 15:41:08 +10:00
Jim Mussared
444b45e431
top: Remove all empty packages.
2021-05-27 15:41:08 +10:00
Damien George
eae01bd4e4
logging: Add "levelno" entry to log record object/dict.
...
Useful for custom handlers to do further level filtering.
Signed-off-by: Damien George <damien@micropython.org>
2020-09-03 11:29:36 +10:00
Damien George
7b1161dd1b
logging: Add support for custom handlers.
...
Any custom handlers will be passed a LogRecord instance which has members
and a dict with "levelname", "message" and "name", to be used for creating
a log message. The handler list is a global singleton so that sub-logging
objects all use the same set of (root) handlers.
The name of the root handler is also changed from None to "root", to match
CPython.
Signed-off-by: Damien George <damien@micropython.org>
2020-07-08 15:59:01 +10:00
Damien George
dedf328503
fnmatch: Remove dependency on posixpath module.
...
In micropython-lib, os.path.normcase is already a no-op.
Signed-off-by: Damien George <damien@micropython.org>
2020-07-07 19:09:59 +10:00
Damien George
6b985bbc1b
copy: Support copy and deepcopy of OrderedDict objects.
...
Signed-off-by: Damien George <damien@micropython.org>
2020-07-07 10:56:10 +10:00
Damien George
b89114c834
Revert "README: Add note that repository is unmaintained."
...
This reverts commit 1509830fee
.
2019-02-26 01:02:14 +11:00
Paul Sokolovsky
1509830fee
README: Add note that repository is unmaintained.
2019-02-24 21:09:10 +03:00
Paul Sokolovsky
f20d89c6aa
logging: Release 0.3.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
a4f2d5665d
logging: example_logging: Add testcase for exception().
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
b97fe09ed9
logging: Add exc() and exception() methods.
...
Non-standard exc() method accepts exception instance to log as a
parameter. exception() just uses sys.exc_info().
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
09c59c4704
logging: Add setLevel() method.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
a93d0ee87b
logging: Release 0.2.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
0feab3397e
logging: example_logging: Add more testcases.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
6b67e351f0
logging: Implement isEnabledFor(level) method.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
f788f667ca
logging: Some performance and memory use optimizations.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
220b501eeb
unittest: Release 0.3.2.
2018-05-11 14:18:02 +10:00
Konstantin Belyalov
912f9413ac
unittest: Exit with non zero code in case of failures. Fixing #259
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
0a581ef357
uasyncio.udp: Release 0.1.1.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
8d75a36431
uasyncio.udp: Remove optional flags value in a call to usocket.sendto().
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
4238bc9653
uasyncio: Release 2.0.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
97be3343fa
uasyncio.core: Release 2.0.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
5149a54f91
uasyncio: Update __init__() to take runq_len & waitq_len params.
2018-05-11 14:18:02 +10:00
Paul Sokolovsky
7e8a3cfe45
uasyncio.core: test_full_wait: Update for runq/waitq refactor.
2018-05-11 14:18:02 +10:00