I want to use esp32 drive sd for fatfs,but when i use fopen and fgets function at different source file.these are some error……
[img] [/img]
some error about esp32 for sd driver
Re: some error about esp32 for sd driver
According to the log, you do something about GPIO4 pin (reconfigure it as input) after SD card is initialized.
This is an SD card pin, and changing its configuration causes SD card to fail.
This is an SD card pin, and changing its configuration causes SD card to fail.
-
- Posts: 4
- Joined: Fri Nov 17, 2017 2:08 pm
Re: some error about esp32 for sd driver
Thank to you for your answer.when I check all my use functions,but nothing that destroy IO4.The accessory is my code。
- Attachments
-
- main.zip
- (12.17 KiB) Downloaded 339 times
-
- Posts: 9708
- Joined: Thu Nov 26, 2015 4:08 am
Re: some error about esp32 for sd driver
Check your setting of io_conf.pin_bit_mask in spi_master2.c. You put a GPIO number in there (18), but you should put a bitmask in there (1<<18).
-
- Posts: 4
- Joined: Fri Nov 17, 2017 2:08 pm
Re: some error about esp32 for sd driver
Thank you very much! you are right. my Problems have been resolved.
Who is online
Users browsing this forum: No registered users and 84 guests