|
@@ -107,22 +107,24 @@ void GcodeSuite::M26() {
|
107
|
107
|
}
|
108
|
108
|
|
109
|
109
|
/**
|
110
|
|
- * M27: Get SD Card status
|
|
110
|
+ * M27: Get SD Card status or set the SD status auto-report interval.
|
111
|
111
|
*/
|
112
|
112
|
void GcodeSuite::M27() {
|
113
|
|
- card.getStatus(
|
114
|
|
- #if NUM_SERIAL > 1
|
115
|
|
- command_queue_port[cmd_queue_index_r]
|
116
|
|
- #endif
|
117
|
|
- );
|
118
|
113
|
#if ENABLED(AUTO_REPORT_SD_STATUS)
|
119
|
|
- if (parser.seenval('S'))
|
120
|
|
- card.set_auto_report_interval(parser.value_byte()
|
121
|
|
- #if NUM_SERIAL > 1
|
122
|
|
- , command_queue_port[cmd_queue_index_r]
|
123
|
|
- #endif
|
124
|
|
- );
|
|
114
|
+ if (parser.seenval('S')) {
|
|
115
|
+ card.set_auto_report_interval(parser.value_byte()
|
|
116
|
+ #if NUM_SERIAL > 1
|
|
117
|
+ , command_queue_port[cmd_queue_index_r]
|
|
118
|
+ #endif
|
|
119
|
+ );
|
|
120
|
+ }
|
|
121
|
+ else
|
125
|
122
|
#endif
|
|
123
|
+ card.getStatus(
|
|
124
|
+ #if NUM_SERIAL > 1
|
|
125
|
+ command_queue_port[cmd_queue_index_r]
|
|
126
|
+ #endif
|
|
127
|
+ );
|
126
|
128
|
}
|
127
|
129
|
|
128
|
130
|
/**
|