Configuration
This page covers the minimum printer.cfg needed to get an Ouroboros board
recognized by Klipper, ready for FOCI_SELFTEST and FOCI_SETUP on both
steppers. Ouroboros is a single STM32H723 MCU driving two stepper channels,
so it needs one [mcu] section and one [stepper_x]/[foci stepper_x]
pair per channel, not two separate MCUs.
Tuned gains, encoder alignment, and everything else that FOCI_AUTOTUNE
and FOCI_SETUP persist come from SAVE_CONFIG afterward. None of that
belongs in this initial config.
[mcu ouroboros]serial: /dev/serial/by-id/usb-foci_FOCI_Ouroboros_<serial>-if00Use the serial path you noted down in Installation.
Stepper X and Y
Section titled “Stepper X and Y”Each axis needs a standard Klipper [stepper_x]/[stepper_y] section (FOCI
reads microsteps, rotation_distance, and full_steps_per_rotation
straight from it) plus a [foci stepper_x]/[foci stepper_y] section that
turns on the TMC4671 driver for that channel. The foci section name must
match the linked stepper section’s name exactly; that’s the only thing that
links the two.
Channel 0 is STEP0/DIR0/ENA0, channel 1 is STEP1/DIR1/ENA1. Swap
which physical stepper you wire to which channel if X and Y come out
reversed, rather than trying to swap the pin names.
[stepper_x]step_pin: ouroboros:STEP0dir_pin: ouroboros:DIR0enable_pin: !ouroboros:ENA0microsteps: 16full_steps_per_rotation: 200rotation_distance: 40# A real endstop is still required by Klipper here. ^PA0 is the# endstop on your main MCU; alternatively, wire the switch to# Ouroboros' own STOP0 connector and use ouroboros:STOP0 instead. See# Sensorless Homing for FOCI's virtual_endstop option.endstop_pin: ^PA0
[foci stepper_x]run_current: 1.0encoder_ppr: 1000
[stepper_y]step_pin: ouroboros:STEP1dir_pin: ouroboros:DIR1enable_pin: !ouroboros:ENA1microsteps: 16full_steps_per_rotation: 200rotation_distance: 40# Same choice as X: ^PA1 (main MCU) or ouroboros:STOP1 (Ouroboros'# own connector).endstop_pin: ^PA1
[foci stepper_y]run_current: 1.0encoder_ppr: 1000Required fields
Section titled “Required fields”run_current and encoder_ppr are the only two fields [foci <stepper>]
requires.
run_currentis in amps. Start at 50-80% of your motor’s rated phase current from its datasheet, then raise it later ifFOCI_AUTOTUNEor your motion tests call for more headroom.encoder_ppris your encoder’s pulses-per-revolution rating, read off the encoder’s or motor’s datasheet or nameplate. It has nothing to do withmicrostepsorfull_steps_per_rotation. The common LDO-42STH48-2504B-EN1000 ships with a 1000 PPR encoder, henceencoder_ppr: 1000in the example above.
MCU and MOSFET temperature
Section titled “MCU and MOSFET temperature”Ouroboros exposes three analog channels as regular ADC pins: MCU_TEMP
(the STM32H723’s internal die temperature) and TH0/TH1 (one MOSFET
thermistor per channel). These work with Klipper’s stock
[temperature_sensor] support directly:
[temperature_sensor ouroboros_mcu]sensor_type: Generic 3950sensor_pin: ouroboros:MCU_TEMPmin_temp: 0max_temp: 120
[temperature_sensor ouroboros_tmc1_mosfet]sensor_type: Generic 3950sensor_pin: ouroboros:TH0min_temp: 0max_temp: 100
[temperature_sensor ouroboros_tmc2_mosfet]sensor_type: Generic 3950sensor_pin: ouroboros:TH1min_temp: 0max_temp: 100Restart Klipper, then continue with Bring-up.