Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Duet3D/RepRapFirmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Crocker <dcrocker@eschertech.com>2021-04-29 18:17:41 +0300
committerDavid Crocker <dcrocker@eschertech.com>2021-04-29 18:17:41 +0300
commit48f7d6b2391350ea1a511a28ee0b47c3f1cb4e2d (patch)
treec61f40fb25bbfb0976f5c2477aceeb95df7b96f0 /src/Duet3_V06
parentc8578fb1073e896246cbe94db19ff8c340fabddb (diff)
Add support for secondary CAN on Duet 3 MB6HC
Diffstat (limited to 'src/Duet3_V06')
-rw-r--r--src/Duet3_V06/Pins_Duet3_V06.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/Duet3_V06/Pins_Duet3_V06.h b/src/Duet3_V06/Pins_Duet3_V06.h
index 66c8939f..d1dfe43e 100644
--- a/src/Duet3_V06/Pins_Duet3_V06.h
+++ b/src/Duet3_V06/Pins_Duet3_V06.h
@@ -34,6 +34,7 @@ constexpr uint32_t IAP_IMAGE_START = 0x20458000; // last 32kb of RAM
#define HAS_VREF_MONITOR 1
#define SUPPORT_CAN_EXPANSION 1
+#define DUAL_CAN 1 // support the second CAN interface as simple CAN (not FD)
#define SUPPORT_LED_STRIPS 1
#define SUPPORT_INKJET 0 // set nonzero to support inkjet control
#define SUPPORT_ROLAND 0 // set nonzero to support Roland mill
@@ -381,7 +382,11 @@ constexpr GpioPinFunction CAN1RXPinPeriphMode = GpioPinFunction::C;
constexpr Pin APIN_CAN1_TX = PortDPin(12);
constexpr GpioPinFunction CAN1TXPinPeriphMode = GpioPinFunction::B;
-constexpr unsigned int CanDeviceNumber = 1; // we use CAN1
+constexpr unsigned int CanDeviceNumber = 1; // CAN-FD device number
+
+#if defined(DUAL_CAN) && DUAL_CAN
+constexpr unsigned int SecondaryCanDeviceNumber = 0; // plan CAN device number
+#endif
constexpr Pin SbcTfrReadyPin = PortEPin(2);
// Note, the DMAC peripheral IDs are hard-coded in DataTransfer