summaryrefslogtreecommitdiffstatshomepage
Commit message (Collapse)AuthorAge
* docs/esp8266/tutorial/intro: Reword section on flash size requirement.Paul Sokolovsky2017-04-14
| | | | | Give a clearly dissuading tone on end users trying 512KB version - it has to many end-usery features lacking.
* esp8266/README: Add notice about 512K version.Paul Sokolovsky2017-04-14
|
* esp8266/README: Replace reference of alpha status to beta status.Paul Sokolovsky2017-04-14
|
* zephyr/modusocket: Strip packet header right in the receive callback.Paul Sokolovsky2017-04-13
| | | | Instead of complicating recv() implementation.
* tests/extmod/utimeq1: Improve coverage of utimeq module.Damien George2017-04-13
|
* py/gc: Execute finaliser code in a protected environment.Damien George2017-04-12
| | | | | | | | | | | | If a finaliser raises an exception then it must not propagate through the GC sweep function. This patch protects against such a thing by running finaliser code via the mp_call_function_1_protected call. This patch also adds scheduler lock/unlock calls around the finaliser execution to further protect against any possible reentrancy issues: the memory manager is already locked when doing a collection, but we also don't want to allow any scheduled code to run, KeyboardInterrupts to interupt the code, nor threads to switch.
* py/nlrsetjmp: Add check for failed NLR jump.Damien George2017-04-12
| | | | | Also optimise the function so it only needs to call the MP_STATE_THREAD macro once (following how other nlr code is written).
* unix: Enabled high-quality float hashing in coverage build.Damien George2017-04-12
|
* py/objfloat: Add implementation of high-quality float hashing.Damien George2017-04-12
| | | | Disabled by default.
* py: Optimise types for common case where type has a single parent type.Damien George2017-04-12
| | | | | | | | | | | | | | | | | | | | | | | | The common cases for inheritance are 0 or 1 parent types, for both built-in types (eg built-in exceptions) as well as user defined types. So it makes sense to optimise the case of 1 parent type by storing just the type and not a tuple of 1 value (that value being the single parent type). This patch makes such an optimisation. Even though there is a bit more code to handle the two cases (either a single type or a tuple with 2 or more values) it helps reduce overall code size because it eliminates the need to create a static tuple to hold single parents (eg for the built-in exceptions). It also helps reduce RAM usage for user defined types that only derive from a single parent. Changes in code size (in bytes) due to this patch: bare-arm: -16 minimal (x86): -176 unix (x86-64): -320 unix nanbox: -384 stmhal: -64 cc3200: -32 esp8266: -108
* py/obj: Clean up and add comments describing mp_obj_type_t struct.Damien George2017-04-12
|
* zephyr/modusocket: Call net_nbuf_print_frags() in recv callback if DEBUG > 1.Paul Sokolovsky2017-04-11
|
* py/objint: Use unsigned arithmetic when formatting an integer.Damien George2017-04-11
| | | | | Otherwise the edge case of the most negative integer value will not convert correctly.
* py/objint: Extract small int value directly because type is known.Damien George2017-04-11
|
* unix, windows: Use core-provided KeyboardInterrupt exception object.Damien George2017-04-11
|
* stmhal: Enable parsing of all Pin constructor args by machine.Signal.Damien George2017-04-11
|
* extmod/machine_signal: Support all Pin's arguments to the constructor.Paul Sokolovsky2017-04-11
| | | | | | | | | | | | | | | | | This implements the orginal idea is that Signal is a subclass of Pin, and thus can accept all the same argument as Pin, and additionally, "inverted" param. On the practical side, it allows to avoid many enclosed parenses for a typical declararion, e.g. for Zephyr: Signal(Pin(("GPIO_0", 1))). Of course, passing a Pin to Signal constructor is still supported and is the most generic form (e.g. Unix port will only support such form, as it doesn't have "builtin" Pins), what's introduces here is just practical readability optimization. "value" kwarg is treated as applying to a Signal (i.e. accounts for possible inversion).
* py/runtime: When init'ing kbd intr exc, use tuple ptr instead of object.Damien George2017-04-10
|
* py: Make sure that static emg-exc-buffer is aligned to size of mp_obj_t.Damien George2017-04-10
| | | | | | | | | | | | This buffer is used to allocate objects temporarily, and such objects require that their underlying memory be correctly aligned for their data type. Aligning for mp_obj_t should be sufficient for emergency exceptions, but in general the memory buffer should aligned to the maximum alignment of the machine (eg on a 32-bit machine with mp_obj_t being 4 bytes, a double may not be correctly aligned). This patch fixes a bug for certain nan-boxing builds, where mp_obj_t is 8 bytes and must be aligned to 8 bytes (even though the machine is 32 bit).
* docs/uhashlib: Deconditionalize.Paul Sokolovsky2017-04-09
| | | | | Notes on WiPy incompatibilities with the standard module API are moved under "Known issues" to its documentation.
* docs/usocket: Deconditionalize.Paul Sokolovsky2017-04-09
| | | | | Notes on WiPy incompatibilities with the standard socket module API are moved under "Known issues" to its documentation.
* docs/utime: Deconditionalize description of sleep().Paul Sokolovsky2017-04-09
|
* docs/library/machine.UART: Remove some conditionals.Paul Sokolovsky2017-04-09
|
* cc3200/pybuart: Make parity specifications consistent with HW API.Paul Sokolovsky2017-04-09
| | | | parity=0 means even parity, parity=1 - odd.
* docs/library/builtins: int: Add notice on byteorder param for to/from_bytes.Paul Sokolovsky2017-04-09
|
* zephyr/machine_pin: Implement pin protocol for machine.Signal support.Paul Sokolovsky2017-04-08
|
* zephyr/modmachine: Add Signal class.Paul Sokolovsky2017-04-08
|
* zephyr/mpconfigport.h: Fix build if usocket module is disabled.Paul Sokolovsky2017-04-08
|
* zephyr/modusocket: Implement accept().Paul Sokolovsky2017-04-08
|
* zephyr/modusocket: socket_bind: Don't set recv callback on STREAM sockets.Paul Sokolovsky2017-04-08
| | | | For stream sockets, next exected operation is listen().
* zephyr/modusocket: Implement listen().Paul Sokolovsky2017-04-07
|
* docs/esp8266/general: Start explicit "Known Issues", mentioned RTC inaccuracy.Paul Sokolovsky2017-04-07
|
* drivers/nrf24l01: Update to work on newer ports, using machine, utime.Damien George2017-04-07
| | | | | | | | | Changes made are: - Use the time module in place of the pyb module for delays. - Use spi.read/spi.write instead of spi.send/spi.receive. - Drop some non-portable parameters to spi and pin initialization. Thanks to @deshipu for the original patch.
* tools/pyboard: Provide more details when expected reply not received.Paul Sokolovsky2017-04-07
| | | | | When trying to execute a command via raw REPL and expected "OK" reply not received, show what was received instead.
* modusocket: Handle a case when recv_q is empty when EOF is signaled.Paul Sokolovsky2017-04-06
| | | | In this case, we can mark socket as closed directly.
* zephyr/modusocket: Factor out "extended k_fifo API".Paul Sokolovsky2017-04-05
| | | | | | Internal structure of k_fifo changed between 1.7 and 1.8, so we need to abstract it away. This adds more functions than currently used, for future work.
* docs/machine.Pin: Move wipy-specific methods to its docs.Paul Sokolovsky2017-04-05
|
* tools/pyboard: ProcessPtyToTerminal: Add workaround for PySerial bug.Paul Sokolovsky2017-04-05
| | | | | When working with a "virtual" port, like PTY. The issue described in http://stackoverflow.com/questions/34831131/pyserial-does-not-play-well-with-virtual-port
* docs/machine.Pin: Move wipy-specific details to its own docs.Paul Sokolovsky2017-04-05
|
* cc3200/modmachine: Return frequency value directly, like other ports.Paul Sokolovsky2017-04-05
|
* docs/machine.SPI: Remove outdated wipy chunk.Paul Sokolovsky2017-04-05
|
* docs/uos: De-conditionalize statvfs() description.Paul Sokolovsky2017-04-05
| | | | | It's a standard function, and it's already described (in the library intro) that for any given port, any function may be missing.
* docs/utime: De-conditionalize description of sleep_ms() and friends.Paul Sokolovsky2017-04-05
| | | | These are basic MicroPython API, and all ports should implement them.
* tests/basics: Add test for tuple inplace add.Damien George2017-04-05
|
* py/objtuple: Add support for inplace add (same as normal add).Damien George2017-04-05
|
* tests/basics: Add tests for raising ValueError when range() gets 0 step.Damien George2017-04-05
|
* py: Raise a ValueError if range() step is zero.Damien George2017-04-05
| | | | | Following CPython. Otherwise one gets either an infinite loop (if code is optimised by the uPy compiler) or possibly a divide-by-zero CPU exception.
* tools/pyboard: execpty: Use shell=False to workaround some curdir issues.Paul Sokolovsky2017-04-05
| | | | Without this, Zephyr's port "make test" doesn't work.
* zephyr/Makefile: Add "test" target, runs testsuite in QEMU.Paul Sokolovsky2017-04-05
|
* tools/pyboard: Add "exec" and "execpty" pseudo-devices support.Paul Sokolovsky2017-04-04
| | | | | | | | | | | | | | | | | | | | This allows to execute a command and communicate with its stdin/stdout via pipes ("exec") or with command-created pseudo-terminal ("execpty"), to emulate serial access. Immediate usecase is controlling a QEMU process which emulates board's serial via normal console, but it could be used e.g. with helper binaries to access real board over other hadware protocols, etc. An example of device specification for these cases is: --device exec:../zephyr/qemu.sh --device execpty:../zephyr/qemu2.sh Where qemu.sh contains long-long qemu startup line, or calls another command. There's a special support in this patch for running the command in a new terminal session, to support shell wrappers like that (without new terminal session, only wrapper script would be terminated, but its child processes would continue to run).