Это видео недоступно.
Сожалеем об этом.
Raspberry Pi Pico (RP2040) SD Card (Read & Write) with MicroPython and C/C++ | Digi-Key Electronics
HTML-код
- Опубликовано: 25 июл 2021
- SD cards are popular ways to store data that can be transferred between computers and consumer electronics (e.g. digital cameras). They can be found in the tiny microSD format and still store gigabytes of data. SD card protocol supports the faster 4-bit SD mode as well as the 1-bit SPI mode. Some microcontrollers support SD mode for faster transfers, but the SPI mode is simple and popular for low data-rate logging (e.g. sensor data and timestamps).
In this tutorial, we show you how to read and write to an SD card from a Raspberry Pi Pico using MicroPython and C/C++. We will demonstrate the simpler SPI format, as the Pico has a built-in SPI peripheral.
Note that you will need to format your SD card using the FAT32 filesystem on your operating system. Here are some guides to help you do that:
- Windows: helpdeskgeek.c...
- Mac: havecamerawill...
- Linux: linuxize.com/p...
A written tutorial along with all of the code in this video can be found here: www.digikey.co...
The sdcard.py driver for MicroPython can be found here: github.com/mic...
FATFS API documentation for interacting with files in MicroPython can be found here: docs.micropyth...
The third party library for working with SD cards in C/C++ can be found here: github.com/car...
FATFS API documentation for interacting with files in C can be found here: elm-chan.org/fs...
Product Links:
www.digikey.co...
www.digikey.co...
Related Videos:
Intro to Raspberry Pi Pico and RP2040 - MicroPython Part 1: Blink - • Intro to Raspberry Pi ...
Intro to Raspberry Pi Pico and RP2040 - C/C++ Part 1: VS Code and Blink - • Intro to Raspberry Pi ...
Intro to Raspberry Pi Pico and RP2040 - C/C++ Part 2: Debug with Picoprobe - • Intro to Raspberry Pi ...
Related Project Links:
www.digikey.co...
www.digikey.co...
www.digikey.co...
Maker.io - www.digikey.co...
Digi-Key’s Blog - TheCircuit www.digikey.co...
Connect with Digi-Key on Facebook / digikey.electronics
And follow us on Twitter / digikey
This tutorial is broken. The Micropython github page has changed, the sdcard lib is not at the link provided.🙁
Thanks for the very good overview and example.
I love this series!
5:22 the baud rate defined here is overridden by what is entered in the sdcard.py driver - just an fyi since it took me a few minutes to figure out why the speed wasn't changing :)
nice work and nice look as always.
i tested this with raspberry pi pico(c++ sdk) and it's doesnt work
Thanks a lot! Very usefull
OSErrorL [Error 19] ENODEV
Not sure why it is not recognizing.
Hi really thank you, i was wondering if with a MicroSD card catalex, can it be use that github in C?
Is it possible to have data from inputs / sensors be written to the pico so that they show up in the usb drive where one uploads the code?
thank you for sharing your knowledge!
anyway, could you try do your spi video with ad 343 sensor but with pio spi? i think that's interesting. thank you :)
is there a way to data log in the circuit python ?
getting an error message f_prinf failed and single block write failed
Hi, On digikey I can't seem to be able to leave a comment so I will leave one here.
Since you wrote the article the no-OS-FatFS-SD-SPI-RPi-Pico may have changed a bit ... I was unable to compile the code you shower with the current code.
Also the default pins on the pproject may have changed and don't match the wiring you are suggesting.
I added hw_conf.c in the add_executable line in CMakeLists.txt
add_executable(${NAME} ${NAME}.c hw_config.c)
It now builds but I've not yet tested if it actually works
Did you find a solution?, thanks
Error: importerror no module named pyb at 4.51. This is a fake sketch, there is no # at the comment "Example"...at line 8 and line 15.