Apply #pragma once, misc cleanup (#12322)
* Apply #pragma once in headers * Adjust some thermistors formatting * Misc cleanup and formatting
This commit is contained in:
@@ -16,14 +16,12 @@
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
/**
|
||||
* Description: HAL for Espressif ESP32 WiFi
|
||||
*/
|
||||
|
||||
#ifndef _HAL_ESP32_H
|
||||
#define _HAL_ESP32_H
|
||||
|
||||
#define CPU_32_BIT
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
@@ -123,5 +121,3 @@ void HAL_adc_start_conversion (uint8_t adc_pin);
|
||||
#define HAL_INIT 1
|
||||
void HAL_idletask(void);
|
||||
void HAL_init(void);
|
||||
|
||||
#endif // _HAL_ESP32_H
|
||||
|
@@ -19,9 +19,7 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef _HAL_TIMERS_ESP32_H
|
||||
#define _HAL_TIMERS_ESP32_H
|
||||
#pragma once
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
// Includes
|
||||
@@ -104,5 +102,3 @@ bool HAL_timer_interrupt_enabled(const uint8_t timer_num);
|
||||
|
||||
#define HAL_timer_isr_prologue(TIMER_NUM)
|
||||
#define HAL_timer_isr_epilogue(TIMER_NUM)
|
||||
|
||||
#endif // _HAL_TIMERS_ESP32_H
|
||||
|
@@ -19,6 +19,7 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
/**
|
||||
* Endstop Interrupts
|
||||
@@ -34,9 +35,6 @@
|
||||
* (Located in Marlin/buildroot/share/pin_interrupt_test/pin_interrupt_test.ino)
|
||||
*/
|
||||
|
||||
#ifndef _ENDSTOP_INTERRUPTS_H_
|
||||
#define _ENDSTOP_INTERRUPTS_H_
|
||||
|
||||
#include "../../module/endstops.h"
|
||||
|
||||
// One ISR for all EXT-Interrupts
|
||||
@@ -77,5 +75,3 @@ void setup_endstop_interrupts(void) {
|
||||
attachInterrupt(digitalPinToInterrupt(Z_MIN_PROBE_PIN), endstop_ISR, CHANGE);
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif //_ENDSTOP_INTERRUPTS_H_
|
||||
|
@@ -19,9 +19,7 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef _FASTIO_ESP32_H
|
||||
#define _FASTIO_ESP32_H
|
||||
#pragma once
|
||||
|
||||
/**
|
||||
* Utility functions
|
||||
@@ -64,9 +62,3 @@
|
||||
// TWI (I2C)
|
||||
#define SCL 5
|
||||
#define SDA 4
|
||||
|
||||
//
|
||||
// pins
|
||||
//
|
||||
|
||||
#endif // _FASTIO_ESP32_H
|
||||
|
@@ -16,11 +16,7 @@
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef _HAL_OTA_H
|
||||
#define _HAL_OTA_H
|
||||
#pragma once
|
||||
|
||||
void OTA_init();
|
||||
void OTA_handle();
|
||||
|
||||
#endif
|
||||
|
@@ -16,13 +16,9 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef SPI_PINS_H_
|
||||
#define SPI_PINS_H_
|
||||
#pragma once
|
||||
|
||||
#define SS_PIN 5
|
||||
#define SCK_PIN 18
|
||||
#define MISO_PIN 19
|
||||
#define MOSI_PIN 23
|
||||
|
||||
#endif // SPI_PINS_H_
|
||||
|
@@ -19,14 +19,10 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef WATCHDOG_ESP32_H
|
||||
#define WATCHDOG_ESP32_H
|
||||
#pragma once
|
||||
|
||||
// Initialize watchdog with a 4 second interrupt time
|
||||
void watchdog_init();
|
||||
|
||||
// Reset watchdog.
|
||||
inline void watchdog_reset() {};
|
||||
|
||||
#endif // WATCHDOG_ESP32_H
|
||||
inline void watchdog_reset() { }
|
||||
|
Reference in New Issue
Block a user