os.VfsLfs2.mkfs(sdcard) TypeError: function takes 3 positional arguments but 4 were given #13111
-
I am trying to format a microSD card with LittleFS and I'm getting an error. Here's what I'm doing and the resulting error:
The card is 32G, currently formatted as FAT, and plugged into an SPI connected breakout board. I can access it from /sd by putting this in my boot.py:
I can successfully After commenting out the lines with Effectively, this:
I was assuming sdcard is a block device, but I'm thinking maybe not. I also tried this approach, trying to mirror what worked when mounting as FAT:
Same result... TypeError: function takes 3 positional arguments but 4 were given Can anyone tell me what I'm doing wrong? Is LittleFS just not meant for SD cards? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
The sdcard driver uses the "simple interface" while littlefs only implements the "extended interface". https://docs.micropython.org/en/latest/library/os.html#simple-and-extended-interface We need to update sdcard.py to support the extended interface (and really...deprecate the simple interface) |
Beta Was this translation helpful? Give feedback.
The sdcard driver uses the "simple interface" while littlefs only implements the "extended interface".
https://docs.micropython.org/en/latest/library/os.html#simple-and-extended-interface
We need to update sdcard.py to support the extended interface (and really...deprecate the simple interface)