From 8f9b246d0ec0bf2d0703ed2456ba00820e4a57bd Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Thu, 24 Jan 2019 13:18:37 -0600 Subject: [PATCH] Tweak some formatting, replace tabs --- .../HAL_STM32F1/u8g_com_stm32duino_fsmc.cpp | 38 ++++++++++--------- .../sdcard/M20-M30_M32-M34_M524_M928.cpp | 2 +- 2 files changed, 21 insertions(+), 19 deletions(-) diff --git a/Marlin/src/HAL/HAL_STM32F1/u8g_com_stm32duino_fsmc.cpp b/Marlin/src/HAL/HAL_STM32F1/u8g_com_stm32duino_fsmc.cpp index de55f6c2ec..2e01428d4d 100644 --- a/Marlin/src/HAL/HAL_STM32F1/u8g_com_stm32duino_fsmc.cpp +++ b/Marlin/src/HAL/HAL_STM32F1/u8g_com_stm32duino_fsmc.cpp @@ -26,10 +26,11 @@ * Communication interface for FSMC */ +#if defined(STM32F1) || defined(STM32F1xx) + #include "../../inc/MarlinConfig.h" #if HAS_GRAPHICAL_LCD -#if defined(STM32F1) || defined(STM32F1xx) #include "U8glib.h" #include "libmaple/fsmc.h" @@ -227,29 +228,30 @@ void LCD_IO_Init(uint8_t cs, uint8_t rs) { } void LCD_IO_WriteData(uint16_t RegValue) { - LCD->RAM = RegValue; - __DSB(); + LCD->RAM = RegValue; + __DSB(); } void LCD_IO_WriteReg(uint8_t Reg) { - LCD->REG = (uint16_t)Reg; - __DSB(); + LCD->REG = (uint16_t)Reg; + __DSB(); } uint32_t LCD_IO_ReadData(uint16_t RegValue, uint8_t ReadSize) { - volatile uint32_t data; - LCD->REG = (uint16_t)RegValue; - __DSB(); - - data = LCD->RAM; // dummy read - data = LCD->RAM & 0x00FF; - - while (--ReadSize) { - data <<= 8; - data |= (LCD->RAM & 0x00FF); - } - return (uint32_t)data; + volatile uint32_t data; + LCD->REG = (uint16_t)RegValue; + __DSB(); + + data = LCD->RAM; // dummy read + data = LCD->RAM & 0x00FF; + + while (--ReadSize) { + data <<= 8; + data |= (LCD->RAM & 0x00FF); + } + return (uint32_t)data; } -#endif // STM32F1 || STM32F1xx #endif // HAS_GRAPHICAL_LCD + +#endif // STM32F1 || STM32F1xx diff --git a/Marlin/src/gcode/sdcard/M20-M30_M32-M34_M524_M928.cpp b/Marlin/src/gcode/sdcard/M20-M30_M32-M34_M524_M928.cpp index 004ca33a8a..495cd2c623 100644 --- a/Marlin/src/gcode/sdcard/M20-M30_M32-M34_M524_M928.cpp +++ b/Marlin/src/gcode/sdcard/M20-M30_M32-M34_M524_M928.cpp @@ -117,7 +117,7 @@ void GcodeSuite::M25() { // Set initial pause flag to prevent more commands from landing in the queue while we try to pause #if ENABLED(SDSUPPORT) - if (IS_SD_PRINTING()) { card.pauseSDPrint(); } + if (IS_SD_PRINTING()) card.pauseSDPrint(); #endif #if ENABLED(PARK_HEAD_ON_PAUSE)