Damien George
04d05db27e
py/vm: Fix bug with unwind jump popping the iterator from a for loop.
...
This patch fixes a regression introduced by
088740ecc4
2017-05-25 20:39:08 +10:00
Damien George
68e71eacb8
py/vm: Fix bug with stackless mode and unwinding of exceptions.
...
This patch fixes a regression introduced by
71a3d6ec3b
Previous to this patch the n_state variable was referring to that computed
at the very start of the mp_execute_bytecode function. This patch fixes it
so that n_state is recomputed when the code_state changes.
2017-05-25 20:35:57 +10:00
Paul Sokolovsky
982e676902
zephyr/modusocket: getaddrinfo: Raise OSError on resolution timeout, etc.
2017-05-24 19:55:14 +03:00
Paul Sokolovsky
1c9ee49756
drivers: Replace deprecated Pin.high()/low() methods with .__call__(1/0).
2017-05-21 17:44:58 +03:00
Paul Sokolovsky
bcf31a3908
esp8266, stmhal, zephyr: Rename machine.Pin high/low methods to on/off.
...
For consistent Pin/Signal class hierarchy. With it, Signal is a proper
(while still ducktyped) subclass of a Pin, and any (direct) usage of Pin
can be replace with Signal.
As stmhal's class is reused both as machine.Pin and legacy pyb.Pin,
high/low methods actually retained there.
2017-05-21 17:44:58 +03:00
Paul Sokolovsky
299c0a3925
CODECONVENTIONS: Typo fix.
2017-05-21 15:58:03 +03:00
Paul Sokolovsky
3ebd67fc09
library/machine.Pin: Remove .id() method and .board class attr.
...
Both aren't part of generic Hardware API: It's impossible to implement
.id() method in a generic case (e.g., when Pin is instantiated by the
underlying OS/RTOS). .board attribute is an obvious space hog which
instead can be implemented on Python level if needed.
2017-05-21 15:50:16 +03:00
Paul Sokolovsky
19e065294d
cc3200/mods/pybpin: Remove toggle() method.
...
It's not part of MicroPython HW API and can be easily implemented on Python
level in case of need.
Saved 56 bytes of binary.
2017-05-21 15:39:27 +03:00
Damien George
338f0849d9
py/mkenv.mk: Use $(TOP) instead of ".." to reference tools, mpy-cross.
2017-05-19 15:53:55 +10:00
Damien George
436d97b3f9
docs/library/machine.UART: Update and improve uart.any() docs.
2017-05-19 15:48:22 +10:00
Damien George
aca898eeb0
esp8266/machine_uart: Add uart.any() method.
...
Returns 0 or 1, corresponding to no or at least 1 char waiting.
2017-05-19 15:48:22 +10:00
Damien George
218a876f97
tests/basics/builtin_range: Add tests for negative slicing of range.
2017-05-18 17:32:42 +10:00
Damien George
03659c51ca
py/objrange: Fix slicing of range when step of slice is negative.
2017-05-18 17:32:42 +10:00
Damien George
e1b0f2a16f
tests/basics/list_slice_3arg: Add more tests for negative slicing.
2017-05-18 17:32:42 +10:00
Damien George
eb4c37f7a4
py/sequence: Fix boundary errors when slicing with a negative step.
2017-05-18 17:32:42 +10:00
Damien George
d007351b33
docs/library/micropython: Document the newer micropython functions.
2017-05-18 00:25:09 +10:00
Damien George
55dd83a7ba
drivers/display/lcd160cr_test: Allow test to take orientation parameter.
2017-05-17 19:54:38 +10:00
Damien George
f351c6db5e
drivers/display/lcd160cr: Fix get_line method and enhance screen_dump.
...
The docs are updated and describe the new behaviour of these methods.
2017-05-17 19:53:13 +10:00
Damien George
e4a53570d0
docs: Change single occurrence of "Micropython" to "MicroPython".
2017-05-17 12:38:33 +10:00
Paul Sokolovsky
0af974b777
examples/hwapi/soft_pwm2_uasyncio: Update for call_later_ms().
...
Following finalized naming in uasyncio.
2017-05-17 00:44:00 +03:00
Paul Sokolovsky
0912334f54
zephyr/modusocket: getaddrinfo: Use RAISE_ERRNO for proper error decoding.
2017-05-17 00:21:22 +03:00
Paul Sokolovsky
5f648ff60e
zephyr/main: Check default netif before applying operations to it.
...
If no network driver is enabled (e.g., it doesn't exist for a particular
board), it will be NULL.
2017-05-17 00:17:53 +03:00
Paul Sokolovsky
aa9ce283c2
zephyr/modusocket: Get rid of cur_pkt object member.
...
Instead, just peek a packet at the head of the queue and work with it.
2017-05-16 13:46:54 +03:00
Paul Sokolovsky
a3008e447c
zephyr/modusocket: First step to switch to alternative FIFO processing.
...
Here we wait for non-empty FIFO, and then directly access/drop its head
element.
2017-05-16 13:43:06 +03:00
Damien George
88c51c3592
tools/mpy-tool.py: Fix regression with freezing floats in obj repr C.
...
Regression was introduced by ec534609f6
2017-05-16 18:53:02 +10:00