What version of the firmware are you using?
1.3a 20201212
Is the problem repeatable?
Yes
Under what conditions does the bug occur?
Without an SD card inserted into the MidTBot, click the “Refresh” button in the Web GUI. Eventually a “No SD card inserted” message will appear in the SD card window, but attempting to execute any further commands (such as $X) will report “Error 120 [MSG:SD card job running].” The only way I’ve found to get past the error is to reset the ESP32 manually.
评论 (6)
#2 – AlphaCircuit 于 2021-02-10
Solutions as below..
I have made a solution to this problem. As follows modify as follows sdcard.cpp locate “getsdstate” and replace with below, I was struggling for days and realised all the prechecks on card being there where causing it not bother checking for a card after a no card refresh… this resolves it by taking out any notion of not checking ie it always checks … note copying as vebatim as a lot is remarked out but left incase someone finds a better way. Note it WORKS as is copy and paste it …. Cheers
Modify File SDCard.CPP
uint8t getsd_state(bool refresh) {
/*
if (SDCARDDETPIN != UNDEFINED_PIN) {
if (digitalRead(SDCARDDETPIN) != SDCARDDETVAL) {
sdstate = SDCARDNOT_PRESENT;
return sd_state;
//no need to go further if SD detect is not correct
}
}
if (!refresh) {
return sd_state; //to avoid refresh=true + busy to reset SD and waste time
}
/////// Norm mod
//if busy doing something return state
/*
if (!((sdstate == SDCARDNOTPRESENT) || (sdstate == SDCARD_IDLE))) {
return sd_state;
}
if ((sdstate == SDCARDNOTPRESENT)) { //|| (sdstate == SDCARD_IDLE))) {
SD.end();
return sd_state;
}
if (!(sdstate == SDCARDIDLE)) {
return sd_state;
}
/////////////Norm Mod ends
*/
if (!refresh) {
return sd_state; //to avoid refresh=true + busy to reset SD and waste time
}
//SD is idle or not detected, let see if still the case
// SD.end();
// sdstate = SDCARDNOT_PRESENT;
//using default value for speed ? should be parameter
//refresh content if card was removed
if (SD.begin((GRBLSPISS == -1) ? SS : GRBLSPISS, SPI, GRBLSPIFREQ, “/sd”, 2)) {
if (SD.cardSize() > 0) {
sdstate = SDCARDIDLE;
}
}
return sd_state;
}
#3 – bdring 于 2021-02-10
We have made some SD card changes recently. Have you looked at the latest code?
#4 – AlphaCircuit 于 2021-02-10
> We have made some SD card changes recently. Have you looked at the latest code?
Um sorry new to here, but I posted my solution, that worked for me… Please let me know if I needed to post it differently. The above code is a fix…
#5 – bdring 于 2021-02-10
The best way is to create a pull request. It makes it very easy for us to see the impact on the current code. We have guidelines here.
https://github.com/bdring/Grbl_Esp32/wiki/Pull-Request-Guidelines
#6 – Leemonoid 于 2021-02-13
Closing this issue. With the latest firmware build, the problem has been corrected. Thanks!
#1 – bdring 于 2020-12-30
I have confirmed the problem and have added it to our issue tracker. It is probably a simple fix that can be included in the next update.