Skip to content

Commit

Permalink
Try MAPLIST here
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed Jun 20, 2022
1 parent 359d406 commit 44730a3
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions Marlin/src/module/stepper/trinamic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1057,10 +1057,8 @@ void reset_trinamic_drivers() {
#if ANY_AXIS_HAS(SW_SERIAL)
struct SanitySwSerialDetails { int32_t txpin; int32_t rxpin; uint32_t address; };
#define TMC_SW_DETAIL_ARGS(A) TERN(A##_HAS_SW_SERIAL, A##_SERIAL_TX_PIN, -1), TERN(A##_HAS_SW_SERIAL, A##_SERIAL_RX_PIN, -1), TERN0(A##_HAS_SW_SERIAL, A##_SLAVE_ADDRESS)
#define TMC_SW_DETAIL(A) TMC_SW_DETAIL_ARGS(A),
constexpr SanitySwSerialDetails sanity_tmc_sw_details[] = {
MAP(TMC_SW_DETAIL, ALL_AXIS_NAMES)
};
#define TMC_SW_DETAIL(A) { TMC_SW_DETAIL_ARGS(A) }
constexpr SanitySwSerialDetails sanity_tmc_sw_details[] = { MAPLIST(TMC_SW_DETAIL, ALL_AXIS_NAMES) };

constexpr bool sc_sw_done(size_t start, size_t end) { return start == end; }
constexpr bool sc_sw_skip(int32_t txpin) { return txpin < 0; }
Expand Down

0 comments on commit 44730a3

Please sign in to comment.