Skip to content
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

Unreadable SD card #541

Open
valera39 opened this issue Oct 31, 2024 · 10 comments
Open

Unreadable SD card #541

valera39 opened this issue Oct 31, 2024 · 10 comments
Labels

Comments

@valera39
Copy link

Hello Dear Wolle!
I had the same error again as I wrote earlier. Suddenly the radio froze and after a forced reboot the memory card suddenly stopped reading, the files on it became like this
Annotation 2024-10-29 121130

@valera39
Copy link
Author

I formatted the card again and copied the files from the archive and the radio booted again.
Why is this happening?

@valera39
Copy link
Author

And here's the same problem again:
ESP32 Chip: ESP32-S3
Arduino Version: 3.0.5
ESP-IDF Version: 5.1.4
MiniWebRadio Version 3.5p - Oct 29/2024
ARDUINO_LOOP_STACK_SIZE 8192 words (32 bit)
FLASH size 16777216 bytes, speed 80 MHz
CPU speed 240 MHz
SDMMC speed 80 MHz
TFT speed 40 MHz
PSRAM total size: 6015520 bytes
RESET_REASON: Reset due to power-on event

00:00:00
00:00:00 ***************************
00:00:00 * MiniWebRadio V3 *
00:00:00 ***************************
00:00:00
00:00:00 setup: .... Arduino is pinned to core 1
00:00:00 tft_info: . init ILI9488
00:00:00 setup: .... Init SD card
00:00:00 setup: .... SD card found, 29789.5 MB by 29818.0 MB free
E (319) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (320) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (322) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x107
E (329) diskio_sdmmc: sdmmc_write_blocks failed (263)
E (335) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (342) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (348) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (355) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 1425][E][vfs_api.cpp:99] open(): /sdcard/settings.json does not exist, no permits for creation
[ 1445][E][main.cpp:460] operator()(): index "volume": not found
[ 1452][E][main.cpp:460] operator()(): index "volumeSteps": not found
[ 1459][E][main.cpp:460] operator()(): index "ringVolume": not found
[ 1466][E][main.cpp:460] operator()(): index "volumeAfterAlarm": not found
[ 1474][E][main.cpp:460] operator()(): index "BTvolume": not found
[ 1481][E][main.cpp:460] operator()(): index "BTpower": not found
[ 1488][E][main.cpp:460] operator()(): index "alarmtime_sun": not found
[ 1495][E][main.cpp:460] operator()(): index "alarmtime_mon": not found
[ 1503][E][main.cpp:460] operator()(): index "alarmtime_tue": not found
[ 1510][E][main.cpp:460] operator()(): index "alarmtime_wed": not found
[ 1518][E][main.cpp:460] operator()(): index "alarmtime_thu": not found
[ 1525][E][main.cpp:460] operator()(): index "alarmtime_fri": not found
[ 1533][E][main.cpp:460] operator()(): index "alarmtime_sat": not found
[ 1540][E][main.cpp:460] operator()(): index "alarm_weekdays": not found
[ 1548][E][main.cpp:460] operator()(): index "timeAnnouncing": not found
[ 1555][E][main.cpp:460] operator()(): index "mute": not found
[ 1562][E][main.cpp:460] operator()(): index "brightness": not found
[ 1569][E][main.cpp:460] operator()(): index "sleeptime": not found
[ 1576][E][main.cpp:460] operator()(): index "station": not found
[ 1583][E][main.cpp:460] operator()(): index "toneLP": not found
[ 1590][E][main.cpp:460] operator()(): index "toneBP": not found
[ 1596][E][main.cpp:460] operator()(): index "toneHP": not found
[ 1603][E][main.cpp:460] operator()(): index "balance": not found
[ 1610][E][main.cpp:460] operator()(): index "timeFormat": not found
[ 1617][E][main.cpp:460] operator()(): index "Timezone_Name": not found
[ 1625][E][main.cpp:460] operator()(): index "Timezone_String": not found
[ 1632][E][main.cpp:460] operator()(): index "lastconnectedhost": not found
[ 1640][E][main.cpp:460] operator()(): index "lastconnectedfile": not found
[ 1648][E][main.cpp:460] operator()(): index "sleepMode": not found
[ 1655][E][main.cpp:460] operator()(): index "cur_AudioFileNr": not found
[ 1663][E][main.cpp:460] operator()(): index "cur_AudioFolder": not found
[ 1670][E][main.cpp:460] operator()(): index "state": not found
E (614) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (614) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (616) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x107
E (624) diskio_sdmmc: sdmmc_write_blocks failed (263)
E (629) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (637) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (643) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (650) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (656) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (663) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (669) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (676) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 1745][E][vfs_api.cpp:310] VFSFileImpl(): fopen(/sdcard/stations.json) failed
E (701) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (702) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (704) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x107
E (711) diskio_sdmmc: sdmmc_write_blocks failed (263)
E (717) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (724) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (730) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (737) diskio_sdmmc: sdmmc_write_blocks failed (265)
00:00:00 AUDIO_info: file "/common/m/MiniWebRadioV3.jpg" not found
E (754) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (757) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (763) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (771) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (777) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (784) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (790) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (797) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 1866][E][vfs_api.cpp:310] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 1885][E][main.cpp:575] updateSettings(): file "settings.json" not found
00:00:00 setup: .... seek for WiFi networks
E (830) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (830) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (836) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (843) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 1913][E][vfs_api.cpp:99] open(): /sdcard/networks.csv does not exist, no permits for creation
[ 4756][E][WiFiMulti.cpp:306] run(): [WIFI] no matching wifi found!
00:00:00 WiFI_info: WiFi credentials are not correct

@valera39
Copy link
Author

valera39 commented Oct 31, 2024

Changing the card didn't help
Lowering the frequency didn't help either
Returned to the default speed value.
The bluetooth module is also not visible again.
ESP32 Chip: ESP32-S3
Arduino Version: 3.0.7
ESP-IDF Version: 5.1.4
MiniWebRadio Version 3.5p - Oct 29/2024
ARDUINO_LOOP_STACK_SIZE 8192 words (32 bit)
FLASH size 16777216 bytes, speed 80 MHz
CPU speed 240 MHz
SDMMC speed 80 MHz
TFT speed 40 MHz
PSRAM total size: 8374804 bytes
RESET_REASON: Reset due to power-on event

00:00:00
00:00:00 ***************************
00:00:00 * MiniWebRadio V3 *
00:00:00 ***************************
00:00:00
00:00:00 setup: .... Arduino is pinned to core 1
00:00:00 tft_info: . init ILI9488
00:00:00 setup: .... Init SD card
00:00:00 setup: .... SD card found, 7575.3 MB by 7595.0 MB free
00:00:00 setup: .... seek for WiFi networks
00:00:00 WiFI_info: add SSID: mySSID
00:00:00 WiFI_info: add SSID: ASUS_AC66U_RPT
00:00:00 WiFI_info: add SSID: ASUS_AC66U
00:00:00 WiFI_info: add SSID: Honor
[ 4786][W][STA.cpp:537] disconnect(): STA already disconnected.
[ 4902][W][STA.cpp:135] _onStaArduinoEvent(): Reason: 2 - AUTH_EXPIRE
[ 4910][W][STA.cpp:537] disconnect(): STA already disconnected.
00:00:00 WiFI_info: Connecting WiFi...
00:00:00 WiFI_info: mDNS name: MiniWebRadio
00:00:00 setup: .... connected to Honor, IP address is 192.168.43.214, Received Signal Strength -34 dB
00:00:00 ftpServer: Buffers allocated: 4622 bytes
00:00:00 rtime_info: Initializing SNTP
00:00:00 AUDIO_info: commFMT = Philips
00:00:00 setup: .... number of saved stations: 26
00:00:00 setup: .... number of saved favourites: 21
00:00:00 setup: .... current station number: 2
00:00:00 setup: .... current volume: 21
00:00:00 setup: .... volume steps: 21
00:00:00 setup: .... volume after alarm: 12
00:00:00 setup: .... last connected host: https://stream.cassiopeia-station.ru:1045/stream
00:00:00 setup: .... connection timeout: 2500 ms
00:00:00 setup: .... connection timeout SSL: 3500 ms
00:00:00 action: ... switch to station 2
00:00:00 AUDIO_info: PSRAM found, inputBufferSize: 638965 bytes
00:00:00 AUDIO_info: buffers freed, free Heap: 142467 bytes
00:00:00 AUDIO_info: connect to: "stream.cassiopeia-station.ru" on port 1045 path
"/stream"
00:00:00 AUDIO_info: SSL has been established in 684 ms, free Heap: 142095 bytes
00:00:00 setup: .... Ambient Light Sensor BH1750 found
00:00:00 bitRate: 320Kbit/s
00:00:00 StationName: Всесоюзное радио онлайн
00:00:00 AUDIO_info: MP3Decoder has been initialized, free Heap: 141211 bytes , free stack 5720 DWORDs
00:00:00 lastURL: .. https://stream.cassiopeia-station.ru:1045/stream
00:00:00 Audiocodec: MP3
00:00:00 ftpServer: Ftp server waiting for connection on port 21
00:00:00 BT-Emitter: KCX_BT_Emitter not found
00:00:00 AUDIO_info: stream ready
00:00:00 AUDIO_info: syncword found at pos 0
00:00:00 AUDIO_info: MPEG-2.5, Layer I
00:00:00 AUDIO_info: Channels: 2
00:00:00 AUDIO_info: SampleRate: 44100
00:00:00 AUDIO_info: BitsPerSample: 16
00:00:00 AUDIO_info: BitRate: 320000
00:00:00 StreamTitle: Соловьиная роща - Вероника Круглова - Тревожный стук
00:14:36 DLNA_server: 0 media server found
00:14:43 action: ... current volume is 21
00:14:43 click on .. backpane
00:14:45 click on .. backpane
00:14:45 click on .. backpane
00:14:46 click on .. backpane
00:14:48 action: ... current volume is 20
00:14:48 click on .. sdr_RA_volume
00:14:48 click on .. sdr_RA_volume
00:14:48 action: ... current volume is 19
00:14:48 action: ... current volume is 18
00:14:48 action: ... current volume is 17
E (25658) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (25658) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 26612][E][vfs_api.cpp:280] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 26631][E][main.cpp:575] updateSettings(): file "settings.json" not found
00:14:48 action: ... current volume is 13
00:14:48 click on .. sdr_RA_volume
00:14:49 action: ... current volume is 8
00:14:49 click on .. sdr_RA_volume
00:14:49 action: ... current volume is 7
00:14:49 click on .. sdr_RA_volume
00:14:49 action: ... current volume is 6
00:14:49 click on .. sdr_RA_volume
00:14:49 action: ... current volume is 5
00:14:49 click on .. sdr_RA_volume
E (29849) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (29850) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (29852) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (29860) diskio_sdmmc: sdmmc_write_blocks failed (265)
00:14:52 AUDIO_info: file "/common/m/RSSI4.bmp" not found
E (29895) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (29896) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (29899) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (29906) diskio_sdmmc: sdmmc_write_blocks failed (265)
00:14:52 AUDIO_info: file "/common/m/RSSI4.bmp" not found
E (35652) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (35653) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (35655) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (35663) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (35670) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (35676) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (35683) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (35690) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 36647][E][vfs_api.cpp:310] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 36666][E][main.cpp:575] updateSettings(): file "settings.json" not found
E (45656) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (45657) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (45660) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (45667) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (45673) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (45680) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (45687) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (45694) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 46651][E][vfs_api.cpp:310] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 46670][E][main.cpp:575] updateSettings(): file "settings.json" not found
E (55651) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (55651) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (55654) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (55661) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (55668) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (55675) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (55682) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (55688) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 56645][E][vfs_api.cpp:310] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 56664][E][main.cpp:575] updateSettings(): file "settings.json" not found
E (65652) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (65653) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (65655) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (65663) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (65669) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (65676) diskio_sdmmc: sdmmc_write_blocks failed (265)
E (65683) sdmmc_cmd: sdmmc_write_sectors_dma: sdmmc_send_cmd returned 0x109
E (65690) diskio_sdmmc: sdmmc_write_blocks failed (265)
[ 66647][E][vfs_api.cpp:310] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 66666][E][main.cpp:575] updateSettings(): file "settings.json" not found

@valera39
Copy link
Author

valera39 commented Oct 31, 2024

Did a full cleanup, after active use and several reboots so far the card is readable
What does this error mean?
E (97987) sdmmc_cmd: sdmmc_read_sectors_dma: sdmmc_send_cmd returned 0x107
E (97988) diskio_sdmmc: sdmmc_read_blocks failed (263)
[ 98941][E][vfs_api.cpp:280] VFSFileImpl(): fopen(/sdcard/settings.json) failed
[ 98960][E][main.cpp:575] updateSettings(): file "settings.json" not found

My head's not thinking straight anymore, so I'm going to bed.

@schreibfaul1
Copy link
Owner

Ooh, read error from the SD card. This usually has a mechanical cause. Perhaps it is a contact problem or a bad solder joint.

@skassel2024
Copy link

Hello valera39,
I also had the problem with the SD card at the beginning. See my answer in
issue #538. At that time, one of the three diodes was defective, so that the voltage to TFT was below 3V. It is also better to bridge the three resistors on the display to the SD socket.

@valera39
Copy link
Author

valera39 commented Nov 1, 2024

skassel2024
Thanks for the advice, but I think my power supply and contacts are fine. I can not understand why there is periodic overwriting of files in unreadable format (see my first post in the thread). This has never happened before and does not happen now on other radios I have built, but on earlier firmware versions.

@schreibfaul1
Copy link
Owner

@valera39
this is most likely a mechanical problem, sdmmc_send_cmd returned 0x109 means CRC error.
Or your SD card does not manage 80MHz, then you can lower the frequency.

@valera39
Copy link
Author

valera39 commented Nov 2, 2024

The card may have started to fail even though it's fairly new. I tried different frequencies and left it at default. I put in another card and so far everything is working
I'll be watching, thanks!

Copy link

github-actions bot commented Dec 3, 2024

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Dec 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants