mirror of
https://git.mirrors.martin98.com/https://github.com/luc-github/ESP3D.git
synced 2025-08-05 19:56:02 +08:00
Fix SD is not automaticaly mounted on printer after access
This commit is contained in:
parent
85931368d8
commit
70fa36837a
@ -22,7 +22,7 @@
|
||||
#define _VERSION_ESP3D_H
|
||||
|
||||
//version and sources location
|
||||
#define FW_VERSION "3.0.0.a212"
|
||||
#define FW_VERSION "3.0.0.a213"
|
||||
#define REPOSITORY "https://github.com/luc-github/ESP3D/tree/3.0"
|
||||
|
||||
#endif //_VERSION_ESP3D_H
|
||||
|
@ -125,18 +125,20 @@ bool ESP_SD::accessFS(uint8_t FS)
|
||||
void ESP_SD::releaseFS(uint8_t FS)
|
||||
{
|
||||
(void)FS;
|
||||
log_esp3d("Release SD");
|
||||
setState(ESP_SDCARD_IDLE);
|
||||
#if SD_DEVICE_CONNECTION == ESP_SHARED_SD
|
||||
_enabled = false;
|
||||
#if defined (ESP_FLAG_SHARED_SD_PIN) && ESP_FLAG_SHARED_SD_PIN != -1
|
||||
log_esp3d("SD shared disabled PIN %d with %d", ESP_FLAG_SHARED_SD_PIN, ESP_FLAG_SHARED_SD_VALUE);
|
||||
digitalWrite(ESP_FLAG_SHARED_SD_PIN, !ESP_FLAG_SHARED_SD_VALUE);
|
||||
#endif // ESP_FLAG_SHARED_SD_PIN
|
||||
#if defined (ESP3DLIB_ENV)
|
||||
log_esp3d("Release SD");
|
||||
log_esp3d("Mount SD in Marlin");
|
||||
card.mount();
|
||||
#endif // ESP3DLIB_ENV
|
||||
_enabled = false;
|
||||
#endif //SD_DEVICE_CONNECTION == ESP_SHARED_SD
|
||||
setState(ESP_SDCARD_IDLE);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user