2016-03-25 06:19:46 +00:00
|
|
|
/**
|
2016-03-24 18:01:20 +00:00
|
|
|
* Marlin 3D Printer Firmware
|
|
|
|
* Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
|
|
|
*
|
|
|
|
* Based on Sprinter and grbl.
|
|
|
|
* Copyright (C) 2011 Camiel Gubbels / Erik van der Zalm
|
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*
|
2015-01-26 02:40:00 +00:00
|
|
|
*/
|
2015-01-26 02:50:09 +00:00
|
|
|
|
2017-06-08 23:05:14 +00:00
|
|
|
/**
|
|
|
|
* Include pins definitions
|
|
|
|
*
|
|
|
|
* Pins numbering schemes:
|
|
|
|
*
|
|
|
|
* - Digital I/O pin number if used by READ/WRITE macros. (e.g., X_STEP_DIR)
|
|
|
|
* The FastIO headers map digital pins to their ports and functions.
|
|
|
|
*
|
|
|
|
* - Analog Input number if used by analogRead or DAC. (e.g., TEMP_n_PIN)
|
|
|
|
* These numbers are the same in any pin mapping.
|
|
|
|
*/
|
|
|
|
|
2017-06-06 09:32:31 +00:00
|
|
|
#ifndef __PINS_H__
|
|
|
|
#define __PINS_H__
|
2011-12-12 18:34:37 +00:00
|
|
|
|
2017-09-06 11:28:32 +00:00
|
|
|
#include "../inc/MarlinConfig.h"
|
|
|
|
|
2017-12-05 06:33:25 +00:00
|
|
|
#if MB(RAMPS_13_EFB) || MB(RAMPS_14_EFB) || MB(RAMPS_PLUS_EFB) || MB(RAMPS_14_RE_ARM_EFB) || MB(RAMPS_SMART_EFB) || MB(RAMPS_DUO_EFB) || MB(RAMPS4DUE_EFB)
|
2017-09-06 11:28:32 +00:00
|
|
|
#define IS_RAMPS_EFB
|
2017-12-05 06:33:25 +00:00
|
|
|
#elif MB(RAMPS_13_EEB) || MB(RAMPS_14_EEB) || MB(RAMPS_PLUS_EEB) || MB(RAMPS_14_RE_ARM_EEB) || MB(RAMPS_SMART_EEB) || MB(RAMPS_DUO_EEB) || MB(RAMPS4DUE_EEB)
|
2017-09-06 11:28:32 +00:00
|
|
|
#define IS_RAMPS_EEB
|
2017-12-05 06:33:25 +00:00
|
|
|
#elif MB(RAMPS_13_EFF) || MB(RAMPS_14_EFF) || MB(RAMPS_PLUS_EFF) || MB(RAMPS_14_RE_ARM_EFF) || MB(RAMPS_SMART_EFF) || MB(RAMPS_DUO_EFF) || MB(RAMPS4DUE_EFF)
|
2017-09-06 11:28:32 +00:00
|
|
|
#define IS_RAMPS_EFF
|
2017-12-05 06:33:25 +00:00
|
|
|
#elif MB(RAMPS_13_EEF) || MB(RAMPS_14_EEF) || MB(RAMPS_PLUS_EEF) || MB(RAMPS_14_RE_ARM_EEF) || MB(RAMPS_SMART_EEF) || MB(RAMPS_DUO_EEF) || MB(RAMPS4DUE_EEF)
|
2017-09-06 11:28:32 +00:00
|
|
|
#define IS_RAMPS_EEF
|
2017-12-05 06:33:25 +00:00
|
|
|
#elif MB(RAMPS_13_SF) || MB(RAMPS_14_SF) || MB(RAMPS_PLUS_SF) || MB(RAMPS_14_RE_ARM_SF) || MB(RAMPS_SMART_SF) || MB(RAMPS_DUO_SF) || MB(RAMPS4DUE_SF)
|
2017-09-06 11:28:32 +00:00
|
|
|
#define IS_RAMPS_SF
|
|
|
|
#endif
|
2017-06-17 21:19:42 +00:00
|
|
|
|
2017-08-23 23:24:02 +00:00
|
|
|
//
|
|
|
|
// RAMPS 1.3 / 1.4 - ATmega1280, ATmega2560
|
|
|
|
//
|
|
|
|
|
|
|
|
#if MB(RAMPS_OLD)
|
2015-01-26 02:40:00 +00:00
|
|
|
#include "pins_RAMPS_OLD.h"
|
2015-06-15 06:17:00 +00:00
|
|
|
#elif MB(RAMPS_13_EFB)
|
2016-07-30 10:07:20 +00:00
|
|
|
#include "pins_RAMPS_13.h"
|
|
|
|
#elif MB(RAMPS_13_EEB)
|
|
|
|
#include "pins_RAMPS_13.h"
|
|
|
|
#elif MB(RAMPS_13_EFF)
|
|
|
|
#include "pins_RAMPS_13.h"
|
|
|
|
#elif MB(RAMPS_13_EEF)
|
|
|
|
#include "pins_RAMPS_13.h"
|
|
|
|
#elif MB(RAMPS_13_SF)
|
2015-01-26 02:40:00 +00:00
|
|
|
#include "pins_RAMPS_13.h"
|
2015-10-31 01:05:09 +00:00
|
|
|
#elif MB(RAMPS_14_EFB)
|
2016-07-30 10:10:30 +00:00
|
|
|
#include "pins_RAMPS.h"
|
2016-07-30 10:07:20 +00:00
|
|
|
#elif MB(RAMPS_14_EEB)
|
2016-07-30 10:10:30 +00:00
|
|
|
#include "pins_RAMPS.h"
|
2016-07-30 10:07:20 +00:00
|
|
|
#elif MB(RAMPS_14_EFF)
|
2016-07-30 10:10:30 +00:00
|
|
|
#include "pins_RAMPS.h"
|
2016-07-30 10:07:20 +00:00
|
|
|
#elif MB(RAMPS_14_EEF)
|
2016-07-30 10:10:30 +00:00
|
|
|
#include "pins_RAMPS.h"
|
2016-07-30 10:07:20 +00:00
|
|
|
#elif MB(RAMPS_14_SF)
|
2016-07-30 10:10:30 +00:00
|
|
|
#include "pins_RAMPS.h"
|
2017-12-05 06:33:25 +00:00
|
|
|
#elif MB(RAMPS_PLUS_EFB)
|
|
|
|
#include "pins_RAMPS_PLUS.h"
|
|
|
|
#elif MB(RAMPS_PLUS_EEB)
|
|
|
|
#include "pins_RAMPS_PLUS.h"
|
|
|
|
#elif MB(RAMPS_PLUS_EFF)
|
|
|
|
#include "pins_RAMPS_PLUS.h"
|
|
|
|
#elif MB(RAMPS_PLUS_EEF)
|
|
|
|
#include "pins_RAMPS_PLUS.h"
|
|
|
|
#elif MB(RAMPS_PLUS_SF)
|
|
|
|
#include "pins_RAMPS_PLUS.h"
|
2017-08-23 23:24:02 +00:00
|
|
|
|
|
|
|
//
|
|
|
|
// RAMPS Derivatives - ATmega1280, ATmega2560
|
|
|
|
//
|
|
|
|
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(3DRAG)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_3DRAG.h" // ATmega1280, ATmega2560
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(K8200)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_K8200.h" // ATmega1280, ATmega2560 (3DRAG)
|
2016-07-02 13:32:21 +00:00
|
|
|
#elif MB(K8400)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_K8400.h" // ATmega1280, ATmega2560 (3DRAG)
|
|
|
|
#elif MB(BAM_DICE)
|
|
|
|
#include "pins_RAMPS.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(BAM_DICE_DUE)
|
|
|
|
#include "pins_BAM_DICE_DUE.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(MKS_BASE)
|
|
|
|
#include "pins_MKS_BASE.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(MKS_13)
|
|
|
|
#include "pins_MKS_13.h" // ATmega1280, ATmega2560
|
2017-11-02 22:06:08 +00:00
|
|
|
#elif MB(MKS_GEN_L)
|
|
|
|
#include "pins_MKS_GEN_L.h" // ATmega1280, ATmega2560
|
2017-08-23 23:24:02 +00:00
|
|
|
#elif MB(ZRIB_V20)
|
|
|
|
#include "pins_ZRIB_V20.h" // ATmega1280, ATmega2560 (MKS_13)
|
|
|
|
#elif MB(FELIX2)
|
|
|
|
#include "pins_FELIX2.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(RIGIDBOARD)
|
|
|
|
#include "pins_RIGIDBOARD.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(RIGIDBOARD_V2)
|
|
|
|
#include "pins_RIGIDBOARD_V2.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(SAINSMART_2IN1)
|
|
|
|
#include "pins_SAINSMART_2IN1.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(ULTIMAKER)
|
|
|
|
#include "pins_ULTIMAKER.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(ULTIMAKER_OLD)
|
|
|
|
#include "pins_ULTIMAKER_OLD.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(AZTEEG_X3)
|
|
|
|
#include "pins_AZTEEG_X3.h" // ATmega2560
|
|
|
|
#elif MB(AZTEEG_X3_PRO)
|
|
|
|
#include "pins_AZTEEG_X3_PRO.h" // ATmega2560
|
|
|
|
#elif MB(ULTIMAIN_2)
|
|
|
|
#include "pins_ULTIMAIN_2.h" // ATmega2560
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(RUMBA)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_RUMBA.h" // ATmega2560
|
|
|
|
#elif MB(BQ_ZUM_MEGA_3D)
|
|
|
|
#include "pins_BQ_ZUM_MEGA_3D.h" // ATmega2560
|
2017-10-21 05:31:07 +00:00
|
|
|
#elif MB(MAKEBOARD_MINI)
|
|
|
|
#include "pins_MAKEBOARD_MINI.h" // ATmega2560
|
2017-08-23 23:24:02 +00:00
|
|
|
|
|
|
|
//
|
|
|
|
// Other ATmega1280, ATmega2560
|
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(CNCONTROLS_11)
|
|
|
|
#include "pins_CNCONTROLS_11.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(CNCONTROLS_12)
|
|
|
|
#include "pins_CNCONTROLS_12.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(MIGHTYBOARD_REVE)
|
|
|
|
#include "pins_MIGHTYBOARD_REVE.h" // ATmega1280, ATmega2560
|
|
|
|
#elif MB(CHEAPTRONIC)
|
|
|
|
#include "pins_CHEAPTRONIC.h" // ATmega2560
|
|
|
|
#elif MB(CHEAPTRONIC_V2)
|
|
|
|
#include "pins_CHEAPTRONICv2.h" // ATmega2560
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(MEGATRONICS)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_MEGATRONICS.h" // ATmega2560
|
2015-01-27 23:54:46 +00:00
|
|
|
#elif MB(MEGATRONICS_2)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_MEGATRONICS_2.h" // ATmega2560
|
2017-12-09 05:35:25 +00:00
|
|
|
#elif MB(MEGATRONICS_3) || MB(MEGATRONICS_31)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_MEGATRONICS_3.h" // ATmega2560
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(RAMBO)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_RAMBO.h" // ATmega2560
|
2017-12-09 05:35:01 +00:00
|
|
|
#elif MB(MINIRAMBO) || MB(MINIRAMBO_10A)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_MINIRAMBO.h" // ATmega2560
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(ELEFU_3)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_ELEFU_3.h" // ATmega2560
|
2015-01-26 02:40:00 +00:00
|
|
|
#elif MB(LEAPFROG)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_LEAPFROG.h" // ATmega1280, ATmega2560
|
2015-07-22 09:35:02 +00:00
|
|
|
#elif MB(MEGACONTROLLER)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_MEGACONTROLLER.h" // ATmega2560
|
2017-03-28 03:22:13 +00:00
|
|
|
#elif MB(SCOOVO_X9H)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_SCOOVO_X9H.h" // ATmega2560
|
2017-05-23 20:53:29 +00:00
|
|
|
#elif MB(GT2560_REV_A)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_GT2560_REV_A.h" // ATmega1280, ATmega2560
|
2017-05-23 20:53:29 +00:00
|
|
|
#elif MB(GT2560_REV_A_PLUS)
|
2017-08-23 23:24:02 +00:00
|
|
|
#include "pins_GT2560_REV_A_PLUS.h" // ATmega1280, ATmega2560
|
|
|
|
|
|
|
|
//
|
|
|
|
// ATmega1281, ATmega2561
|
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(MINITRONICS)
|
|
|
|
#include "pins_MINITRONICS.h" // ATmega1281
|
2017-10-27 08:42:04 +00:00
|
|
|
#elif MB(SILVER_GATE)
|
|
|
|
#include "pins_SILVER_GATE.h" // ATmega2561
|
2017-08-23 23:24:02 +00:00
|
|
|
|
|
|
|
//
|
|
|
|
// Sanguinololu and Derivatives - ATmega644P, ATmega1284P
|
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(SANGUINOLOLU_11)
|
|
|
|
#include "pins_SANGUINOLOLU_11.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(SANGUINOLOLU_12)
|
|
|
|
#include "pins_SANGUINOLOLU_12.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(MELZI)
|
|
|
|
#include "pins_MELZI.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(MELZI_MAKR3D)
|
|
|
|
#include "pins_MELZI_MAKR3D.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(MELZI_CREALITY)
|
|
|
|
#include "pins_MELZI_CREALITY.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(STB_11)
|
|
|
|
#include "pins_STB_11.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(AZTEEG_X1)
|
|
|
|
#include "pins_AZTEEG_X1.h" // ATmega644P, ATmega1284P
|
|
|
|
|
|
|
|
//
|
|
|
|
// Other ATmega644P, ATmega644, ATmega1284P
|
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(GEN3_MONOLITHIC)
|
|
|
|
#include "pins_GEN3_MONOLITHIC.h" // ATmega644P
|
|
|
|
#elif MB(GEN3_PLUS)
|
|
|
|
#include "pins_GEN3_PLUS.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(GEN6)
|
|
|
|
#include "pins_GEN6.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(GEN6_DELUXE)
|
|
|
|
#include "pins_GEN6_DELUXE.h" // ATmega644P, ATmega1284P
|
|
|
|
#elif MB(GEN7_CUSTOM)
|
|
|
|
#include "pins_GEN7_CUSTOM.h" // ATmega644P, ATmega644, ATmega1284P
|
|
|
|
#elif MB(GEN7_12)
|
|
|
|
#include "pins_GEN7_12.h" // ATmega644P, ATmega644, ATmega1284P
|
|
|
|
#elif MB(GEN7_13)
|
|
|
|
#include "pins_GEN7_13.h" // ATmega644P, ATmega644, ATmega1284P
|
|
|
|
#elif MB(GEN7_14)
|
|
|
|
#include "pins_GEN7_14.h" // ATmega644P, ATmega644, ATmega1284P
|
|
|
|
#elif MB(OMCA_A)
|
|
|
|
#include "pins_OMCA_A.h" // ATmega644
|
|
|
|
#elif MB(OMCA)
|
|
|
|
#include "pins_OMCA.h" // ATmega644P, ATmega644
|
|
|
|
#elif MB(ANET_10)
|
|
|
|
#include "pins_ANET_10.h" // ATmega1284P
|
|
|
|
#elif MB(SETHI)
|
|
|
|
#include "pins_SETHI.h" // ATmega644P, ATmega644, ATmega1284P
|
|
|
|
|
|
|
|
//
|
|
|
|
// Teensyduino - AT90USB1286, AT90USB1286P
|
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(TEENSYLU)
|
|
|
|
#include "pins_TEENSYLU.h" // AT90USB1286, AT90USB1286P
|
|
|
|
#elif MB(PRINTRBOARD)
|
|
|
|
#include "pins_PRINTRBOARD.h" // AT90USB1286
|
|
|
|
#elif MB(PRINTRBOARD_REVF)
|
|
|
|
#include "pins_PRINTRBOARD_REVF.h" // AT90USB1286
|
|
|
|
#elif MB(BRAINWAVE)
|
|
|
|
#include "pins_BRAINWAVE.h" // AT90USB646
|
|
|
|
#elif MB(BRAINWAVE_PRO)
|
|
|
|
#include "pins_BRAINWAVE_PRO.h" // AT90USB1286
|
|
|
|
#elif MB(SAV_MKI)
|
|
|
|
#include "pins_SAV_MKI.h" // AT90USB1286
|
|
|
|
#elif MB(TEENSY2)
|
|
|
|
#include "pins_TEENSY2.h" // AT90USB1286
|
|
|
|
#elif MB(5DPRINT)
|
|
|
|
#include "pins_5DPRINT.h" // AT90USB1286
|
|
|
|
|
2017-06-17 23:36:10 +00:00
|
|
|
//
|
2017-06-17 21:19:42 +00:00
|
|
|
// Re-ARM - LPC1768
|
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(RAMPS_14_RE_ARM_EFB)
|
|
|
|
#include "pins_RAMPS_RE_ARM.h"
|
|
|
|
#elif MB(RAMPS_14_RE_ARM_EEB)
|
|
|
|
#include "pins_RAMPS_RE_ARM.h"
|
|
|
|
#elif MB(RAMPS_14_RE_ARM_EFF)
|
|
|
|
#include "pins_RAMPS_RE_ARM.h"
|
|
|
|
#elif MB(RAMPS_14_RE_ARM_EEF)
|
|
|
|
#include "pins_RAMPS_RE_ARM.h"
|
|
|
|
#elif MB(RAMPS_14_RE_ARM_SF)
|
|
|
|
#include "pins_RAMPS_RE_ARM.h"
|
|
|
|
|
|
|
|
//
|
|
|
|
// Other 32-bit Boards
|
2017-06-17 23:36:10 +00:00
|
|
|
//
|
|
|
|
|
|
|
|
#elif MB(TEENSY35_36)
|
|
|
|
#include "pins_TEENSY35_36.h"
|
|
|
|
#elif MB(DUE3DOM)
|
|
|
|
#include "pins_DUE3DOM.h"
|
|
|
|
#elif MB(DUE3DOM_MINI)
|
|
|
|
#include "pins_DUE3DOM_MINI.h"
|
|
|
|
#elif MB(RADDS)
|
|
|
|
#include "pins_RADDS.h"
|
2017-11-09 20:24:14 +00:00
|
|
|
#elif MB(RURAMPS4D)
|
|
|
|
#include "pins_RURAMPS4D.h"
|
2017-10-06 18:27:15 +00:00
|
|
|
#elif MB(RAMPS_FD_V1)
|
|
|
|
#include "pins_RAMPS_FD_V1.h"
|
2017-06-17 23:36:10 +00:00
|
|
|
#elif MB(RAMPS_FD_V2)
|
|
|
|
#include "pins_RAMPS_FD_V2.h"
|
|
|
|
#elif MB(RAMPS_SMART_EFB)
|
|
|
|
#include "pins_RAMPS_SMART.h"
|
|
|
|
#elif MB(RAMPS_SMART_EEB)
|
|
|
|
#include "pins_RAMPS_SMART.h"
|
|
|
|
#elif MB(RAMPS_SMART_EFF)
|
|
|
|
#include "pins_RAMPS_SMART.h"
|
|
|
|
#elif MB(RAMPS_SMART_EEF)
|
|
|
|
#include "pins_RAMPS_SMART.h"
|
|
|
|
#elif MB(RAMPS_SMART_SF)
|
|
|
|
#include "pins_RAMPS_SMART.h"
|
|
|
|
#elif MB(RAMPS_DUO_EFB)
|
|
|
|
#include "pins_RAMPS_DUO.h"
|
|
|
|
#elif MB(RAMPS_DUO_EEB)
|
|
|
|
#include "pins_RAMPS_DUO.h"
|
|
|
|
#elif MB(RAMPS_DUO_EFF)
|
|
|
|
#include "pins_RAMPS_DUO.h"
|
|
|
|
#elif MB(RAMPS_DUO_EEF)
|
|
|
|
#include "pins_RAMPS_DUO.h"
|
|
|
|
#elif MB(RAMPS_DUO_SF)
|
|
|
|
#include "pins_RAMPS_DUO.h"
|
|
|
|
#elif MB(RAMPS4DUE_EFB)
|
|
|
|
#include "pins_RAMPS4DUE.h"
|
|
|
|
#elif MB(RAMPS4DUE_EEB)
|
|
|
|
#include "pins_RAMPS4DUE.h"
|
|
|
|
#elif MB(RAMPS4DUE_EFF)
|
|
|
|
#include "pins_RAMPS4DUE.h"
|
|
|
|
#elif MB(RAMPS4DUE_EEF)
|
|
|
|
#include "pins_RAMPS4DUE.h"
|
|
|
|
#elif MB(RAMPS4DUE_SF)
|
|
|
|
#include "pins_RAMPS4DUE.h"
|
2017-11-21 09:13:59 +00:00
|
|
|
#elif MB(ULTRATRONICS_PRO)
|
|
|
|
#include "pins_ULTRATRONICS_PRO.h"
|
2017-11-03 09:48:15 +00:00
|
|
|
#elif MB(ARCHIM2)
|
|
|
|
#include "pins_ARCHIM2.h"
|
2017-06-17 23:36:10 +00:00
|
|
|
#elif MB(ALLIGATOR)
|
|
|
|
#include "pins_ALLIGATOR_R2.h"
|
2017-09-27 05:30:23 +00:00
|
|
|
#elif MB(STM32F1R)
|
|
|
|
#include "pins_STM32F1R.h"
|
[2.0.x] Multiple updates to STM32F1 HAL (#8733)
* STM32F1 HAL
Adding files for STM32F1 HAL based on libmaple/stm32duino core.
Current persistent_store uses cardreader changes to be sent in separate
commit, but could be changed to use i2c eeprom.
There is another persistent_store implementation that uses the MCU flash memory
to emulate eeprom
Adding readme with some information about the stm32 HAL.
* Switch to Timer4 to avoid a hard reset on STM32F103C6 boards
On bluepill STM32F103C6 boards, using Timer5 results in a error() vector call. Switch to 4 since these are both general purpose, 16 bit timers.
* Add support for EEPROM emulation using Flash
Some low end machines doe not have EEPROM support. Simulate it using the last two pages of flash. Flash does not allow rewrite between erases, so skip writing the working version if that's enabled.
* Basic Pins for a malyan M200
This is a work in progress to go hand in hand with the STM32 work.
* Add support for ADC with DMA. This work has exposed a problem with the pin enumerations in STM boards vs what marlin expects (i.e, try defining PA0 as a temp pin). The hack can be removed with we go to fastio completely. To see this work, set something in adc_pins to a value like PA0 and connect your pullup resistor'd thermistor.
* Missing file - change HAL_adc_init to actually do something
We have an actual ADC init function now.
* Remove pinmode hack
Remove the pin mode hack that I was using to init PA0.
Updated Readme.md
* Several changes to timers and GPIO
Faster GPIO, and faster timer functions by accesing registers and
libmaple.
Still more changes pending for the Timer's code to skip using the
HardwareTimer class altogether.
Switch all enums to be within #defines
This change allows a user to have, for instance, TEMP_4 and TEMP_BED definied but nothing else. The enums which are not defined move "out", allowing the first ones to take the slots in the enum, and since the array is sized on ADC_PIN_COUNT, we always have the right size data and in order.
* Update Malyan M200 pins
Update Malyan M200 pins with correct fan values.
* Test all pins on actual hardware, update definitions
Some of the pin definitions were from knowlege base/pdfs. Now they've been tested against actual hardware. This should be very close to final.
* Update HAL_timers_Stm32f1.cpp
* Add sample configurations for Malyan M200
Add sample configuration for Malyan M200 without bed leveling, and move fan to auto cool E0 since this printer by default has only one fan.
Choose the timer based on MCU defintion. Timer5 is not valid on C8/CB class boards, so use Timer4 for the step timer.
readme.md update
* Updates to timers, and some stm32 boards definitiions
* Correct pin toggle macro.
* Remove duplicated Malyan M200 entry from pins.h
* Update configuration_store.cpp
* Formatting, indentation
* Formatting in HAL_Stm32f1.cpp
2017-12-11 05:12:45 +00:00
|
|
|
#elif MB(STM3R_MINI)
|
|
|
|
#include "pins_STM3R_MINI.h"
|
|
|
|
#elif MB(MALYAN_M200)
|
|
|
|
#include "pins_MALYAN_M200.h"
|
|
|
|
#elif MB(BEAST)
|
|
|
|
#include "pins_BEAST.h"
|
|
|
|
#elif MB(CHITU3D)
|
|
|
|
#include "pins_CHITU3D.h"
|
2017-10-25 06:16:54 +00:00
|
|
|
#elif MB(MKS_SBASE)
|
2017-10-14 14:44:18 +00:00
|
|
|
#include "pins_MKS_SBASE.h"
|
2017-10-25 06:16:54 +00:00
|
|
|
#elif MB(AZSMZ_MINI)
|
|
|
|
#include "pins_AZSMZ_MINI.h"
|
2017-10-30 21:01:20 +00:00
|
|
|
#elif MB(AZTEEG_X5_GT)
|
|
|
|
#include "pins_AZTEEG_X5_GT.h"
|
2017-11-08 03:14:46 +00:00
|
|
|
#elif MB(BIQU_BQ111_A4)
|
|
|
|
#include "pins_BIQU_BQ111_A4.h"
|
2011-12-12 18:34:37 +00:00
|
|
|
#else
|
2016-05-13 12:10:23 +00:00
|
|
|
#error "Unknown MOTHERBOARD value set in Configuration.h"
|
2011-12-12 18:34:37 +00:00
|
|
|
#endif
|
|
|
|
|
2016-05-08 01:41:20 +00:00
|
|
|
// Define certain undefined pins
|
|
|
|
#ifndef X_MS1_PIN
|
|
|
|
#define X_MS1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef X_MS2_PIN
|
|
|
|
#define X_MS2_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef Y_MS1_PIN
|
|
|
|
#define Y_MS1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef Y_MS2_PIN
|
|
|
|
#define Y_MS2_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef Z_MS1_PIN
|
|
|
|
#define Z_MS1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef Z_MS2_PIN
|
|
|
|
#define Z_MS2_PIN -1
|
|
|
|
#endif
|
2017-10-29 00:45:07 +00:00
|
|
|
#ifndef E0_STEP_PIN
|
|
|
|
#define E0_STEP_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E0_DIR_PIN
|
|
|
|
#define E0_DIR_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E0_ENABLE_PIN
|
|
|
|
#define E0_ENABLE_PIN -1
|
|
|
|
#endif
|
2016-05-08 01:41:20 +00:00
|
|
|
#ifndef E0_MS1_PIN
|
|
|
|
#define E0_MS1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E0_MS2_PIN
|
|
|
|
#define E0_MS2_PIN -1
|
|
|
|
#endif
|
2017-10-29 00:45:07 +00:00
|
|
|
#ifndef E1_STEP_PIN
|
|
|
|
#define E1_STEP_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E1_DIR_PIN
|
|
|
|
#define E1_DIR_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E1_ENABLE_PIN
|
|
|
|
#define E1_ENABLE_PIN -1
|
|
|
|
#endif
|
2016-05-08 01:41:20 +00:00
|
|
|
#ifndef E1_MS1_PIN
|
|
|
|
#define E1_MS1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E1_MS2_PIN
|
|
|
|
#define E1_MS2_PIN -1
|
|
|
|
#endif
|
2017-10-29 00:45:07 +00:00
|
|
|
#ifndef E2_STEP_PIN
|
|
|
|
#define E2_STEP_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E2_DIR_PIN
|
|
|
|
#define E2_DIR_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E2_ENABLE_PIN
|
|
|
|
#define E2_ENABLE_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E3_STEP_PIN
|
|
|
|
#define E3_STEP_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E3_DIR_PIN
|
|
|
|
#define E3_DIR_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E3_ENABLE_PIN
|
|
|
|
#define E3_ENABLE_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E4_STEP_PIN
|
|
|
|
#define E4_STEP_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E4_DIR_PIN
|
|
|
|
#define E4_DIR_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef E4_ENABLE_PIN
|
|
|
|
#define E4_ENABLE_PIN -1
|
|
|
|
#endif
|
2016-05-08 01:41:20 +00:00
|
|
|
|
|
|
|
#ifndef FAN_PIN
|
|
|
|
#define FAN_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef FAN1_PIN
|
|
|
|
#define FAN1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef FAN2_PIN
|
|
|
|
#define FAN2_PIN -1
|
|
|
|
#endif
|
2017-05-03 01:18:31 +00:00
|
|
|
#ifndef CONTROLLER_FAN_PIN
|
|
|
|
#define CONTROLLER_FAN_PIN -1
|
2016-08-07 00:16:16 +00:00
|
|
|
#endif
|
2016-05-08 01:41:20 +00:00
|
|
|
|
2017-08-15 12:48:10 +00:00
|
|
|
#ifndef FANMUX0_PIN
|
|
|
|
#define FANMUX0_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef FANMUX1_PIN
|
|
|
|
#define FANMUX1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef FANMUX2_PIN
|
|
|
|
#define FANMUX2_PIN -1
|
|
|
|
#endif
|
|
|
|
|
2016-05-08 01:41:20 +00:00
|
|
|
#ifndef HEATER_0_PIN
|
|
|
|
#define HEATER_0_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef HEATER_1_PIN
|
|
|
|
#define HEATER_1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef HEATER_2_PIN
|
|
|
|
#define HEATER_2_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef HEATER_3_PIN
|
|
|
|
#define HEATER_3_PIN -1
|
|
|
|
#endif
|
2016-10-05 06:49:59 +00:00
|
|
|
#ifndef HEATER_4_PIN
|
|
|
|
#define HEATER_4_PIN -1
|
|
|
|
#endif
|
2016-05-08 01:41:20 +00:00
|
|
|
#ifndef HEATER_BED_PIN
|
|
|
|
#define HEATER_BED_PIN -1
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef TEMP_0_PIN
|
|
|
|
#define TEMP_0_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef TEMP_1_PIN
|
|
|
|
#define TEMP_1_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef TEMP_2_PIN
|
|
|
|
#define TEMP_2_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef TEMP_3_PIN
|
|
|
|
#define TEMP_3_PIN -1
|
|
|
|
#endif
|
2017-04-06 21:46:30 +00:00
|
|
|
#ifndef TEMP_4_PIN
|
|
|
|
#define TEMP_4_PIN -1
|
|
|
|
#endif
|
2016-05-08 01:41:20 +00:00
|
|
|
#ifndef TEMP_BED_PIN
|
|
|
|
#define TEMP_BED_PIN -1
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef SD_DETECT_PIN
|
|
|
|
#define SD_DETECT_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef SDPOWER
|
|
|
|
#define SDPOWER -1
|
|
|
|
#endif
|
|
|
|
#ifndef LED_PIN
|
|
|
|
#define LED_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef PS_ON_PIN
|
|
|
|
#define PS_ON_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef KILL_PIN
|
|
|
|
#define KILL_PIN -1
|
|
|
|
#endif
|
|
|
|
#ifndef SUICIDE_PIN
|
|
|
|
#define SUICIDE_PIN -1
|
|
|
|
#endif
|
|
|
|
|
2016-10-22 15:07:51 +00:00
|
|
|
#ifndef MAX_EXTRUDERS
|
2017-04-06 21:46:30 +00:00
|
|
|
#define MAX_EXTRUDERS 5
|
2016-10-22 15:07:51 +00:00
|
|
|
#endif
|
|
|
|
|
2016-10-22 23:25:59 +00:00
|
|
|
//
|
|
|
|
// Assign auto fan pins if needed
|
|
|
|
//
|
|
|
|
#if !defined(E0_AUTO_FAN_PIN) && defined(ORIG_E0_AUTO_FAN_PIN)
|
|
|
|
#define E0_AUTO_FAN_PIN ORIG_E0_AUTO_FAN_PIN
|
|
|
|
#endif
|
|
|
|
#if !defined(E1_AUTO_FAN_PIN) && defined(ORIG_E1_AUTO_FAN_PIN)
|
|
|
|
#define E1_AUTO_FAN_PIN ORIG_E1_AUTO_FAN_PIN
|
|
|
|
#endif
|
|
|
|
#if !defined(E2_AUTO_FAN_PIN) && defined(ORIG_E2_AUTO_FAN_PIN)
|
|
|
|
#define E2_AUTO_FAN_PIN ORIG_E2_AUTO_FAN_PIN
|
|
|
|
#endif
|
|
|
|
#if !defined(E3_AUTO_FAN_PIN) && defined(ORIG_E3_AUTO_FAN_PIN)
|
|
|
|
#define E3_AUTO_FAN_PIN ORIG_E3_AUTO_FAN_PIN
|
|
|
|
#endif
|
2017-04-08 07:42:07 +00:00
|
|
|
#if !defined(E4_AUTO_FAN_PIN) && defined(ORIG_E4_AUTO_FAN_PIN)
|
|
|
|
#define E4_AUTO_FAN_PIN ORIG_E4_AUTO_FAN_PIN
|
|
|
|
#endif
|
2016-10-22 23:25:59 +00:00
|
|
|
|
2015-01-26 03:43:43 +00:00
|
|
|
// List of pins which to ignore when asked to change by gcode, 0 and 1 are RX and TX, do not mess with those!
|
2016-05-27 00:43:20 +00:00
|
|
|
#define _E0_PINS E0_STEP_PIN, E0_DIR_PIN, E0_ENABLE_PIN, E0_MS1_PIN, E0_MS2_PIN,
|
2015-01-27 23:19:03 +00:00
|
|
|
#define _E1_PINS
|
|
|
|
#define _E2_PINS
|
|
|
|
#define _E3_PINS
|
2016-10-05 06:49:59 +00:00
|
|
|
#define _E4_PINS
|
2015-01-27 23:19:03 +00:00
|
|
|
|
2017-06-19 21:54:37 +00:00
|
|
|
#if ENABLED(SWITCHING_EXTRUDER)
|
|
|
|
// Tools 0 and 1 use E0
|
|
|
|
#if EXTRUDERS > 2 // Tools 2 and 3 use E1
|
|
|
|
#undef _E1_PINS
|
|
|
|
#define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN, E1_MS1_PIN, E1_MS2_PIN,
|
|
|
|
#if EXTRUDERS > 4 // Tools 4 and 5 use E2
|
|
|
|
#undef _E2_PINS
|
|
|
|
#define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN,
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
#elif EXTRUDERS > 1
|
2015-03-28 03:29:05 +00:00
|
|
|
#undef _E1_PINS
|
2016-05-27 00:43:20 +00:00
|
|
|
#define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN, E1_MS1_PIN, E1_MS2_PIN,
|
2015-01-26 13:17:08 +00:00
|
|
|
#if EXTRUDERS > 2
|
2015-03-28 03:29:05 +00:00
|
|
|
#undef _E2_PINS
|
2016-05-27 00:43:20 +00:00
|
|
|
#define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN,
|
2015-01-26 13:17:08 +00:00
|
|
|
#if EXTRUDERS > 3
|
2015-03-28 03:29:05 +00:00
|
|
|
#undef _E3_PINS
|
2016-05-27 00:43:20 +00:00
|
|
|
#define _E3_PINS E3_STEP_PIN, E3_DIR_PIN, E3_ENABLE_PIN,
|
2016-10-05 06:49:59 +00:00
|
|
|
#if EXTRUDERS > 4
|
|
|
|
#undef _E4_PINS
|
|
|
|
#define _E4_PINS E4_STEP_PIN, E4_DIR_PIN, E4_ENABLE_PIN,
|
2017-04-06 21:46:30 +00:00
|
|
|
#endif // EXTRUDERS > 4
|
|
|
|
#endif // EXTRUDERS > 3
|
|
|
|
#endif // EXTRUDERS > 2
|
|
|
|
#endif // EXTRUDERS > 1
|
2016-05-27 00:43:20 +00:00
|
|
|
|
2017-11-25 04:15:56 +00:00
|
|
|
#define _H0_PINS HEATER_0_PIN, E0_AUTO_FAN_PIN, analogInputToDigitalPin(TEMP_0_PIN),
|
2016-05-27 00:43:20 +00:00
|
|
|
#define _H1_PINS
|
|
|
|
#define _H2_PINS
|
|
|
|
#define _H3_PINS
|
2016-10-05 06:49:59 +00:00
|
|
|
#define _H4_PINS
|
2016-05-27 00:43:20 +00:00
|
|
|
|
|
|
|
#if HOTENDS > 1
|
|
|
|
#undef _H1_PINS
|
2017-11-25 04:15:56 +00:00
|
|
|
#define _H1_PINS HEATER_1_PIN, E1_AUTO_FAN_PIN, analogInputToDigitalPin(TEMP_1_PIN),
|
2016-05-27 00:43:20 +00:00
|
|
|
#if HOTENDS > 2
|
|
|
|
#undef _H2_PINS
|
2017-11-25 04:15:56 +00:00
|
|
|
#define _H2_PINS HEATER_2_PIN, E2_AUTO_FAN_PIN, analogInputToDigitalPin(TEMP_2_PIN),
|
2016-05-27 00:43:20 +00:00
|
|
|
#if HOTENDS > 3
|
|
|
|
#undef _H3_PINS
|
2017-11-25 04:15:56 +00:00
|
|
|
#define _H3_PINS HEATER_3_PIN, E3_AUTO_FAN_PIN, analogInputToDigitalPin(TEMP_3_PIN),
|
2016-10-05 06:49:59 +00:00
|
|
|
#if HOTENDS > 4
|
|
|
|
#undef _H4_PINS
|
2017-11-25 04:15:56 +00:00
|
|
|
#define _H4_PINS HEATER_4_PIN, analogInputToDigitalPin(TEMP_4_PIN),
|
2017-04-06 21:46:30 +00:00
|
|
|
#endif // HOTENDS > 4
|
|
|
|
#endif // HOTENDS > 3
|
|
|
|
#endif // HOTENDS > 2
|
2016-06-28 22:06:56 +00:00
|
|
|
#elif ENABLED(MIXING_EXTRUDER)
|
|
|
|
#undef _E1_PINS
|
|
|
|
#define _E1_PINS E1_STEP_PIN, E1_DIR_PIN, E1_ENABLE_PIN,
|
|
|
|
#if MIXING_STEPPERS > 2
|
|
|
|
#undef _E2_PINS
|
|
|
|
#define _E2_PINS E2_STEP_PIN, E2_DIR_PIN, E2_ENABLE_PIN,
|
|
|
|
#if MIXING_STEPPERS > 3
|
|
|
|
#undef _E3_PINS
|
|
|
|
#define _E3_PINS E3_STEP_PIN, E3_DIR_PIN, E3_ENABLE_PIN,
|
2016-10-05 06:49:59 +00:00
|
|
|
#if MIXING_STEPPERS > 4
|
|
|
|
#undef _E4_PINS
|
|
|
|
#define _E4_PINS E4_STEP_PIN, E4_DIR_PIN, E4_ENABLE_PIN,
|
2017-04-06 21:46:30 +00:00
|
|
|
#endif // MIXING_STEPPERS > 4
|
|
|
|
#endif // MIXING_STEPPERS > 3
|
|
|
|
#endif // MIXING_STEPPERS > 2
|
|
|
|
#endif // MIXING_STEPPERS > 1
|
2012-02-29 14:49:02 +00:00
|
|
|
|
2017-11-25 04:15:56 +00:00
|
|
|
#define BED_PINS HEATER_BED_PIN, analogInputToDigitalPin(TEMP_BED_PIN),
|
2016-05-08 01:41:20 +00:00
|
|
|
|
|
|
|
//
|
|
|
|
// Assign endstop pins for boards with only 3 connectors
|
|
|
|
//
|
2012-12-16 20:08:55 +00:00
|
|
|
#ifdef X_STOP_PIN
|
|
|
|
#if X_HOME_DIR < 0
|
|
|
|
#define X_MIN_PIN X_STOP_PIN
|
|
|
|
#define X_MAX_PIN -1
|
|
|
|
#else
|
|
|
|
#define X_MIN_PIN -1
|
|
|
|
#define X_MAX_PIN X_STOP_PIN
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef Y_STOP_PIN
|
|
|
|
#if Y_HOME_DIR < 0
|
|
|
|
#define Y_MIN_PIN Y_STOP_PIN
|
|
|
|
#define Y_MAX_PIN -1
|
|
|
|
#else
|
|
|
|
#define Y_MIN_PIN -1
|
|
|
|
#define Y_MAX_PIN Y_STOP_PIN
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef Z_STOP_PIN
|
|
|
|
#if Z_HOME_DIR < 0
|
|
|
|
#define Z_MIN_PIN Z_STOP_PIN
|
|
|
|
#define Z_MAX_PIN -1
|
|
|
|
#else
|
|
|
|
#define Z_MIN_PIN -1
|
|
|
|
#define Z_MAX_PIN Z_STOP_PIN
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
2016-05-08 01:41:20 +00:00
|
|
|
//
|
|
|
|
// Disable unused endstop / probe pins
|
|
|
|
//
|
2016-09-19 04:28:11 +00:00
|
|
|
#if DISABLED(Z_MIN_PROBE_ENDSTOP)
|
2015-08-10 08:35:39 +00:00
|
|
|
#undef Z_MIN_PROBE_PIN
|
|
|
|
#define Z_MIN_PROBE_PIN -1
|
2015-03-28 09:31:51 +00:00
|
|
|
#endif
|
|
|
|
|
2016-03-02 10:00:34 +00:00
|
|
|
#if DISABLED(USE_XMAX_PLUG)
|
2015-03-24 17:06:44 +00:00
|
|
|
#undef X_MAX_PIN
|
|
|
|
#define X_MAX_PIN -1
|
|
|
|
#endif
|
|
|
|
|
2016-03-02 10:00:34 +00:00
|
|
|
#if DISABLED(USE_YMAX_PLUG)
|
2016-03-23 11:48:06 +00:00
|
|
|
#undef Y_MAX_PIN
|
2015-03-24 17:06:44 +00:00
|
|
|
#define Y_MAX_PIN -1
|
|
|
|
#endif
|
|
|
|
|
2016-03-02 10:00:34 +00:00
|
|
|
#if DISABLED(USE_ZMAX_PLUG)
|
2015-03-24 17:06:44 +00:00
|
|
|
#undef Z_MAX_PIN
|
|
|
|
#define Z_MAX_PIN -1
|
|
|
|
#endif
|
|
|
|
|
2016-03-02 10:00:34 +00:00
|
|
|
#if DISABLED(USE_XMIN_PLUG)
|
|
|
|
#undef X_MIN_PIN
|
|
|
|
#define X_MIN_PIN -1
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#if DISABLED(USE_YMIN_PLUG)
|
|
|
|
#undef Y_MIN_PIN
|
|
|
|
#define Y_MIN_PIN -1
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#if DISABLED(USE_ZMIN_PLUG)
|
2015-10-03 06:08:58 +00:00
|
|
|
#undef Z_MIN_PIN
|
2015-03-24 17:06:44 +00:00
|
|
|
#define Z_MIN_PIN -1
|
|
|
|
#endif
|
|
|
|
|
2017-07-07 03:47:37 +00:00
|
|
|
#ifndef LCD_PINS_D4
|
|
|
|
#define LCD_PINS_D4 -1
|
|
|
|
#endif
|
|
|
|
#ifndef LCD_PINS_D5
|
|
|
|
#define LCD_PINS_D5 -1
|
|
|
|
#endif
|
|
|
|
#ifndef LCD_PINS_D6
|
|
|
|
#define LCD_PINS_D6 -1
|
|
|
|
#endif
|
|
|
|
#ifndef LCD_PINS_D7
|
|
|
|
#define LCD_PINS_D7 -1
|
|
|
|
#endif
|
|
|
|
|
2016-02-10 04:04:07 +00:00
|
|
|
//
|
2016-05-17 21:56:49 +00:00
|
|
|
// Dual X-carriage, Dual Y, Dual Z support
|
2016-02-10 04:04:07 +00:00
|
|
|
//
|
|
|
|
|
2016-05-17 21:56:49 +00:00
|
|
|
#define _X2_PINS
|
|
|
|
#define _Y2_PINS
|
|
|
|
#define _Z2_PINS
|
|
|
|
|
2016-02-10 04:04:07 +00:00
|
|
|
#define __EPIN(p,q) E##p##_##q##_PIN
|
|
|
|
#define _EPIN(p,q) __EPIN(p,q)
|
|
|
|
|
2016-07-11 17:19:07 +00:00
|
|
|
// The X2 axis, if any, should be the next open extruder port
|
|
|
|
#if ENABLED(DUAL_X_CARRIAGE) || ENABLED(X_DUAL_STEPPER_DRIVERS)
|
2016-05-17 21:56:49 +00:00
|
|
|
#ifndef X2_STEP_PIN
|
2016-06-28 22:06:56 +00:00
|
|
|
#define X2_STEP_PIN _EPIN(E_STEPPERS, STEP)
|
|
|
|
#define X2_DIR_PIN _EPIN(E_STEPPERS, DIR)
|
|
|
|
#define X2_ENABLE_PIN _EPIN(E_STEPPERS, ENABLE)
|
2017-10-29 00:45:07 +00:00
|
|
|
#if E_STEPPERS > 4 || !PIN_EXISTS(X2_ENABLE)
|
2017-05-02 20:08:16 +00:00
|
|
|
#error "No E stepper plug left for X2!"
|
|
|
|
#endif
|
2016-05-17 21:56:49 +00:00
|
|
|
#endif
|
|
|
|
#undef _X2_PINS
|
|
|
|
#define _X2_PINS X2_STEP_PIN, X2_DIR_PIN, X2_ENABLE_PIN,
|
2016-06-28 22:06:56 +00:00
|
|
|
#define Y2_E_INDEX INCREMENT(E_STEPPERS)
|
2016-05-17 21:56:49 +00:00
|
|
|
#else
|
2016-06-28 22:06:56 +00:00
|
|
|
#define Y2_E_INDEX E_STEPPERS
|
2016-05-17 21:56:49 +00:00
|
|
|
#endif
|
|
|
|
|
2016-02-10 04:04:07 +00:00
|
|
|
// The Y2 axis, if any, should be the next open extruder port
|
2016-07-11 17:19:07 +00:00
|
|
|
#if ENABLED(Y_DUAL_STEPPER_DRIVERS)
|
|
|
|
#ifndef Y2_STEP_PIN
|
|
|
|
#define Y2_STEP_PIN _EPIN(Y2_E_INDEX, STEP)
|
|
|
|
#define Y2_DIR_PIN _EPIN(Y2_E_INDEX, DIR)
|
|
|
|
#define Y2_ENABLE_PIN _EPIN(Y2_E_INDEX, ENABLE)
|
2017-10-29 00:45:07 +00:00
|
|
|
#if Y2_E_INDEX > 4 || !PIN_EXISTS(Y2_ENABLE)
|
2017-05-02 20:08:16 +00:00
|
|
|
#error "No E stepper plug left for Y2!"
|
|
|
|
#endif
|
2016-07-11 17:19:07 +00:00
|
|
|
#endif
|
2016-05-17 21:56:49 +00:00
|
|
|
#undef _Y2_PINS
|
|
|
|
#define _Y2_PINS Y2_STEP_PIN, Y2_DIR_PIN, Y2_ENABLE_PIN,
|
2016-07-11 17:19:07 +00:00
|
|
|
#define Z2_E_INDEX INCREMENT(Y2_E_INDEX)
|
|
|
|
#else
|
|
|
|
#define Z2_E_INDEX Y2_E_INDEX
|
2015-08-28 01:08:09 +00:00
|
|
|
#endif
|
|
|
|
|
2016-02-10 04:04:07 +00:00
|
|
|
// The Z2 axis, if any, should be the next open extruder port
|
2016-07-11 17:19:07 +00:00
|
|
|
#if ENABLED(Z_DUAL_STEPPER_DRIVERS)
|
|
|
|
#ifndef Z2_STEP_PIN
|
|
|
|
#define Z2_STEP_PIN _EPIN(Z2_E_INDEX, STEP)
|
|
|
|
#define Z2_DIR_PIN _EPIN(Z2_E_INDEX, DIR)
|
|
|
|
#define Z2_ENABLE_PIN _EPIN(Z2_E_INDEX, ENABLE)
|
2017-10-29 00:45:07 +00:00
|
|
|
#if Z2_E_INDEX > 4 || !PIN_EXISTS(Z2_ENABLE)
|
2017-05-02 20:08:16 +00:00
|
|
|
#error "No E stepper plug left for Z2!"
|
|
|
|
#endif
|
2016-07-11 17:19:07 +00:00
|
|
|
#endif
|
2016-05-17 21:56:49 +00:00
|
|
|
#undef _Z2_PINS
|
|
|
|
#define _Z2_PINS Z2_STEP_PIN, Z2_DIR_PIN, Z2_ENABLE_PIN,
|
2015-08-28 01:08:09 +00:00
|
|
|
#endif
|
|
|
|
|
2017-10-26 18:37:26 +00:00
|
|
|
#ifndef HAL_SENSITIVE_PINS
|
2017-11-20 05:00:43 +00:00
|
|
|
#define HAL_SENSITIVE_PINS
|
2017-10-26 18:37:26 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#define SENSITIVE_PINS { \
|
2015-10-03 06:08:58 +00:00
|
|
|
X_STEP_PIN, X_DIR_PIN, X_ENABLE_PIN, X_MIN_PIN, X_MAX_PIN, \
|
|
|
|
Y_STEP_PIN, Y_DIR_PIN, Y_ENABLE_PIN, Y_MIN_PIN, Y_MAX_PIN, \
|
|
|
|
Z_STEP_PIN, Z_DIR_PIN, Z_ENABLE_PIN, Z_MIN_PIN, Z_MAX_PIN, Z_MIN_PROBE_PIN, \
|
2017-05-03 01:18:31 +00:00
|
|
|
PS_ON_PIN, HEATER_BED_PIN, FAN_PIN, FAN1_PIN, FAN2_PIN, CONTROLLER_FAN_PIN, \
|
2016-10-05 06:49:59 +00:00
|
|
|
_E0_PINS _E1_PINS _E2_PINS _E3_PINS _E4_PINS BED_PINS \
|
|
|
|
_H0_PINS _H1_PINS _H2_PINS _H3_PINS _H4_PINS \
|
2016-05-17 21:56:49 +00:00
|
|
|
_X2_PINS _Y2_PINS _Z2_PINS \
|
2017-10-26 18:37:26 +00:00
|
|
|
X_MS1_PIN, X_MS2_PIN, Y_MS1_PIN, Y_MS2_PIN, Z_MS1_PIN, Z_MS2_PIN, \
|
|
|
|
HAL_SENSITIVE_PINS \
|
2015-10-03 06:08:58 +00:00
|
|
|
}
|
2015-01-26 03:43:43 +00:00
|
|
|
|
2016-07-27 10:40:44 +00:00
|
|
|
#define HAS_DIGIPOTSS (PIN_EXISTS(DIGIPOTSS))
|
|
|
|
|
2017-06-17 23:36:10 +00:00
|
|
|
// Note: default SPI pins are defined in the HAL
|
|
|
|
|
2017-09-06 11:28:32 +00:00
|
|
|
#include "../HAL/HAL_spi_pins.h"
|
2016-07-27 10:40:44 +00:00
|
|
|
|
2017-06-06 09:32:31 +00:00
|
|
|
#endif // __PINS_H__
|