Use a macro for HAL header redirection (#10380)

This commit is contained in:
Chris Pepper
2018-04-13 02:25:08 +01:00
committed by Scott Lahteine
parent 12785583d0
commit cc6d41e1d3
51 changed files with 152 additions and 285 deletions

View File

@ -25,7 +25,7 @@
#if defined(__MK64FX512__) || defined(__MK66FX1M0__)
#include "../HAL.h"
#include "HAL.h"
#include <Wire.h>

View File

@ -26,6 +26,8 @@
#ifndef _HAL_TEENSY_H
#define _HAL_TEENSY_H
#define CPU_32_BIT
// --------------------------------------------------------------------------
// Includes
// --------------------------------------------------------------------------
@ -39,6 +41,9 @@
#undef sq
#define sq(x) ((x)*(x))
#include "../math_32bit.h"
#include "../HAL_SPI.h"
#include "fastio_Teensy.h"
#include "watchdog_Teensy.h"

View File

@ -1,6 +1,6 @@
#if defined(__MK64FX512__) || defined(__MK66FX1M0__)
#include "../HAL.h"
#include "HAL.h"
#include <SPI.h>
#include <pins_arduino.h>
#include "spi_pins.h"

View File

@ -26,7 +26,7 @@
#if defined(__MK64FX512__) || defined(__MK66FX1M0__)
#include "../HAL.h"
#include "HAL.h"
#include "HAL_timers_Teensy.h"

View File

@ -34,8 +34,19 @@
* (Located in Marlin/buildroot/share/pin_interrupt_test/pin_interrupt_test.ino)
*/
#ifndef _ENDSTOP_INTERRUPTS_H_
#define _ENDSTOP_INTERRUPTS_H_
#ifndef _ENDSTOP_INTERRUPTS_H_
#define _ENDSTOP_INTERRUPTS_H_
volatile uint8_t e_hit = 0; // Different from 0 when the endstops should be tested in detail.
// Must be reset to 0 by the test function when finished.
// This is what is really done inside the interrupts.
FORCE_INLINE void endstop_ISR_worker( void ) {
e_hit = 2; // Because the detection of a e-stop hit has a 1 step debouncer it has to be called at least twice.
}
// One ISR for all EXT-Interrupts
void endstop_ISR(void) { endstop_ISR_worker(); }
/**
* Endstop interrupts for Due based targets.

View File

@ -23,7 +23,7 @@
#ifndef WATCHDOG_TEENSY_H
#define WATCHDOG_TEENSY_H
#include "../HAL.h"
#include "HAL.h"
// Arduino Due core now has watchdog support