Jeff Epler
774f6ac6ab
Switch to using MP_ERROR_TEXT instead of translate, globally
2023-10-30 09:49:06 +01:00
Dan Halbert
2c0fa0f7dc
initial merge from v1.20.0; just satisifying conflicts
2023-09-19 11:10:12 -04:00
Dan Halbert
0d2c3c3f08
wip: continuing compilation fixes; mp_obj_alloc everywhere
2023-08-07 20:45:57 -04:00
Dan Halbert
d9d27a3e31
Fix signature of `mkfs()`
2023-03-21 10:30:03 -04:00
Isaac Benitez
9e630a565e
Updated block_device type annotation
2023-03-19 15:08:29 -07:00
Dan Halbert
ca292f3427
Turn off mkfs FAT32 on all SAMD21 builds; note in doc
2023-03-17 12:18:24 -04:00
Dan Halbert
5569f101a7
Document that storage.VfsFat.mkfs() is a @staticmethod
2023-03-17 10:50:07 -04:00
MicroDev
4ef363a797
improve dualbank and storage extension docs
2023-01-29 23:16:45 +05:30
s-ol
99b8564e8f
Add VfsFat.readonly property for getting current state
...
Previously the only other way of determining whether the Vfs has been mounted
read-write or read-only appears to be to attempt a write operation and detect a
possible OSError.
It wasn't possible for the user code to keep track of the state of the state
since the boot VM has to decide whether to (re)mount read-write or read-only,
but can't (easily) pass this information on to the runtime VM.
2022-12-08 14:45:24 +01:00
microDev
728fea4ca4
add storage extension python api
2022-10-13 09:53:33 +05:30
Jeff Epler
907c5d387f
Tweak black_bindings
...
Originally, black_bindings found each contiguous "//|" block and sent
it to black independently. This was slower than it needed to be.
Instead, swap the comment prefix: when running black, take off
"//|" prefixes and put "##|" prefixes on all un-prefixed lines.
Then, after black is run, do the opposite operation
This more than doubles the overall speed of "pre-commit run --all",
from 3m20s to 55s CPU time on my local machine (32.5s to under 10s
"elapsed" time)
It also causes a small amount of churn in the bindings, because
black now sees enough context to know whether one 'def' follows another
or ends the 'def's in a 'class'. In the latter case, it adds an extra
newline, which becomes a "//|" line.
I'm less sure why a trailing comma was omitted before down in
rp2pio/StateMachine.c but let's roll with it.
2022-09-30 11:18:13 -05:00
Jeff Epler
b2cc8d2aad
run black_bindings across all bindings
2022-09-27 15:21:42 -05:00
Jeff Epler
c415c13517
mend broken doc block
...
Since black_bindings.py will pass each contiguous
"//|"-block to black independently, they must each be a fully
formed Python item.
2022-09-27 15:19:31 -05:00
Scott Shawcroft
9d10a3da66
Conditionalize LTO
2022-05-27 12:59:54 -07:00
Alec Delaney
cb3932ce29
Make other documentation links prettier
2022-05-13 11:51:30 -04:00
Alec Delaney
ba4a253e77
Add link to CPY Essentials Learn guide for storage module
2022-05-04 14:04:07 -04:00
Jeff Epler
621953c960
Additional missing-prototypes fixes
...
I think this correctly enables missing-prototypes in atmel-samd
and raspberrypi ports.
2021-11-10 10:55:53 -06:00
Dan Halbert
1acafbf675
Fix n_args_min on many MP_DEFINE_CONST_FUN_OBJ_KW()
2021-10-07 16:55:19 -04:00
Rob Capellini
1c8828223f
Convert more modules to use MP_REGISTER_MODULE
...
Convert neopixel_write, onewireio, ps2io, pulseio, pwmio, rainbowio, random, rgbmatrix, rotaryio, rtc, sdcardio, sharpdisplay, _stage, storage, struct, supervisor, synthio, touchio, traceback, usb_cdc, usb_hid, usb_midi, and vectorio modules to use MP_REGISTER_MODULE.
Related to #5183 .
2021-08-30 22:29:51 -04:00
Scott Shawcroft
d2860b58b0
Check background pending before sleep
...
There is a race between when we run background tasks and when we
sleep. If an interrupt happens between the two, then we may delay
executing the background task. On some ports we checked this for
TinyUSB already. On iMX RT, we didn't which caused USB issues.
This PR makes it more generic for all background tasks including
USB.
Fixes #5086 and maybe others.
2021-08-19 12:18:13 -07:00
Dan Halbert
fa6c06fb38
count in/out endpoints; allow more usb modules on low-endpoint boards
2021-05-13 21:59:02 -04:00
Dan Halbert
fc8e1c4c2e
address review comments
2021-05-05 12:35:12 -04:00
Dan Halbert
adc3d7d55e
update Python API according to review comments
2021-05-03 22:29:02 -04:00
Dan Halbert
cc95b71d64
fix type annotations
2021-04-30 09:40:40 -04:00
Dan Halbert
f06d54524d
merge from adafruit
2021-04-28 23:48:26 -04:00
Scott Shawcroft
76033d5115
Merge MicroPython v1.11 into CircuitPython
2021-04-26 15:47:41 -07:00
Dan Halbert
6cb751ab06
wip: revamp API names
2021-04-14 22:10:09 -04:00
Dan Halbert
4a7e129287
wip: latent usb device enabling/disabling
2021-04-13 23:33:44 -04:00
microDev
a52eb88031
run code formatting script
2021-03-15 19:27:36 +05:30
Taku Fukada
56c898da80
Modify some Python stubs
2020-08-07 01:01:28 +09:00
Taku Fukada
54a342a7f5
Add and correct some type hints
2020-07-24 18:20:03 +09:00
dherrada
612c6bb86b
Merge branch 'main' into type_hints
2020-07-17 14:55:30 -04:00
Diego Elio Pettenò
34b4993d63
Add license to some obvious files.
2020-07-06 19:16:25 +01:00
dherrada
45b6e0174e
Added type hints to storage
2020-07-03 15:38:40 -04:00
dherrada
d0d949cd24
Made every init return None
2020-07-03 14:23:34 -04:00
Jeff Epler
89bd87d9fc
shared-bindings: Fix docs of storage.VfsFat
...
This is almost, but not entirely, a whitespace change.
"..." was missing or mis-placed in several places
The invalid syntax 'def f(self, ):' was used in several places.
2020-05-31 10:35:42 -05:00
Scott Shawcroft
4e8de3c554
Swap sphinx to autoapi and the inline stubs
2020-05-12 17:28:24 -07:00
dherrada
603df58f97
Did stage, socket, storage
2020-05-11 13:40:02 -04:00
Scott Shawcroft
cfe24b8532
Improve rST consistency for rst2pyi use
2019-05-30 19:02:47 -07:00
Scott Shawcroft
daee83c10b
Fix mount doc
2019-02-21 13:23:02 -08:00
Scott Shawcroft
1a0596a2fb
Add option to disable the concurrent write protection
...
This allows writing to the filesystem from the host computer and
CircuitPython by increasing the risk of filesystem corruption.
2019-02-21 10:45:41 -08:00
Scott Shawcroft
933add6cd8
Support internationalisation.
2018-08-07 14:58:57 -07:00
Dan Halbert
e2e01efa84
compiles and runs; hangs on import storage;storage.VfsFat.<tab>
2018-07-13 22:51:10 -04:00
Dan Halbert
5f98953ed8
esp8266 and nrf: raise NotImplementedError
2018-04-10 12:08:41 -04:00
Dan Halbert
aa8c262d14
add storage.erase_filesystem() to erase and reformat CIRCUITPY
2018-04-09 12:52:42 -04:00
Jeff Epler
34f5498760
Document storage.VfsFat more thoroughly
2018-03-27 21:28:19 -05:00
Jeff Epler
c08f5a3a00
Add storage.getmount to retrieve the mount object associated with a path
2018-03-27 21:28:18 -05:00
Scott Shawcroft
bf05183158
Merge remote-tracking branch 'adafruit/2.x' into merge_2x
2018-02-27 15:24:16 -08:00
Scott Shawcroft
20dd3b1e43
Delete a bunch of docs, drivers and examples not relevant to CircuitPython.
...
This fixes #345 and fixes #215 .
2018-02-20 17:34:59 -08:00
Dan Halbert
72c911be97
Support SPI flash chips for CIRCUITPY, using non-DMA SPI for now.
2017-11-27 21:00:24 -05:00