Damien George
d779b9642f
tests: Wait for just over 1 sec when testing RTC.
Waiting for 1000ms between seconds of RTC is sometimes too quick.
Waiting for 1001ms is enough for the RTC to pass 1 second.
10 years ago
Damien George
244476e3e6
stmhal: For non-debug compile, enable CC/LD opt to remove dead code.
Saves over 35k ROM due to elimination of unused HAL functions. All
tests pass.
Addresses issue #702 .
10 years ago
Damien George
c84aa41990
Merge branch 'danpeirce-master'
10 years ago
Dan Peirce
f0c3a7e781
teensy/README.md (corrected typo)
10 years ago
Dan Peirce
6009309c33
modified: teensy/README.md
Updated teensy/README.md to reflect change in build process (teensyduino is no
longer required for build).
10 years ago
Damien George
e6c0dff967
py: Viper can now store to global.
10 years ago
Damien George
a5190a7dac
py: Fix typing of viper locals; allow default types in annotation.
10 years ago
Damien George
2ac4af6946
py: Allow viper to have type annotations.
Viper functions can now be annotated with the type of their arguments
and return value. Eg:
@micropython.viper
def f(x:int) -> int:
return x + 1
10 years ago
Damien George
6be0b0a8ec
py: Clean up and simplify functions in scope; add STATIC in compiler.
Some small code clean-ups that result in about 80 bytes ROM saving for
stmhal.
10 years ago
Damien George
bf133f7737
stmhal: Resolve question in comment about timer clock.
10 years ago
Damien George
2c781eabbd
Merge pull request #798 from stinos/msvc-alignof
msvc: Use built-in alignof
10 years ago
Damien George
9b7a8ee8f1
py: Fix mult by negative number of tuple, list, str, bytes.
Multiplication of a tuple, list, str or bytes now yields an empty
sequence (instead of crashing). Addresses issue #799
Also added ability to mult bytes on LHS by integer.
10 years ago
stijn
8cce8b7c4c
msvc: Use built-in alignof
This also fixes a 'unnamed type definition in parentheses' warning on the
alignof implementation define in binary.c
10 years ago
Damien George
9d02780eaf
Merge branch 'pfalcon-modzlibd'
10 years ago
Damien George
1ddd844815
extmod: Finish rename of zlib to zlibd; enable zlibd on stmhal.
10 years ago
Paul Sokolovsky
5073d3da07
tests: Add test for zlibd module.
10 years ago
Paul Sokolovsky
8882c20b8f
modzlibd: Add tinfl.c from miniz SVN repo, r63.
The only change is line-ending convesion to LF.
10 years ago
Paul Sokolovsky
510296f25a
modzlibd: Decompress part of "zlib" module, based on miniz tinfl.c .
10 years ago
Damien George
75ec22bf11
py: #if guard qstrs that are optional.
Also disable gc module on bare-arm port.
10 years ago
Damien George
105e32f1a5
stmhal: Enable moductypes by default.
Also fixes compiler error in moductypes when compiled without debugging.
Addresses issue #778 .
10 years ago
Damien George
f20375eedd
py: Add .real and .imag attributes to complex numbers.
10 years ago
Damien George
bb91f1195a
py: Improve range: add len, subscr, proper print.
Can now index ranges with integers and slices, and reverse ranges
(although reversing is not very efficient).
Not sure how useful this stuff is, but gets us closer to having all of
Python's builtins.
10 years ago
Damien George
4c03b3a899
py: Implement builtin reversed() function.
reversed function now implemented, and works for tuple, list, str, bytes
and user objects with __len__ and __getitem__.
Renamed mp_builtin_len to mp_obj_len to make it publically available (eg
for reversed).
10 years ago
Damien George
69c5fe1df6
py: Make a function static; replace NULL with MP_OBJ_NULL.
10 years ago
Damien George
2eb1f604ee
py, objstr: Optimise bytes subscr when unicode is enabled.
Saves code bytes and makes it faster, so why not?
10 years ago
Damien George
7703d71938
py, modcmath: Fix doc comment, and add some more of them.
10 years ago
Paul Sokolovsky
9749b2fb0d
objstr: Make sure that bytes are indexed as bytes, not as unicode.
Fixes #795 .
10 years ago
Damien George
6e6bcccdc1
Merge branch 'master' of github.com:micropython/micropython
10 years ago
Damien George
101d87da6a
stmhal: Working STM32F4DISC accelerometer, via Python script.
Thanks to David Siorpaes.
10 years ago
Paul Sokolovsky
0c5498540b
objstr: split(): check arg type consistency (str vs bytes).
Similar to other methods and following CPython3 strictness.
10 years ago
Paul Sokolovsky
ecca53bd34
py: binary.c: Properly implement alignment for native unpacked structs.
10 years ago
Paul Sokolovsky
2831a8f800
modsocket: .recv() returns bytes object.
10 years ago
Damien George
4ef26c14b1
doc: Fix up a few docs in sys module.
10 years ago
Damien George
30dd23aa7f
doc: Document gc, sys, math, cmath.
10 years ago
Damien George
0c64c634ca
stmhal: Add sys.platform string to PYBv1.0 (it's "pyboard").
10 years ago
Damien George
c4ee39dd63
tools, gendoc: Output small descr about module TOC.
10 years ago
Paul Sokolovsky
5f930337bc
objarray: Implement equality testing between arrays and other buffers.
10 years ago
Paul Sokolovsky
7133d91773
py: mp_buffer_info_t::buf may be valid, but NULL for empty objects.
This happens for example for zero-size arrays. As .get_buffer() method now
has explicit return value, it's enough to distinguish success vs failure
of getting buffer.
10 years ago
Paul Sokolovsky
5f47ebbf82
moductypes: Remove debug inclusion of stdio.h .
10 years ago
Damien George
2605df3346
stmhal, pin: Save 140 bytes ROM by simplifying pin_print function.
10 years ago
Damien George
04019e365f
stmhal, pin: Simplify default value for alternate function init.
10 years ago
Damien George
590b2abdfc
tools, gendoc: Put module TOC/index in module/ directory.
10 years ago
Damien George
ea439e59d9
stmhal: Start of documentation for modos and modtime.
10 years ago
Damien George
ef7a066c9c
tools, gendoc: Allow constants at module level; gen module index.
Addresses some issues from #585 .
10 years ago
Damien George
4162271181
Merge branch 'dhylands-pin-af'
10 years ago
Damien George
b92e7533d3
tests, pyb: Update pin test.
10 years ago
Damien George
284efa89ae
stmhal/teensy: Use _ instead of - in source file names.
Trying to move towards consistency, let's use _ exclusively in names of
source files (eg .c, .h, .csv).
10 years ago
Damien George
4b67463be1
stmhal: Fix documentation; remove ability to specify af by str.
10 years ago
Damien George
5b7c0c437b
stmhal: Comment out unused functions.
10 years ago
Damien George
196773505a
Merge branch 'pin-af' of https://github.com/dhylands/micropython into dhylands-pin-af
10 years ago