Trouble setting up PT100/MAX31865 temp sensor

Hi all, I’m trying to set up a PT100 temp sensor using a Fysetc MAX31865 stepstick on a Fysetc Spider V1.1 mainboard, but I am running into problems. I tried following the guide on the Fysetc Wiki (PT100_Stick Introduction - FYSETC WIKI) which appears to be an adaption of the instructions in the Voron documentation. It says to insert the following lines in the [extruder] section of the config file:

sensor_type: MAX31865
sensor_pin: PD11 # I pulg into Spider E4-MOT socket, cs pin is the sensor pin
spi_speed: 4000000
spi_software_sclk_pin: PE12
spi_software_mosi_pin: PE14
spi_software_miso_pin: PE13
rtd_nominal_r: 100
rtd_reference_r: 430
rtd_num_of_wires: 2

However when I do this, Klipper complains that the spi parameters are not valid in the [extruder] section. So, I set up a new temperature sensor like this:

[temperature_sensor ext_PT100]
sensor_type: MAX31865
sensor_pin: PD11
spi_speed: 4000000
spi_software_sclk_pin: PE12
spi_software_mosi_pin: PE14
spi_software_miso_pin: PE13
rtd_nominal_r: 100
rtd_reference_r: 430
rtd_num_of_wires: 2
rtd_use_50Hz_filter: True
min_temp: 0
max_temp: 300
gcode_id: C

And then I added the line “sensor_type: ext_PT100” to the [extruder] section, but now Klipper throws this error:

Unknown temperature sensor ‘ext_PT100’

And now I’m stuck, I don’t know what else to try. I’d really appreciate any pointers to help me solve this.

Many thanks, John

I use the same MAX board in one of my printers:

[extruder]
...
sensor_type: MAX31865
sensor_pin: P1.1
spi_speed: 4000000
spi_software_sclk_pin: P0.4
spi_software_mosi_pin: P1.17
spi_software_miso_pin: P0.5
rtd_nominal_r: 100
rtd_reference_r: 430
rtd_num_of_wires: 2
rtd_use_50Hz_filter: True
...

For the Spider it should be:

sensor_type: MAX31865
sensor_pin: PD11
spi_speed: 4000000
spi_software_sclk_pin: PE12
spi_software_mosi_pin: PE14
spi_software_miso_pin: PE13

Please attach your klippy.log file

Edit:
Also check the jumper settings for your E4 port

Thanks very much for the reply. I’ve attached 2 log files, the first shows the error I get when I configure the PT100 in a separate [temperature_sensor] section, and the 2nd log file show the result of putting the PT100 configuration into the [extruder] section.

I set my jumpers as per this image on the Fysetc wiki:
Jumpers

klippy.log (85.3 KB)
klippy1.log (288.4 KB)

I only went through the second log, but you have a mistake in your config from what I can see. You have the sensor_type configured incorrectly.

[extruder]
max_extrude_only_distance = 150.0
max_extrude_cross_section = 100
step_pin = PD5
dir_pin = !PD6
enable_pin = !PD4
heater_pin = PB15
sensor_type = new_hotend
sensor_pin = PD11
spi_speed = 4000000
spi_software_sclk_pin = PE12
spi_software_mosi_pin = PE14
spi_software_miso_pin = PE13
rtd_nominal_r = 100
rtd_reference_r = 430
rtd_num_of_wires = 2
rtd_use_50hz_filter = True
microsteps = 16
nozzle_diameter = 0.600
filament_diameter = 1.750
min_temp = 0
max_temp = 400
min_extrude_temp = 120
smooth_time = 1.0
rotation_distance = 4.713
pressure_advance = 0.065
pid_kp = 39.152
pid_ki = 2.486
pid_kd = 154.163
control = pid

Doh! Thanks very much for that, that was the problem. I looked at it a hundred times and missed that every time.