Paul Sokolovsky
1a0adf49df
esp8266: Enable urandom module.
9 years ago
Damien George
e673714cfe
esp8266: Make mp_hal_delay_us work with new event framework.
9 years ago
Paul Sokolovsky
58e2ad42ae
esp8266: Update README with the latest features.
9 years ago
Damien George
b894551772
extmod/uctypes: Change param type from void* to byte*.
9 years ago
Damien George
da161fd9f0
extmod/uctypes: Finish support for FLOAT32 and FLOAT64 types.
9 years ago
Damien George
12154b1774
extmod/uctypes: Use mp_binary_get_val helper when extracting value.
It handles more cases than mp_binary_get_int.
9 years ago
Damien George
8d4d6731f5
py/parse: When looking up consts, check they exist before checking type.
9 years ago
Peter Hinch
2b302dad51
docs: Update pyb.UART.any() to mention that it returns character count.
9 years ago
Peter Hinch
6d5a549067
docs: Mention that pyb.SPI constructor accepts "X" and "Y" arguments.
9 years ago
Peter Hinch
b8133c4c0f
docs: Update pyb.I2C constructor to reflect changes in Pyboard Lite.
9 years ago
Peter Hinch
4a6cac4643
docs: Update asm tutorial, maximum number of allowed args is now 4.
9 years ago
Damien George
99146ea444
tests/io: Remove "testfile" at end of open_plus test.
9 years ago
Damien George
556a1df6fd
esp8266/ets_alt_task: Make FIRST_PRIO=0 to cover all task priorities.
FIRST_PRIO=2 works but using 0 is hopefully safer, and can anyway be
optimised in the future.
9 years ago
Paul Sokolovsky
9d7b871f58
esp8266: Store frozen modules in FlashROM.
Requires special lexer to access their contents.
9 years ago
Damien George
2466cb67f8
docs/esp8266: Update quick reference: i2c.readfrom and neopixel example.
9 years ago
Damien George
3acaa28b52
py: Don't allocate an extra parse node for power exponent.
Previous to this patch, the "**b" in "a**b" had its own parse node with
just one item (the "b"). Now, the "b" is just the last element of the
power parse-node. This saves (a tiny bit of) RAM when compiling.
9 years ago
Paul Sokolovsky
52e062ef33
py/frozenmod: Allow port to override lexer to use for frozen modules.
9 years ago
Damien George
664f03f466
tests: Add a test for argument passing to inline-asm functions.
9 years ago
Damien George
9a58316de2
py/objfun: Allow inline-asm functions to be called with 4 arguments.
9 years ago
Damien George
be989be861
qemu-arm: Enable builtin override feature, and enable more tests.
Hopefully these tests run reliably on Travis.
9 years ago
Damien George
1ded19d4b3
qemu-arm: Reinitialise uPy heap and runtime at start of each test.
Previous to this patch, all qemu-arm tests were running in the same
session, and global variables could be left over from the previous test.
This patch makes it so that the heap and runtime are reinitialised at
the start of each test.
9 years ago
Damien George
157056ecdf
tests: Add new subdir "stress/" specifically for stress tests.
9 years ago
Damien George
ab69ed7dac
tests: Split large tests into smaller files, to run with a small heap.
All tests in basics/ directory can now run and pass using 64-bit unix
port with only a 16k heap (./run-tests --heapsize 16k). Tests in this
directory should remain small so they can be used for ports with a
small heap.
9 years ago
Damien George
9996adc37d
tests/run-tests: Add cmd line option "--heapsize".
This allows you to specify the heapsize that unix will use when running
the test suite, eg: ./run-tests --heapsize 16k
9 years ago
Damien George
cea6cf8a5e
py/formatfloat: Fix buffer overflow when formatting tiny numbers.
9 years ago
Damien George
0d1f8868b6
py: For mp_buffer_info_t, change len type from mp_uint_t to size_t.
9 years ago
Damien George
77f85db41e
py/objarray: Fix array slice assignment when array is reallocated.
Addresses issue #1898 .
9 years ago
Damien George
06b398489e
py/parsenum: Fix compiler warnings for no decl and signed comparison.
9 years ago
Damien George
0be6359f39
py: When printf'ing an object as a pointer, pass the concrete pointer.
9 years ago
Damien George
2a1cca20b1
py: Fix passing of some wide int types to printf varg format list.
Passing an mp_uint_t to a %d printf format is incorrect for builds where
mp_uint_t is larger than word size (eg a nanboxing build). This patch
adds some simple casting to int in these cases.
9 years ago
Damien George
e7cd1699df
py/argcheck: Use size_t instead of mp_uint_t to count number of args.
9 years ago
Damien George
dddb98db8b
py/parsenum: Use size_t to count bytes, and int for type of base arg.
size_t is the proper type to count number of bytes in a string. The base
argument does not need to be a full mp_uint_t, int is enough.
9 years ago
Dave Hylands
99fc0d120a
stmhal: NUCELO_F401RE cleanup
Added definitions for SPI1, SPI2, and SPI3
Removed USB stuff (that could be removed)
Updated BOARD name defintion
9 years ago
Dave Hylands
00f921ce02
stmhal: Rename STM32F401NUCLEO to NUCLEO_F401RE
This makes the board match the name printed on the board (and
agree with the documentation)
9 years ago
Dave Hylands
031fadd10e
stmhal: Add board definition files for NUCLEO_F411RE
9 years ago
Paul Sokolovsky
e5c39a3a9e
esp8266: Switch to lwIP built from source.
Using https://github.com/pfalcon/esp-open-lwip project.
9 years ago
Paul Sokolovsky
0779409d0d
extmod/modlwip: lwip_tcp_receive: Properly map lwIP error to POSIX errno.
9 years ago
Paul Sokolovsky
ba8f7d5171
extmod/modlwip: Add socket.setblocking() method.
9 years ago
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.
9 years ago
Peter Hinch
21b74604f9
docs: Add Python speed optimisation guide, including minimal viper ref.
9 years ago
Peter Hinch
85d3b6165a
docs: Update details on using ADCAll object for vref/vbat channels.
9 years ago
Peter Hinch
70f32f0f73
docs: Update asm_thumb2_hints_tips re return type of asm funcs.
9 years ago
Christopher Arndt
3d0e3a3d3e
esp8266: Mention git submodule in build instructions for esp8266 port.
9 years ago
Damien George
932f07ccf5
esp8266: Rejig Makefile so extmod/modlwip.o is placed under build/.
9 years ago
Paul Sokolovsky
4c2cb7e384
esp8266: Define MICROPY_EVENT_POLL_HOOK for the port.
9 years ago
Paul Sokolovsky
6e5c31c947
esp8266: Be sure to build ets_alt_task.
9 years ago
Paul Sokolovsky
a099bfe89c
esp8266/esp_mphal: Add higher-level event polling function.
ets_event_poll() polls both system events and uPy pending exception.
9 years ago
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.
9 years ago
Paul Sokolovsky
54fc247f9b
esp8266/ets_alt_task: Update for vendor SDK 1.5.0.
SDK 1.5.0 has a task with priority 3: ets_task(401001f4, 3, 3fff9808, 4).
Recognizing SDK version requires the latets esp-open-sdk build.
9 years ago
Paul Sokolovsky
97375f4576
esp8266/ets_alt_task: Be sure to "pop" event before calling its handler.
Otherwise, if handler calls recursive event loop, there's infinite
recursion (because the loop calls the same handler on same event again).
9 years ago