{"id":20313263,"url":"https://github.com/copych/sdmmc_esp32_read_only","last_synced_at":"2026-06-09T05:04:45.926Z","repository":{"id":222472682,"uuid":"757363273","full_name":"copych/SDMMC_ESP32_Read_Only","owner":"copych","description":"Simplified Read Only FAT32 implementation for SD MMC on ESP32 and ESP32S3","archived":false,"fork":false,"pushed_at":"2024-04-09T09:36:29.000Z","size":55,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-04T08:35:41.198Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/copych.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-14T10:45:41.000Z","updated_at":"2025-02-14T10:32:40.000Z","dependencies_parsed_at":"2025-01-14T12:28:32.593Z","dependency_job_id":"bfdd9a12-f3f3-4a32-bbad-5a52e17d8c52","html_url":"https://github.com/copych/SDMMC_ESP32_Read_Only","commit_stats":null,"previous_names":["copych/sdmmc_esp32_read_only"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/copych/SDMMC_ESP32_Read_Only","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/copych%2FSDMMC_ESP32_Read_Only","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/copych%2FSDMMC_ESP32_Read_Only/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/copych%2FSDMMC_ESP32_Read_Only/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/copych%2FSDMMC_ESP32_Read_Only/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/copych","download_url":"https://codeload.github.com/copych/SDMMC_ESP32_Read_Only/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/copych%2FSDMMC_ESP32_Read_Only/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34092291,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-09T02:00:06.510Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T18:10:13.266Z","updated_at":"2026-06-09T05:04:45.910Z","avatar_url":"https://github.com/copych.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"Simplified READ-ONLY FAT32 class for fast accessing and reading of (in my case WAV) files. \nCluster chains are to be pre-cached (on the application side) for directory files, and stored in memory as a collection of linear sector chain boundaries. Ideally, when no fragmentation appears, only a single pair of sectors (beginning/end) per file needed.\n\ncalls are like this:\n\n```\nSDMMC_FAT32 Card;\nSDMMC_FileReader Reader(\u0026Card);\n\nentry_t* entry;\n\nCard.begin();\n\nCard.testReadSpeed(READ_BUF_SECTORS /*sectors per read*/, 8 /*total MBytes to test*/);\n\n// List root folder\nCard.setCurrentDir(\"/\");\nCard.printCurrentDir();\n\nentry = Card.nextEntry();\nwhile (!entry-\u003eis_end) {\n    if (entry-\u003eis_dir) {\n      Card.setCurrentDir(entry-\u003ename);\n      Card.printCurrentDir();\n      break;\n    }\n    entry = Card.nextEntry();\n}\n\nstr_max_t str=\"\";\nReader.open(\"config.ini\"); \nwhile (Reader.available()) {\n    Reader.read_line(str);\n    DEBUG(str.c_str());\n}\nReader.close();\n\nCard.end();\n```\n\nIt is neither a product nor a code of beauty, but some stuff one can find useful for particular needs. For example, this may help with reading files from the SD with a reasonable good speed and constant low access time.\nFor example, standard Arduino ESP32 core lib gives ~5 ms lag before opening first file in the given directory, and ~20 ms lag for the 200th file, because of scanning directory entries.\nThis class allows addressing files directly by sectors, and reading of sector-aligned blocks.\n\nThis is what I have measured for an old random 16GB Card that I had.\n|sectors per read  |  reading speed, MB/s |\n|------------------|----------------------|\n|        1         |        0.90          |\n|        2         |        1.57          |\n|        4         |        2.82          |\n|        8         |        5.00          |\n|       16         |        7.79          |\n|       32         |       11.12          |\n|       64         |       13.85          |\n|      128         |       15.75          |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcopych%2Fsdmmc_esp32_read_only","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcopych%2Fsdmmc_esp32_read_only","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcopych%2Fsdmmc_esp32_read_only/lists"}