summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-11-05unix: fast: Set initial module dict size big to have high pystone score.Paul Sokolovsky
For this, introduce MICROPY_MODULE_DICT_SIZE config setting.
2014-11-04docs: Bump version to 1.3.6.v1.3.6Damien George
This needs to be done before actually tagging the new version.
2014-11-04docs: Update front page to display date of last update.Damien George
2014-11-04docs: Add links from quickref to pyb classes.Damien George
2014-11-04docs: Add debounce tutorial; order Pin methods; add pull resistor info.Damien George
2014-11-03docs: Add pdf size info to datasheet links.Damien George
2014-11-03docs: Add skin imgs; change external links to micropython.org/resources.Damien George
2014-11-03docs: Adjust table spacing in topindex page.Damien George
2014-11-03py: Explicitly set uninitialised struct member to false.Damien George
Uninitialised struct members get a default value of 0/false, so this is not strictly needed. But it actually decreases code size because when all members are initialised the compiler doesn't need to insert a call to memset to clear everything. In other words, setting 1 extra member to 0 uses less code than calling memset. ROM savings in bytes: 32-bit unix: 100; bare-arm: 44; stmhal: 52.
2014-11-03py: Fix builtin callable so it checks user-defined instances correctly.Damien George
Addresses issue #953.
2014-11-03Merge branch 'szinya-master'Damien George
2014-11-03docs: Fix typo in Fading LEDsMárton Szinovszki
2014-11-02docs: Disable logo and add spacing to top index.Damien George
2014-11-02docs: Make custom index page; add more docs.Damien George
2014-11-02unix: Provide "fast" target to build interpreter for benchmarking.Paul Sokolovsky
This build is primarily intended for benchmarking, and may have random features enabled/disabled to get high scores in synthetic benchmarks. The intent is to show/prove that MicroPython codebase can compete with CPython, when configured appropriately. But the main MicroPython aim still remains to optimize for memory usage (which inevitibly leads to performance degradation in some areas on some workloads).
2014-11-02stmhal: Improve pyb.freq to allow 8 and 16MHz (not usable with USB).Damien George
Also restrict higher frequencies to have a VCO_OUT frequency below 432MHz, as specified in the datasheet. Docs improved to list allowed frequencies, and explain about USB stability.
2014-11-02py: Fix bug with right-shifting small ints by large amounts.Paul Sokolovsky
Undefined behavior in C, needs explicit check.
2014-10-31docs: Cleanup and update some docs.Damien George
2014-10-31tests: Add heapalloc.py.exp, since CPython can't generate it.Damien George
2014-10-31py: Make gc.enable/disable just control auto-GC; alloc is still allowed.Damien George
gc.enable/disable are now the same as CPython: they just control whether automatic garbage collection is enabled or not. If disabled, you can still allocate heap memory, and initiate a manual collection.
2014-10-31stmhal: Fix UART so bits counts number of data bits, not incl parity.Damien George
Addresses issue #950.
2014-10-31py: Add builtin round function.Damien George
Addresses issue #934.
2014-10-31docs: Add 2 images for tutorials.Damien George
2014-10-31docs: Import documentation from source-code inline comments.Damien George
The inline docs (prefixed with /// in .c files) have been converted to RST format and put in the docs subdirectory.
2014-10-31tools: Make gendoc.py able to output RST format.Damien George
2014-10-31stmhal: Update some inlined docs for network and CAN.Damien George
2014-10-31docs: Fix links to images and other parts of the docs.Damien George
2014-10-31docs: Add tutorial for fading LED using PWM, with fritzing imageShuning Bian
2014-10-31stmhal: Implement support for RTS/CTS hardware flow control in UART.Damien George
This is experimental support. API is subject to changes. RTS/CTS available on UART(2) and UART(3) only. Use as: uart = pyb.UART(2, 9600, flow=pyb.UART.RTS | pyb.UART.CTS)
2014-10-31stmhal: Add ioctl to USB_VCP object, so it works with select.Damien George
This patch also enables non-blocking streams on stmhal port. One can now make a USB-UART pass-through function: def pass_through(usb, uart): while True: select.select([usb, uart], [], []) if usb.any(): uart.write(usb.read(256)) if uart.any(): usb.write(uart.read(256)) pass_through(pyb.USB_VCP(), pyb.UART(1, 9600))
2014-10-30stmhal: Improve CAN print function.Damien George
2014-10-30tests: Added and adapted CAN tests for extended messagesHenrik Sölver
2014-10-30stmhal: Added support for extended CAN frames.Henrik Sölver
2014-10-30mpz: Fix 64bit msvc buildstijn
msvc does not treat 1L a 64bit integer hence all occurences of shifting it left or right result in undefined behaviour since the maximum allowed shift count for 32bit ints is 31. Forcing the correct type explicitely, stored in MPZ_LONG_1, solves this.
2014-10-31objstr: Allow to convert any buffer proto object to str.Paul Sokolovsky
Original motivation is to support converting bytearrays, but easier to just support buffer protocol at all.
2014-10-31py: mp_obj_str_get_str(): Work with bytes too.Paul Sokolovsky
It should be fair to say that almost in all cases where some API call expects string, it should be also possible to pass byte string. For example, it should be open/delete/rename file with name as bytestring. Note that similar change was done quite a long ago to mp_obj_str_get_data().
2014-10-30stmhal: Fix ptr arith in CC3000 code; enable network build in travis.Damien George
2014-10-30moductypes: Make .sizeof() work with bytearrays.Paul Sokolovsky
2014-10-30moductypes: Add test for accessing UINT8 array.Paul Sokolovsky
2014-10-30moductypes: When dereferencing a field which is array of uint8, use bytearray.Paul Sokolovsky
Because bytearrays are much friendlier to work with, e.g. they can be printed easily.
2014-10-30moductypes: Make sure we can apply .sizeof() to all aggregate types.Paul Sokolovsky
Before, sizeof() could be applied to a structure field only if that field was itself a structure. Now it can be applied to PTR and ARRAY fields too. It's not possible to apply it to scalar fields though, because as soon as scalar field (int or float) is dereferenced, its value is converted into Python int/float value, and all original type info is lost. Moreover, we allow sizeof of type definitions too, and there int is used to represent (scalar) types. So, we have ambiguity what int may be - either dereferenced scalar structure field, or encoded scalar type. So, rather throw an error if user tries to apply sizeof() to int.
2014-10-29py: Allow to override port config file and thus have >1 configs per port.Paul Sokolovsky
Use it like: make CFLAGS_EXTRA='-DMP_CONFIGFILE="<mpconfigport_my.h>"'
2014-10-29Fix errors after enabling -Wpointer-arithstijn
2014-10-29Add -Wpointer-arith flag to prevent problems with pointer arithmetic on void*stijn
2014-10-26docs: Increase size of pyboard pinout.v1.3.5Damien George
2014-10-26unix: Make -v dump memory info at exit.Paul Sokolovsky
Also, move bytecode dumps to -v -v, because they're too verbose for just -v.
2014-10-26docs: Add quick reference page, with pinout and short example code.Damien George
2014-10-26stmhal: Allow DAC object to be initialised from a pin.Damien George
Eg: dac = DAC(Pin.board.X5)
2014-10-26unix: Implement -m option (execute module from stdlib).Paul Sokolovsky
Support for packages as argument not implemented, but otherwise error and exit handling should be correct. This for example will allow to do: pip-micropython install micropython-test.pystone micropython -m test.pystone
2014-10-26stmhal: Improve REPL control codes; improve pyboard.py script.Damien George
Improvements are: 2 ctrl-C's are now needed to truly kill running script on pyboard, so make CDC interface allow multiple ctrl-C's through at once (ie sending b'\x03\x03' to pyboard now counts as 2 ctrl-C's). ctrl-C in friendly-repl can now stop multi-line input. In raw-repl mode, use ctrl-D to indicate end of running script, and also end of any error message. Thus, output of raw-repl is always at least 2 ctrl-D's and it's much easier to parse. pyboard.py is now a bit faster, handles exceptions from pyboard better (prints them and exits with exit code 1), prints out the pyboard output while the script is running (instead of waiting till the end), and allows to follow the output of a previous script when run with no arguments.