Paul Sokolovsky
0a400a6333
esp8266: Switch integer arith routines to BootROM.
2016-04-14 15:06:07 +03:00
Damien George
df3b1741b6
esp8266: Separate 1-wire timing funcs from Python module to save iRAM.
...
esponewire.c contains low-level timing-critical functions that go in
iRAM. modonewire.c contains Python wrapper code.
2016-04-14 12:44:26 +01:00
Damien George
674bf1bc81
esp8266: Add hard IRQ callbacks for pin change on GPIO0-15.
2016-04-14 12:44:26 +01:00
Damien George
d9d408135d
esp8266: Add dummy entries for non-existing pins to simplify pin logic.
...
Now pins can be easily looked up in the table using the pin number as the
index and vice versa.
2016-04-14 12:43:25 +01:00
Damien George
a9a732af1f
esp8266: Remove pin_id field from C pin object.
...
This field is the same as phys_port and not needed.
2016-04-14 12:43:25 +01:00
Paul Sokolovsky
44ab5c3ef1
extmod/modlwip: Start adding debug output.
2016-04-14 01:15:52 +03:00
Paul Sokolovsky
fef0d9818a
extmod/modlwip: lwip_tcp_receive(): Properly handle EOF for non-blocking sock.
2016-04-14 00:59:09 +03:00
Damien George
f30b6f0af5
py/makeqstrdata: Add more names for escaped chars and esc non-printable.
...
Non-printable characters are escaped as 0xXX, where XX are the hex
digits of the character value.
2016-04-13 22:12:39 +01:00
Paul Sokolovsky
59a4fee516
extmod/modwebsocket: Another case to propagate EOF.
2016-04-13 22:17:09 +03:00
Damien George
733db525e2
stmhal: Add Makefile option FROZEN_MPY_DIR to support frozen bytecode.
2016-04-13 16:07:47 +01:00
Damien George
f9448ddc2c
minimal: Add example of frozen persistent bytecode (.mpy file).
...
frozentest.py is frozen into the binary as frozen bytecode. The .mpy
file is included so that there is no dependency on the cross compiler.
2016-04-13 16:07:47 +01:00
Damien George
0a2e9650f5
py: Add ability to have frozen persistent bytecode from .mpy files.
...
The config variable MICROPY_MODULE_FROZEN is now made of two separate
parts: MICROPY_MODULE_FROZEN_STR and MICROPY_MODULE_FROZEN_MPY. This
allows to have none, either or both of frozen strings and frozen mpy
files (aka frozen bytecode).
2016-04-13 16:07:47 +01:00
Damien George
0699c6bf9e
tools: Add mpy-tool.py, to work with .mpy files.
...
Currently it can freeze .mpy files.
2016-04-13 16:05:43 +01:00
Damien George
594fa73411
py/makeqstrdata: Factor out some code to functions that can be reused.
2016-04-13 16:05:43 +01:00
Damien George
ed0c11236f
py/emitglue: Make mp_raw_code_t* arguments constant pointers.
2016-04-13 16:05:43 +01:00
Damien George
6d24dc23b8
py/emitglue: Move typedef of mp_raw_code_t from .c to .h file.
...
It's needed by frozen bytecode.
2016-04-13 16:05:43 +01:00
Damien George
c2a519bab9
tests: Skip async tests for native emitter.
2016-04-13 15:56:42 +01:00
Damien George
7f7e247545
tests: Add .exp files for async tests, so they can run with Python 3.4.
2016-04-13 15:56:15 +01:00
Damien George
6eb17c31a9
ports: Disable async/await on bare-arm, minimal, pic16bit, cc3200.
...
It costs 1188 bytes of code on Thumb 2 archs.
2016-04-13 15:31:30 +01:00
Damien George
c33df193bf
tests: Add 6 tests for async await/for/with.
2016-04-13 15:27:06 +01:00
Damien George
eacbd7aeba
py: Fix constant folding and inline-asm to work with new async grammar.
2016-04-13 15:26:39 +01:00
pohmelie
81ebba7e02
py: add async/await/async for/async with syntax
...
They are sugar for marking function as generator, "yield from"
and pep492 python "semantically equivalents" respectively.
@dpgeorge was the original author of this patch, but @pohmelie made
changes to implement `async for` and `async with`.
2016-04-13 15:26:38 +01:00
Paul Sokolovsky
959ed931a4
esp8266/esp_mphal: call_dupterm_read(): Fix order of deactivating on EOF.
...
First deactivate, then print diagnostic message.
2016-04-13 16:35:50 +03:00
Paul Sokolovsky
19e3c9d53a
esp8266/esp_mphal: Don't swallow exceptions in dupterm's read()/write().
...
The idea is that if dupterm object can handle exceptions, it will handle
them itself. Otherwise, object state can be compromised and it's better
to terminate dupterm session. For example, disconnected socket will keep
throwing exceptions and dump messages about that.
2016-04-13 16:34:17 +03:00
Paul Sokolovsky
54ea253f56
extmod/moduos_dupterm: Don't swallow exceptions in dupterm's read()/write().
...
The idea is that if dupterm object can handle exceptions, it will handle
them itself. Otherwise, object state can be compromised and it's better
to terminate dupterm session. For example, disconnected socket will keep
throwing exceptions and dump messages about that.
2016-04-13 16:34:11 +03:00