Skip to content

Add read_file calls with prepared mem buffer. #22

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

abel-msk
Copy link

sd_mmc_card uses read_file method for file reading. Method creates vector class for reading, and return this instance.
This looks no good. This class may be destructed on function finished.
This is why the "sd_file_server" does not work in esp-idf env. (IMHO)
So, i add new method "read_file" with preallocated space as parameter.

It tested on ESP32S.

I am also planing to change sd_file_server for working with new method.

@n-serrette
Copy link
Owner

Thanks for your contribution, I will look at it once I have a little time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants