💡
FFCP Klipper DWC Touchscreen
  • Introduction
  • Raspberry Pi Configuration
  • Setting up kiosk mode
  • Install Klipper
  • Install DWC2
  • Finishing Touches
  • Notes
  • Credit
Powered by GitBook
On this page

Was this helpful?

Install Klipper

PreviousSetting up kiosk modeNextInstall DWC2

Last updated 5 years ago

Was this helpful?

The first thing we want to do is get the path for our printer. Make sure it's plugged into your pi and run the following command.

ls /dev/serial/by-id/*

Note down the output as we'll need it later. It should look something like this

/dev/serial/by-id/usb-MakerBot_Industries_The_Replicator_1234567899135120B1B1-if00

Next we'll need to install some more dependencies

sudo apt install git wget gzip tar build-essential libjpeg8-dev imagemagick libv4l-dev cmake -y

Once those have installed we'll need to run the command below. When the window opens, you'll need to go into advanced settings and set the baud rate to 115200

git clone https://github.com/KevinOConnor/klipper 
./klipper/scripts/install-octopi.sh 
cd ~/klipper  
make menuconfig 

Your configuration should look like this.

Hit exit, and run

make clean
make

Save the following configuration to ~/printer.cfg

[stepper_x]
step_pin: PF1
dir_pin: !PF0
enable_pin: !PF2
step_distance: .01038689071
endstop_pin: ^!PL1
position_endstop: 152
position_max: 153
position_min: -120
homing_speed: 50

[stepper_y]
step_pin: PF5
dir_pin: !PF4
enable_pin: !PF6
step_distance: .01038689071
endstop_pin: ^!PL3
position_endstop: 77
position_max: 78
position_min: -84
homing_speed: 50

[stepper_z]
step_pin: PK1
dir_pin: !PK0
enable_pin: !PK2
step_distance: .0025
endstop_pin: !PL6
position_endstop: 0
position_max: 230
position_min: 0

[extruder]
step_pin: PA3
dir_pin: !PA2
enable_pin: !PA4
step_distance: .01038689071
nozzle_diameter: 0.400
filament_diameter: 1.750
heater_pin: PH3
sensor_type: MAX6675
sensor_pin: PE3
spi_software_miso_pin: PE5
spi_software_sclk_pin: PE2
#dummy mosi pin
spi_software_mosi_pin: PA1
control: pid
pid_Kp: 26.414
pid_Ki=1.115
pid_Kd=156.5054
min_temp: 0
max_temp: 260
pressure_advance: 0.07
max_extrude_only_distance: 100

[heater_fan extruder_fan]
pin: PH4

[fan]
pin: PL5


[heater_bed]
heater_pin: PL4
sensor_type: ATC Semitec 104GT-2
sensor_pin: PK7
control: pid
pid_Kp: 70.037
pid_Ki: 1.710
pid_Kd: 717.000
min_temp: 0
max_temp: 130

[mcu]
baud: 115200
serial: <PATH TO YOUR PRINTER>
restart_method: command

[printer]
kinematics: cartesian
#max_velocity: 100
#max_accel: 750
#max_z_velocity: 5
#max_z_accel: 50
max_velocity: 300
max_accel: 3000
max_z_velocity: 5
max_z_accel: 100

[mcp4018 x_axis_pot]
scl_pin: PJ5
sda_pin: PF3
wiper: 0.50
scale: 0.773

[mcp4018 y_axis_pot]
scl_pin: PJ5
sda_pin: PF7
wiper: 0.50
scale: 0.773

[mcp4018 z_axis_pot]
scl_pin: PJ5
sda_pin: PK3
wiper: 0.50
scale: 0.773

[mcp4018 a_axis_pot]
scl_pin: PJ5
sda_pin: PA5
wiper: 0.50
scale: 0.773

[mcp4018 b_axis_pot]
scl_pin: PJ5
sda_pin: PJ6
wiper: 0.50
scale: 0.773

[virtual_sdcard]
path: /home/pi/sdcard

[web_dwc2]
## optional - defaulting to Klipper
printer_name: woot
# optional - defaulting to 0.0.0.0
listen_adress: <YOUR PI IP>
# needed - use above 1024 as nonroot
listen_port: 4750
# optional defaulting to dwc2/web. Its a folder relative to your virtual sdcard.
web_path: dwc2/web

You'll need to modify it to use you're pi's IP address and you're printer's path (the first command we ran on this page)

Now we need to flash our board. There is no undo button for this. If you decide klipper isn't for you, you'll need to get a copy of your current firmware. You can probably snap an image of it using avrdude or you can find one online.

This is the point of no return. We flash klipper to your printer's motherboard.

sudo service klipper stop  
sudo avrdude -v -v -D -F -V -p atmega2560 -P <PATH TO YOUR PRINTER> -c stk500v2 -b 57600 -U flash:w:out/klipper.elf.hex
sudo service klipper start

You'll need to modify the command above to match the path of your printer. (The first command we ran on this page)