Skip to content

Commit

Permalink
Updated to support the enhanced ioPorts interface and using the new t…
Browse files Browse the repository at this point in the history
…ask scheduler for debouncing etc.

Moved probe and safety door inputs to ioPorts pin pool.
  • Loading branch information
terjeio committed Feb 23, 2024
1 parent 2770085 commit c1c0c1f
Show file tree
Hide file tree
Showing 17 changed files with 718 additions and 850 deletions.
18 changes: 9 additions & 9 deletions btt_skr_pico_10_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@
Copyright (c) 2022-2024 Terje Io
Grbl is free software: you can redistribute it and/or modify
grblHAL 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.
Grbl is distributed in the hope that it will be useful,
grblHAL 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
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 Grbl. If not, see <http://www.gnu.org/licenses/>.
along with grblHAL. If not, see <http://www.gnu.org/licenses/>.
*/

#if N_ABC_MOTORS > 1
Expand Down Expand Up @@ -70,7 +70,6 @@
#endif

// Define homing/hard limit switch input pins.
#define LIMIT_PORT GPIO_IN
#define X_LIMIT_PIN 4
#define Y_LIMIT_PIN 3
#define Z_LIMIT_PIN 25
Expand Down Expand Up @@ -113,12 +112,17 @@
#if N_ABC_MOTORS == 0

#define AUXINPUT0_PIN 15
#define AUXINPUT1_PIN 22 // Probe

// Define user-control controls (cycle start, reset, feed hold) input pins.
#define RESET_PIN 16
#define FEED_HOLD_PIN 13
#define CYCLE_START_PIN 14

#if PROBE_ENABLE
#define PROBE_PIN AUXINPUT1_PIN
#endif

#if SAFETY_DOOR_ENABLE
#define SAFETY_DOOR_PIN AUXINPUT0_PIN
#elif MOTOR_FAULT_ENABLE
Expand All @@ -127,10 +131,6 @@

#endif

// Define probe switch input pin.
#define PROBE_PORT GPIO_INPUT
#define PROBE_PIN 22

#if MODBUS_ENABLE
#define MODBUS_SERIAL_PORT 0
#endif
38 changes: 22 additions & 16 deletions cnc_boosterpack_map.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@
Part of grblHAL
Copyright (c) 2021-2023 Terje Io
Copyright (c) 2021-2024 Terje Io
Grbl is free software: you can redistribute it and/or modify
grblHAL 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.
Grbl is distributed in the hope that it will be useful,
grblHAL 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
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 Grbl. If not, see <http://www.gnu.org/licenses/>.
along with grblHAL. If not, see <http://www.gnu.org/licenses/>.
*/

#if TRINAMIC_ENABLE
Expand Down Expand Up @@ -54,7 +54,6 @@
#define STEPPERS_ENABLEZ_PIN 0

// Define homing/hard limit switch input pins.
#define LIMIT_PORT GPIO_IN
#define X_LIMIT_PIN 19
#define Y_LIMIT_PIN 20
#define Z_LIMIT_PIN 10
Expand Down Expand Up @@ -88,19 +87,30 @@
#define COOLANT_MIST_PIN 3

// Define user-control controls (cycle start, reset, feed hold) input pins.

#define AUXINPUT0_PIN 15
#define AUXINPUT1_PIN 17
#define AUXINPUT2_PIN 18
#define AUXINPUT3_PIN 16 // Probe

#define RESET_PIN 12
#define FEED_HOLD_PIN 13
#define CYCLE_START_PIN 14
#if SAFETY_DOOR_ENABLE
#define SAFETY_DOOR_PIN 15

#if PROBE_ENABLE
#define PROBE_PIN AUXINPUT3_PIN
#endif

// Define probe switch input pin.
#define PROBE_PORT GPIO_INPUT
#define PROBE_PIN 16
#if MPG_MODE_ENABLE
#define MODE_SWITCH_PIN AUXINPUT2_PIN
#endif

#if I2C_STROBE_ENABLE
#define I2C_STROBE_PIN 17
#define I2C_STROBE_PIN AUXINPUT1_PIN
#endif

#if SAFETY_DOOR_ENABLE
#define SAFETY_DOOR_PIN AUXINPUT0_PIN
#endif

#define I2C_PORT 1
Expand All @@ -115,9 +125,5 @@
#define SD_MOSI_PIN 19
#endif

#if MPG_MODE_ENABLE
#define MODE_SWITCH_PIN 18
#endif

//I2C: 26,27
//Free: 21,21,22,28
Loading

0 comments on commit c1c0c1f

Please sign in to comment.