Skip to content

Commit

Permalink
Fixed typos and incorrect preprocessor code in some untested board maps.
Browse files Browse the repository at this point in the history
  • Loading branch information
terjeio committed Jan 10, 2025
1 parent bd8cea8 commit 88b8c17
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 19 deletions.
9 changes: 2 additions & 7 deletions main/boards/root_cnc_pro_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,12 @@
#error No free pins for I2C keypad!
#endif

#if TRINAMIC_ENABLE != 5160
#error BOARD_ROOTCNC_PRO has soldered TMC5160 drivers.
#endif

#include "use_i2s_out.h"

#define BOARD_NAME "Root CNC Pro"
#define BOARD_URL "https://wiki.rootcnc.com/en/Root-Controller-pro/DetailedInfo"

#if SDCARD_ENABLE || TRINAMIC_SPI_ENABLE

#if SDCARD_ENABLE
// Pin mapping when using SPI mode.
// With this mapping, SD card can be used both in SPI and 1-line SD mode.
// Note that a pull-up on CS line is required in SD mode.
Expand All @@ -49,7 +44,7 @@
#define PIN_NUM_CS GPIO_NUM_5
#endif

#endif // SDCARD_ENABLE || TRINAMIC_SPI_ENABLE
#endif // SDCARD_ENABLE

#define I2S_OUT_BCK GPIO_NUM_22
#define I2S_OUT_WS GPIO_NUM_21
Expand Down
5 changes: 1 addition & 4 deletions main/boards/root_cnc_v2_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,15 @@
#error No free pins for I2C keypad!
#endif

#if SDCARD_ENABLE || TRINAMIC_SPI_ENABLE

#if SDCARD_ENABLE
// Pin mapping when using SPI mode.
// With this mapping, SD card can be used both in SPI and 1-line SD mode.
#define PIN_NUM_MISO 19
#define PIN_NUM_MOSI 23
#define PIN_NUM_CLK 18
#if SDCARD_ENABLE
// Note that a pull-up on CS line is required in SD mode.
#define PIN_NUM_CS 5
#endif // SDCARD_ENABLE
#endif // SDCARD_ENABLE || TRINAMIC_SPI_ENABLE

#define I2S_OUT_BCK GPIO_NUM_22
#define I2S_OUT_WS GPIO_NUM_17
Expand Down
5 changes: 1 addition & 4 deletions main/boards/root_cnc_v3_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,15 @@
#define BOARD_NAME "Root CNC v3"
#define BOARD_URL "https://wiki.rootcnc.com/en/Root-Controller-ISO/DetailedInfo"

#if SDCARD_ENABLE || TRINAMIC_SPI_ENABLE

#if SDCARD_ENABLE
// Pin mapping when using SPI mode.
// With this mapping, SD card can be used both in SPI and 1-line SD mode.
#define PIN_NUM_MISO 19
#define PIN_NUM_MOSI 23
#define PIN_NUM_CLK 18
#if SDCARD_ENABLE
// Note that a pull-up on CS line is required in SD mode.
#define PIN_NUM_CS 5
#endif // SDCARD_ENABLE
#endif // SDCARD_ENABLE || TRINAMIC_SPI_ENABLE

#define I2S_OUT_BCK GPIO_NUM_22
#define I2S_OUT_WS GPIO_NUM_21
Expand Down
2 changes: 1 addition & 1 deletion main/boards/sourcerabbit_4axis.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
#define AUXOUTPUT4_PIN GPIO_NUM_22 // Coolant flood
#define AUXOUTPUT5_PIN GPIO_NUM_23 // Coolant mist

/ Define driver spindle pins
// Define driver spindle pins
#if DRIVER_SPINDLE_ENABLE & SPINDLE_PWM
#define SPINDLE_PWM_PIN AUXOUTPUT2_PIN
#endif
Expand Down
9 changes: 6 additions & 3 deletions main/boards/xPro_v5_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,12 @@
#define BOARD_NAME "x-Pro v5"
#define BOARD_URL "https://www.spark-concepts.com/cnc-xpro-v5/"

#if TRINAMIC_ENABLE != 5160
#error BOARD_XPRO_V5 has soldered TMC5160 drivers.
#endif
#undef SPI_ENABLE
#undef TRINAMIC_ENABLE
#undef TRINAMIC_SPI_ENABLE
#define SPI_ENABLE 1
#define TRINAMIC_ENABLE 5160
#define TRINAMIC_SPI_ENABLE 1

#define TRINAMIC_MIXED_DRIVERS 0

Expand Down

0 comments on commit 88b8c17

Please sign in to comment.