summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-12-12tests: Activate recursive_data.py test, now that io.StringIO is available.Paul Sokolovsky
2014-12-11tests: Add test for semantics of for-loop that optimisation can break.Damien George
2014-12-11py: Fix a semantic issue with range optimisation.Damien George
Now you can assign to the range variable within the for loop and it will still work. Partially addresses issue #565.
2014-12-11tests: Disable print_exception test when using native emitter.Damien George
2014-12-11tests: Fix print_exception test and re-enable it on Travis CI.Damien George
Issue was with uPy: on local machine with micropython-lib installed, io module is available. Not the case on Travis CI, where only _io module is available in uPy.
2014-12-11run-tests: Skip print_exception.py on TravisCI, as it irreproducibly fails.Paul Sokolovsky
TODO: Figure out what's wrong on Travis.
2014-12-10py: Tidy up a few function declarations.Damien George
2014-12-10py: Remove static from definition of pfenv_printf.Damien George
It's used by stmhal, but not unix.
2014-12-10py: Make functions static where appropriate.Damien George
2014-12-10unix: add unlink function to os moduleNikita Nazarenko
2014-12-10tests: Fix print_exception.py to work on Travis CI.Damien George
2014-12-10tests: Add test for print_exception() function.Paul Sokolovsky
2014-12-10docs: Add sys.print_exception().Paul Sokolovsky
2014-12-10py: Fix function type: () -> (void).Damien George
2014-12-09py: Allow builtins to be overridden.Damien George
This patch adds a configuration option (MICROPY_CAN_OVERRIDE_BUILTINS) which, when enabled, allows to override all names within the builtins module. A builtins override dict is created the first time the user assigns to a name in the builtins model, and then that dict is searched first on subsequent lookups. Note that this implementation doesn't allow deleting of names. This patch also does some refactoring of builtins code, creating the modbuiltins.c file. Addresses issue #959.
2014-12-09drivers, nrf24: Nonblocking send now uses send_start and send_done.adminpete
2014-12-09drivers, nrf24: Nonblocking send now done by generator.adminpete
2014-12-09drivers, nrf24: Add nonblocking send option etc.Peter Hinch
2014-12-08stmhal: Allow SPI.init to specify prescaler directly; improve SPI docs.Damien George
2014-12-08stmhal: Enhance pyb.freq to configure bus (AHB, APB1, APB2) freqs.Damien George
This is useful if you need precise control over the speed of peripherals (eg SPI clock).
2014-12-08modsys: Add sys.print_exception(exc, file=sys.stdout) function.Paul Sokolovsky
The function is modeled after traceback.print_exception(), but unbloated, and put into existing module to save overhead on adding another module. Compliant traceback.print_exception() is intended to be implemented in micropython-lib in terms of sys.print_exception(). This change required refactoring mp_obj_print_exception() to take pfenv_t interface arguments. Addresses #751.
2014-12-07stmhal: Allow network, uselect, usocket mods to be used by other ports.Damien George
Remove include of stm32f4xx_hal.h, replace by include of MICROPY_HAL_H where needed, and make it compile without float support. This makes these 3 modules much more generic and usable by other ports.
2014-12-06windows: define __USE_MINGW_ANSI_STDIO for all Windows compilers.Damien George
2014-12-06stmhal: Make SPI bus use DMA for transfers.Damien George
Uses DMA if interrupts are enabled, polling if they are disabled.
2014-12-06esp8266/README: Fix typos.Paul Sokolovsky
2014-12-05py: Rename mp_obj_int_get to mp_obj_int_get_truncated; fix struct.pack.Damien George
mp_obj_int_get_truncated is used as a "fast path" int accessor that doesn't check for overflow and returns the int truncated to the machine word size, ie mp_int_t. Use mp_obj_int_get_truncated to fix struct.pack when packing maximum word sized values. Addresses issues #779 and #998.
2014-12-05py: Fix printing of size_t entity; fix qemu-arm for changes to lexer.Damien George
2014-12-05unix-cpy: Fix build due to change in lexer API.Damien George
2014-12-05py: Optimise lexer by exposing lexer type.Damien George
mp_lexer_t type is exposed, mp_token_t type is removed, and simple lexer functions (like checking current token kind) are now inlined. This saves 784 bytes ROM on 32-bit unix, 348 bytes on stmhal, and 460 bytes on bare-arm. It also saves a tiny bit of RAM since mp_lexer_t is a bit smaller. Also will run a bit more efficiently.
2014-12-05docs: uzlib: Typo fix.Paul Sokolovsky
2014-12-05docs: Add quick docs for uzlib.Paul Sokolovsky
2014-12-04docs: Update network docs to reflect changes to code.Damien George
2014-12-04stmhal: Overhaul network drivers; has generic network protocol in C.Damien George
This patch overhauls the network driver interface. A generic NIC must provide a set of C-level functions to implement low-level socket control (eg socket, bind, connect, send, recv). Doing this, the network and usocket modules can then use such a NIC to implement proper socket control at the Python level. This patch also updates the CC3K and WIZNET5K drivers to conform to the new interface, and fixes some bugs in the drivers. They now work reasonably well.
2014-12-04drivers, wiznet5k: Add socket_reset; fix orderly shutdown in recv.Damien George
2014-12-04py: Allow bytes/bytearray/array to be init'd by buffer protocol objects.Damien George
Behaviour of array initialisation is subtly different for bytes, bytearray and array.array when argument has buffer protocol. This patch gets us CPython conformant (except we allow initialisation of array.array by buffer with length not a multiple of typecode).
2014-12-04docs: Add skeleton docs for ure module.Paul Sokolovsky
2014-12-02py, vm: Make unum a local variable for each opcode that uses it.Damien George
This makes no change to the generated code, but it's now easier to understand since unum is not a "global" variable anymore.
2014-12-02stmhal: Move RTC HAL init functions to rtc.c, where they belong.Damien George
So can remove unnecessary stm32f4xx_hal_msp.c file.
2014-12-02docs: Add links to LCD and AMP skin schematics.Damien George
2014-12-02docs: Add quick docs for ubinascii.Paul Sokolovsky
2014-12-02docs: Add quick docs for uhashlib.Paul Sokolovsky
2014-12-01docs: Sort "micro-library" module list alphabetically.Paul Sokolovsky
2014-12-01modmicropython: Move mem_info() and qstr_info() functions from unix port.Paul Sokolovsky
TODO: Merge useful functionality from modpyb too.
2014-11-30tools: Make pyboard.py have infinite timeout when running script.Damien George
This makes pyboard.py much more useful for long running scripts. When running a script via pyboard.py, it now waits until the script finishes, with no timeout. CTRL-C can be used to break out of the waiting if needed.
2014-11-30stmhal: Make pyb.[u]delay use systick with IRQs, busy loop otherwise.Damien George
pyb.delay and pyb.udelay now use systick if IRQs are enabled, otherwise they use a busy loop. Thus they work correctly when IRQs are disabled. The busy loop is computed from the current CPU frequency, so works no matter the CPU frequency.
2014-11-30py: Generalise and reduce code size of array +, += and .extend().Damien George
By using the buffer protocol for these array operations, we now allow addition of memoryview objects, and objects with "incompatible" typecodes (in this case it just adds bytes naively). This is an extension to CPython which seems sensible. It also reduces the code size.
2014-11-30Update documentation for the CAN classHenrik Sölver
2014-11-30py: Implement +, += and .extend for bytearray and array objs.Damien George
Addresses issue #994.
2014-11-29stmhal: Add USB_VCP.setinterrupt method, to disable CTRL-C.Damien George
2014-11-29esp8266: Add README.md.Damien George