Fix build failures on non-SAM E boards
This commit is contained in:
parent
a5b39123e7
commit
7115cad933
3 changed files with 10 additions and 1 deletions
|
|
@ -4,7 +4,9 @@
|
|||
#ifndef CAN_H
|
||||
#define CAN_H
|
||||
|
||||
#ifdef ARDUINO_ARCH_ESP32
|
||||
#if defined(ADAFRUIT_FEATHER_M4_CAN)
|
||||
#include "CANSAME5x.h"
|
||||
#elif defined(ARDUINO_ARCH_ESP32)
|
||||
#include "ESP32SJA1000.h"
|
||||
#else
|
||||
#include "MCP2515.h"
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
// Copyright 2020 © Jeff Epler for Adafruit Industries. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
|
||||
#if defined(ADAFRUIT_FEATHER_M4_CAN)
|
||||
#include <stdint.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
|
|
@ -501,3 +502,7 @@ void CAN1_Handler() {
|
|||
}
|
||||
|
||||
CANSAME5x *CANSAME5x::instances[2];
|
||||
|
||||
CANSAME5x CAN;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -50,3 +50,5 @@ private:
|
|||
friend void CAN0_Handler(void);
|
||||
friend void CAN1_Handler(void);
|
||||
};
|
||||
|
||||
extern CANSAME5x CAN;
|
||||
|
|
|
|||
Loading…
Reference in a new issue