Browse Source

Sanity check old serial names

Scott Lahteine 3 years ago
parent
commit
7ce91c5ffe

+ 1
- 1
Marlin/Configuration_adv.h View File

1409
 
1409
 
1410
   #define DGUS_RX_BUFFER_SIZE 128
1410
   #define DGUS_RX_BUFFER_SIZE 128
1411
   #define DGUS_TX_BUFFER_SIZE 48
1411
   #define DGUS_TX_BUFFER_SIZE 48
1412
-  //#define DGUS_SERIAL_STATS_RX_BUFFER_OVERRUNS  // Fix Rx overrun situation (Currently only for AVR)
1412
+  //#define SERIAL_STATS_RX_BUFFER_OVERRUNS  // Fix Rx overrun situation (Currently only for AVR)
1413
 
1413
 
1414
   #define DGUS_UPDATE_INTERVAL_MS  500    // (ms) Interval between automatic screen updates
1414
   #define DGUS_UPDATE_INTERVAL_MS  500    // (ms) Interval between automatic screen updates
1415
 
1415
 

+ 1
- 1
Marlin/src/HAL/AVR/MarlinSerial.h View File

310
     #if HAS_DGUS_LCD
310
     #if HAS_DGUS_LCD
311
       static constexpr unsigned int RX_SIZE   = DGUS_RX_BUFFER_SIZE;
311
       static constexpr unsigned int RX_SIZE   = DGUS_RX_BUFFER_SIZE;
312
       static constexpr unsigned int TX_SIZE   = DGUS_TX_BUFFER_SIZE;
312
       static constexpr unsigned int TX_SIZE   = DGUS_TX_BUFFER_SIZE;
313
-      static constexpr bool RX_OVERRUNS       = ENABLED(DGUS_SERIAL_STATS_RX_BUFFER_OVERRUNS);
313
+      static constexpr bool RX_OVERRUNS       = ENABLED(SERIAL_STATS_RX_BUFFER_OVERRUNS);
314
     #elif EITHER(ANYCUBIC_LCD_I3MEGA, ANYCUBIC_LCD_CHIRON)
314
     #elif EITHER(ANYCUBIC_LCD_I3MEGA, ANYCUBIC_LCD_CHIRON)
315
       static constexpr unsigned int RX_SIZE   = 64;
315
       static constexpr unsigned int RX_SIZE   = 64;
316
       static constexpr unsigned int TX_SIZE   = 128;
316
       static constexpr unsigned int TX_SIZE   = 128;

+ 8
- 0
Marlin/src/inc/SanityCheck.h View File

481
   #error "DGUS_SERIAL_PORT is now LCD_SERIAL_PORT. Please update your configuration."
481
   #error "DGUS_SERIAL_PORT is now LCD_SERIAL_PORT. Please update your configuration."
482
 #elif defined(DGUS_BAUDRATE)
482
 #elif defined(DGUS_BAUDRATE)
483
   #error "DGUS_BAUDRATE is now LCD_BAUDRATE. Please update your configuration."
483
   #error "DGUS_BAUDRATE is now LCD_BAUDRATE. Please update your configuration."
484
+#elif defined(DGUS_STATS_RX_BUFFER_OVERRUNS)
485
+  #error "DGUS_STATS_RX_BUFFER_OVERRUNS is now STATS_RX_BUFFER_OVERRUNS. Please update your configuration."
486
+#elif defined(DGUS_SERIAL_PORT)
487
+  #error "DGUS_SERIAL_PORT is now LCD_SERIAL_PORT. Please update your configuration."
488
+#elif defined(ANYCUBIC_LCD_SERIAL_PORT)
489
+  #error "ANYCUBIC_LCD_SERIAL_PORT is now LCD_SERIAL_PORT. Please update your configuration."
490
+#elif defined(INTERNAL_SERIAL_PORT)
491
+  #error "INTERNAL_SERIAL_PORT is now MMU2_SERIAL_PORT. Please update your configuration."
484
 #elif defined(X_DUAL_ENDSTOPS_ADJUSTMENT)
492
 #elif defined(X_DUAL_ENDSTOPS_ADJUSTMENT)
485
   #error "X_DUAL_ENDSTOPS_ADJUSTMENT is now X2_ENDSTOP_ADJUSTMENT. Please update Configuration_adv.h."
493
   #error "X_DUAL_ENDSTOPS_ADJUSTMENT is now X2_ENDSTOP_ADJUSTMENT. Please update Configuration_adv.h."
486
 #elif defined(Y_DUAL_ENDSTOPS_ADJUSTMENT)
494
 #elif defined(Y_DUAL_ENDSTOPS_ADJUSTMENT)

+ 1
- 1
Marlin/src/lcd/extui/lib/dgus/DGUSDisplay.cpp View File

129
 
129
 
130
 void DGUSDisplay::ProcessRx() {
130
 void DGUSDisplay::ProcessRx() {
131
 
131
 
132
-  #if ENABLED(DGUS_SERIAL_STATS_RX_BUFFER_OVERRUNS)
132
+  #if ENABLED(SERIAL_STATS_RX_BUFFER_OVERRUNS)
133
     if (!LCD_SERIAL.available() && LCD_SERIAL.buffer_overruns()) {
133
     if (!LCD_SERIAL.available() && LCD_SERIAL.buffer_overruns()) {
134
       // Overrun, but reset the flag only when the buffer is empty
134
       // Overrun, but reset the flag only when the buffer is empty
135
       // We want to extract as many as valid datagrams possible...
135
       // We want to extract as many as valid datagrams possible...

Loading…
Cancel
Save