Damien George
d5e81826ec
py: Reduce size of mp_obj_fun_native_t struct by packing ints.
11 years ago
Damien George
510477557d
py: Take out bitfield entries from their own structure.
Don't need to wrap bitfields in their own struct. Compiler does the
correct thing without it.
11 years ago
Damien George
98fb8935bc
stm: Reinstate code to handle CC3000 EXTI (commented out for now).
11 years ago
Damien George
1dc76af7bf
py: Remove name of var arg from macros with var args.
11 years ago
Damien George
c5ac2ac590
py: Start to implement shl/shr for mpz. Fix return void.
11 years ago
Damien George
f8a4fbbb79
stm: Open header file in text mode (in make-pins).
11 years ago
Damien George
43122c320b
Merge pull request #325 from dhylands/led
Update LED configuration
11 years ago
Damien George
4273498cb8
Merge pull request #324 from dhylands/board-check
Print an error if an invalid BOARD is specified
11 years ago
Damien George
c4361227ba
Merge pull request #318 from dhylands/exti
Add EXTI support
11 years ago
Damien George
e70700851a
Merge pull request #323 from dhylands/fix-float-print
Fix floating point printing of negative numbers in the range (0, -1.0)
11 years ago
Dave Hylands
34f66023d4
Update LED configuration
11 years ago
Dave Hylands
c3813ff50d
Print an error if a non-valid BOARD is specified.
11 years ago
Dave Hylands
49b5533000
Fix floating point printing of negative numbers in the range (0, -1.0)
11 years ago
Damien George
aca141269e
py: Fix mpn_sub, was increasing wrong source pointer.
Also change int -> machine_int_t where appropriate.
11 years ago
Damien George
2ee55c312d
stm: Add option to pyb_usb_dev_init() to use USB HID interface.
With this option selected, only HID on its own works, not VCP+HID.
11 years ago
Dave Hylands
ee31f71d39
Add EXTI support
Revamp usrsw to use new exti code.
Add user switch callback function.
11 years ago
Damien George
790eed6f93
stm: Make pendsv_nlr_jump work when debugging is enabled.
Stack layout is different when -g used, so need to handle the pendsv
jump differently. Addresses Issue #315 .
11 years ago
Damien George
ee462489f1
stm: Add USART enum for pyboard skin labels.
11 years ago
Damien George
ed73fcd7d2
Merge pull request #316 from iabdalkader/fatfs_lfn
Add Configurable LFN support to FatFS
11 years ago
mux
1e2cf746d4
Add Configurable LFN support to FatFS
11 years ago
Damien George
9982f2795d
Merge branch 'master' of github.com:micropython/micropython
11 years ago
Damien George
438c88dd2f
Add arbitrary precision integer support.
Some functionality is still missing (eg and, or, bit shift), and some
things are buggy (eg subtract).
11 years ago
Paul Sokolovsky
135002a086
Add basic super() test.
11 years ago
Damien George
2077397118
py: Put number parsing code together in parsenum.c.
11 years ago
Damien George
2613ffde43
py: Rename strtonum to mp_strtonum.
strtonum clashes with BSD function of same name, and our version is
different so warrants a unique name. Addresses Issue #305 .
11 years ago
Damien George
0379b55ab0
py: Fix casting and printing of small int.
11 years ago
Damien George
b25ef4db3b
Merge pull request #314 from pfalcon/parse-node-refactor
parse: Refactor parse node encoding to support full range of small ints.
11 years ago
Paul Sokolovsky
56e5ef203b
parse: Refactor parse node encoding to support full range of small ints.
Based on suggestion by @dpgeorge at
https://github.com/micropython/micropython/pull/313
11 years ago
Paul Sokolovsky
bbf0e2fe12
parse: Note that fact that parser's small ints are different than VM small int.
Specifically, VM's small ints are 31 bit, while parser's only 28. There's already
MP_OBJ_FITS_SMALL_INT(), so, for clarity, rename MP_FIT_SMALL_INT() to
MP_PARSE_FITS_SMALL_INT().
11 years ago
Paul Sokolovsky
1d30b11685
showbc: Update for recent int varlen storage refactor.
TODO: De-duplicate DECODE_UINT, etc. definitions.
11 years ago
Paul Sokolovsky
feacaa12ac
__import__: Catch relative import attempts and throw NotImplementedError.
11 years ago
Paul Sokolovsky
a8d31b28bc
emitbc: Correct buffer sizes for varlen int encoding.
Assuming we have truncating (floor) division, way to do ceiling division
by N is to use formula (x + (N-1)) / N. Specifically, 63 bits, if stored
7 bits per byte, require exactly 9 bytes. 64 bits overflow that and require
10 bytes.
11 years ago
Paul Sokolovsky
a1aba36feb
compile: Add comments ergarding non-implemented relative imports.
11 years ago
Damien George
4d79d5dd7c
py: Fix type of integer in decoding int.
11 years ago
Damien George
b74501c98f
Merge pull request #312 from pfalcon/int-varlen
Support varlen encoding for arbitrary int and uint numbers
11 years ago
Damien George
2e87c62cf6
stm: Update PYBOARD4 pin mapping.
11 years ago
Damien George
948a58d56e
Merge pull request #310 from dhylands/pin_map
Add pin mapping code.
11 years ago
Damien George
1b182a30d0
Merge branch 'master' of github.com:micropython/micropython
11 years ago
Damien George
302646625b
stm: Add RTC start-up info, and uPy bindings.
11 years ago
Paul Sokolovsky
fb7f94392d
import: Implement "from pkg.mod import sym" syntax properly.
http://docs.python.org/3.3/library/functions.html#__import__ :
"When the name variable is of the form package.module, normally, the
top-level package (the name up till the first dot) is returned, not
the module named by name. However, when a non-empty fromlist argument
is given, the module named by name is returned."
11 years ago
Paul Sokolovsky
047cd40313
Bytecode int varlen encoding: support arbitrary values for signed ints too.
11 years ago
Paul Sokolovsky
0f96ec8268
Bytecode uint varlen encoding: support arbitrary values.
11 years ago
Dave Hylands
51dabac096
Add pin mapping code.
This commit also introduces board directories and moves board
specific config into the appropriate board directory.
boards/stm32f4xx-af.csv was extracted from the STM32F4xx datasheet
and hand-tweaked.
make-pins.py takes boards/stm32f4xx-af.csv, boards/stm32f4xx-prefix.c,
and boards/BOARD-NAME/pins.csv as input and generates the file
build/pins_BOARD_NAME.c
The generated pin file for PYBOARD4 looks like this:
https://gist.github.com/dhylands/9063231
The generated pins file includes all of the supported alternate
functions, and includes upsupported alternate functions as comments.
See the commnet block at the top of stm/pin_map.c for details on
how to use the pin mapper.
I also went ahead and modified stm/gpio.c to use the pin mapper.
11 years ago
Damien George
46239413d0
stm: Implement mp_import_stat.
To follow up pull request #309 .
11 years ago
Paul Sokolovsky
4d0588df56
objint_longlong: Don't assert on invalid syntax, raise SyntaxError instead.
11 years ago
Damien George
517e1706bd
Merge pull request #309 from pfalcon/stm-sys-path
stm: Initialize sys.path with ["0:/", "0:/src", "0:/lib"].
11 years ago
Damien George
ff77dc567c
Merge pull request #307 from iabdalkader/master
Fix usart_obj_tx_char
11 years ago
Paul Sokolovsky
4aee119f94
stm: Initialize sys.path with ["0:/", "0:/src", "0:/lib"].
This is compatible with what search path was before sys.path refactor,
with addition of module library path ("0:/lib").
11 years ago
mux
d0ffda91cc
Fix usart_obj_tx_char
11 years ago
Damien George
f34947703a
Merge pull request #303 from dhylands/fix-netduino-disc
Fix build for netduino and stm32f4disc
11 years ago