Pins Map - markniu/PandaPi GitHub Wiki

Name PI GPIO PandaPI Klipper(V2.8) Klipper(V2.9)/standalone(V2.9)
X_Endstop 18 1 PA3 PA3
Y_Endstop 23 4 PA4 PC9
Z_Endstop 7 11 PA1 PA1
X_Step 4 7 PB8 PC11
X_Dir 27 2 PB6 PB6
Y_Step 10 12 PB5 PB5
Y_Dir 24 5 PB4 PB4
Z_Step 11 14 PB3 PB3
Z_Dir 9 13 PA15 PA15
E0_Step 8 10 PB15 PB15
E0_Dir 25 6 PB14 PB14
E1_Step 12 26 PB2 PB2
E1_Dir 26 25 PA7 PC6
E2_Step 1 31 PA6 PC7
E2_Dir 5 21 PA5 PC8
XYZE_ENABLE 17 0 PB9 PC12
BLTOUCH_Signal PA11 PA11
Heater Bed PB13 PB13
Heater_Hotend0 PB12 PB12
Heater_Hotend1 PA12 PA12
Fan0(Hotend0) PA8 PA8
Fan1(model) PA9 PA9
Fan2(board) PA10 PA10
Fan3 PB7 PB7
Bed Thermistor PB1 PB1
Hotend0 Thermistor PB0 PB0
Hotend1 Thermistor PA2 PA2
Filament Runout PA14 PA14
DHT11 22 3
Beeper 19 24 PC3
LCD_BTN 0 30 PA0
LCD_BTN1 6 22 PC4
LCD_BTN2 13 23 PC5
LCD_RS 20 28 PC0
LCD_ENABLE 21 29 PC2
LCD_D4 16 27 PC1
STLINK_SDA PA13 PA13
STLINK_SCL PA14 PA14
UART_TMC2209_TX 14 15 PB10 PB10
SD_SS PA4
SD_SCK PA5
SD_MISO PA6
SD_MOSI PA7

pins_PANDA_PI.h

//
// Steppers
//
#define X_STEP_PIN         7 
#define X_DIR_PIN          2 
#define X_ENABLE_PIN       0 

#define Y_STEP_PIN         12 
#define Y_DIR_PIN          5 
#define Y_ENABLE_PIN       0 

#define Z_STEP_PIN         14 
#define Z_DIR_PIN          13 
#define Z_ENABLE_PIN       0 


#define E0_STEP_PIN        10 
#define E0_DIR_PIN         6 
#define E0_ENABLE_PIN      0 

#define E1_STEP_PIN        26
#define E1_DIR_PIN         25
#define E1_ENABLE_PIN      0

#define E2_STEP_PIN        31
#define E2_DIR_PIN         21
#define E2_ENABLE_PIN      0

Pins for LCD12864 REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER


	#define LCD_PINS_RS      28 
	#define LCD_PINS_ENABLE  29 
	#define LCD_PINS_D4      27  
	#define BEEPER_PIN		24 
	#define BTN_ENC 		30 
	#define BTN_EN1 		22 
	#define BTN_EN2 		23 


For example, if you want to switch extruder motor E0 and E2 on the board. just switch the driver pins of E0 and E2 in pins_PANDA_PI.h

before:

#define E0_STEP_PIN        10 
#define E0_DIR_PIN         6 
#define E0_ENABLE_PIN      0 

#define E2_STEP_PIN        31
#define E2_DIR_PIN         21
#define E2_ENABLE_PIN      0

after:

#define E0_STEP_PIN        31 
#define E0_DIR_PIN         21 
#define E0_ENABLE_PIN      0 

#define E2_STEP_PIN        10
#define E2_DIR_PIN         6
#define E2_ENABLE_PIN      0

will i still be able to control the lights and psu from the pi ?

you can find all the GPIO pins of raspberryPi on pandapi board. if your printer have only one extruder, the GPIO for E1 and E2 drivers are free,so you can connect them out from the driver connector and used as you want.