Jeff Epler
18548fc5d2
Merge pull request #4620 from tannewt/fix_struct_pack
...
Fix struct.pack with padding bytes
2021-04-19 20:43:20 -05:00
Scott Shawcroft
6620ac8bec
Fix py version of struct too.
2021-04-19 14:59:40 -07:00
Scott Shawcroft
e54e5e3575
Merge pull request #4564 from tyomitch/patch-1
...
[build] simplify makeqstrdata heuristic
2021-04-19 14:50:42 -07:00
Scott Shawcroft
5ccd5dc08b
Fix struct.pack with padding bytes
...
It used to validate the following arg could fit in a single byte.
Now, it always uses zero to pad.
2021-04-16 12:39:23 -07:00
Artyom Skrobov
d9e15adb01
[repl] Don't autocomplete globals after "import "
2021-04-14 12:16:28 -04:00
Artyom Skrobov
c6ee471b52
Merge branch 'main' of https://github.com/adafruit/circuitpython into patch-3
2021-04-13 00:32:19 -04:00
Scott Shawcroft
bd5a3a3ba4
Merge pull request #4583 from tyomitch/patch-2
...
[qstr] Separate hash and len from string data
2021-04-12 15:06:40 -07:00
Dan Halbert
c333acdbad
Merge pull request #4589 from hugodahl/feature/Remove-MicroPython-mention-in-error-messages
...
Make error messages platform agnostic
2021-04-10 21:30:17 -04:00
Hugo Dahl
36f3897fe3
Make error messages platform agnostic
...
Remove mentions of 'MicroPython' in error messages as they could lead to confusion in lesser-experienced users
2021-04-10 18:36:53 -05:00
Artyom Skrobov
dcee89ade7
build: simplify compute_huffman_coding()
...
No functional change.
2021-04-09 08:36:26 -04:00
Artyom Skrobov
68920682b6
[build] simplify makeqstrdata heuristic
...
The simpler one saves, on average, 51 more bytes per translation;
the biggest translation per board is reduced, on average, by 85 bytes.
2021-04-09 07:18:40 -04:00
Jeff Epler
3ce0b512f8
rasberrypi: IncrementalEncoder: factor out state machine
2021-04-08 16:25:47 -05:00
Artyom Skrobov
c3e40d50ab
[qstr] Separate hash and len from string data
...
This allows the compiler to merge strings: e.g. "update",
"difference_update" and "symmetric_difference_update"
will all point to the same memory.
Shaves ~1KB off the image size, and potentially allows
bigger savings if qstr attrs are initialized in qstr_init(),
and not stored in the image.
2021-04-06 12:58:42 -04:00
Artyom Skrobov
59fa9b01ad
[repl] Autocomplete builtin modules
2021-04-03 16:56:02 -04:00
Artyom Skrobov
1d55dee15b
[repl] Refactor autocomplete, extracting reusable parts
2021-04-03 16:54:34 -04:00
Artyom Skrobov
6e17db3286
[repl] Refactor autocomplete to reduce nesting
2021-04-03 15:54:36 -04:00
Jeff Epler
fb7b968b10
py.mk: locate ulab sources with shell-find.
2021-04-02 13:09:23 -05:00
Jeff Epler
dc9daba906
update ulab to 2.1.5
2021-04-02 13:09:23 -05:00
Artyom Skrobov
8056af8648
[synthio] add a simple MidiTrack implementation
2021-03-26 16:38:10 -04:00
Artyom Skrobov
d7dc3801ab
[ure] to save space, disable debug dumps by default
...
Has to stay enabled in unix port for the sake of tests/extmod/ure_debug.py
2021-03-26 13:24:20 -04:00
microDev
a52eb88031
run code formatting script
2021-03-15 19:27:36 +05:30
Dan Halbert
5ace7af933
disable default usb_cdc
2021-03-11 11:20:29 -05:00
Jeff Epler
1e5ffe1a53
Revert "circuitpy_mpconfig: Disable flash multi-partition"
...
This reverts commit 156ee4833a
.
2021-03-09 11:08:36 -06:00
Scott Shawcroft
b5a955a168
Merge pull request #4354 from jepler/disable-fat-partition
...
circuitpy_mpconfig: Disable flash multi-partition
2021-03-08 15:25:58 -08:00
Jeff Epler
156ee4833a
circuitpy_mpconfig: Disable flash multi-partition
...
This adds some additional code in mkfs which doesn't seem necessary, and
Disabling it saves 172 bytes flash.
Testing performed: Using a Feather M0 Adalogger, checked that
* an sdcard could still be mounted (using adafruit_sdcard)
* os.listdir() of "/" and "/sd" worked
* CIRCUITPY still mounted
2021-03-07 09:37:18 -06:00
Jeff Epler
4f040af481
vm: Make the speed-size trade-off compile time settable
...
.. and enable for all samd21 boards
2021-03-05 18:29:27 -06:00
Jeff Epler
7b359d7a8a
vm: Consolodate all dispatch instructions
...
Flash savings: 1268 bytes
Performance: 10,000 iteration loop .665 -> .676s (+1.7%)
2021-03-05 16:52:35 -06:00
Jeff Epler
28638df589
vm: cut vmentrytable size
...
This also adds a bit of code everywhere we DISPATCH(), but the net is
+232 bytes free on Feather M0 Adalogger.
Key assumption: All of the offsets in mp_execute_bytecode fit in 16 bits;
it is not clear whether the compiler will verify this assumption (e.g.,
by warning that a constant will be truncated)
2021-03-05 16:52:35 -06:00
Scott Shawcroft
e4f0e47d9f
Merge pull request #4233 from pewpew-game/displayio-group-list
...
displayio: make Group use a python list internally
2021-03-02 09:59:58 -08:00
Scott Shawcroft
d0eab5c561
Merge pull request #4256 from kmatch98/bt_cleanup
...
Add `bitmaptools` module
2021-03-01 18:24:12 -08:00
Radomir Dopieralski
24473b7983
Separate out mp_obj_list_insert for use in display.Group
...
Note that for some reason this makes the binary 500 bytes larger!
2021-02-27 21:13:55 +01:00
Radomir Dopieralski
e505c59ed8
Separate mp_obj_list_pop so it can be used outside of objlist.c
2021-02-27 20:52:38 +01:00
Scott Shawcroft
3f08cb47b8
Merge remote-tracking branch 'adafruit/main' into busio-uart-rp
2021-02-25 16:59:15 -08:00
Scott Shawcroft
52bc935fa7
A few minor fixes for corner cases
...
* Always clear the peripheral interrupt so we don't hang when full
* Store the ringbuf in the object so it gets collected when we're alive
* Make UART objects have a finaliser so they are deinit when their
memory is freed
* Copy bytes into the ringbuf from the FIFO after we read to ensure
the interrupt is enabled ASAP
* Copy bytes into the ringbuf from the FIFO before measuring our
rx available because the interrupt is based on a threshold (not
> 0). For example, a single byte won't trigger an interrupt.
2021-02-25 16:50:57 -08:00
Kevin Matocha
a7a4f93ff8
Updated build configs to turn off BITMAPTOOLS for smaller builds
2021-02-25 15:44:32 -06:00
Kevin Matocha
b720028642
Add bitmaptools module
2021-02-23 23:23:14 -06:00
Dan Halbert
7a4198885e
Fix typos for CIRCUITPY_USB_HID_SYS_CONTROL
2021-02-23 09:22:20 -05:00
Dan Halbert
93bf269c0d
Avoid pulling in extra float-uint64 routines
2021-02-21 12:05:03 -05:00
Jeff Epler
a04369e0f5
add ifdef-guard
2021-02-20 17:41:08 -06:00
Jeff Epler
646eb9a7db
py: memoryview: implement memoryview.cast if CPYTHON_COMPAT
2021-02-20 10:35:36 -06:00
Dan Halbert
076a7b7161
CIRCUITPY_BITOPS merge error
2021-02-19 15:30:27 -05:00
Dan Halbert
67406488d1
merge from upstream; re-alphabetize
2021-02-19 14:22:50 -05:00
Jeff Epler
72e8fb085c
remove debug print during build
2021-02-18 16:01:23 -06:00
Jeff Epler
7fd4567893
bitops: rename from _bit_transpose, describe the algorithm
2021-02-18 15:41:23 -06:00
Jeff Epler
9cf7d73c6c
core: add bit_transpose function
...
.. this version can only handle exactly 8 bits "across". The restriction
may be relaxed in a future revision.
2021-02-18 11:32:47 -06:00
Dan Halbert
ed49c02feb
add timeout; finish up for PR
2021-02-17 23:24:11 -05:00
Dan Halbert
93d788543c
Merge remote-tracking branch 'adafruit/main' into secondary-cdc
2021-02-15 20:03:53 -05:00
Bernhard Boser
f8f59598c7
memoryview is valid argument to exec
2021-02-15 10:05:57 -08:00
Dan Halbert
d54b5861a3
wip
2021-02-12 19:01:14 -05:00
Dan Halbert
f0564b4986
merge from upstream; complicated webusb merge
2021-02-11 18:50:02 -05:00