From df5ad5bfa6c82ddb293593711d20b22cf3629792 Mon Sep 17 00:00:00 2001 From: Minims Date: Mon, 24 Jun 2024 19:17:08 +0200 Subject: [PATCH] Add FYSETC Nozzle-Input-Shaper accelerometer support (#603) --- .../accelerometers/adxl345_Fystec_NIS.cfg | 26 +++++++++++++++++++ user_templates/printer.cfg | 3 ++- 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 config/hardware/accelerometers/adxl345_Fystec_NIS.cfg diff --git a/config/hardware/accelerometers/adxl345_Fystec_NIS.cfg b/config/hardware/accelerometers/adxl345_Fystec_NIS.cfg new file mode 100644 index 000000000..a91b65471 --- /dev/null +++ b/config/hardware/accelerometers/adxl345_Fystec_NIS.cfg @@ -0,0 +1,26 @@ +[include generics/adxl345_software_spi.cfg] + +# https://github.com/FYSETC/Nozzle-Input-Shaper +# stm32f042 + +# You need to override the following to be able to set the proper serial in your overrides.cfg file +[mcu adxl] +serial: /dev/serial/by-id/xxx + +[adxl345] +cs_pin: NIS:PA4 +spi_software_sclk_pin: adxl:PA5 +spi_software_mosi_pin: adxl:PA7 +spi_software_miso_pin: adxl:PA6 +axes_map: x,y,z + +[resonance_tester] +accel_chip: adxl345 +probe_points: + -1,-1,-1 + +# Include the IS calibration macros to unlock them when +# an accelerometer is installed on the machine +[include ../../../macros/helpers/resonance_override.cfg] +[include ../../../scripts/K-ShakeTune/K-SnT_*.cfg] + diff --git a/user_templates/printer.cfg b/user_templates/printer.cfg index 4f93ead2c..ae4c1ca3f 100644 --- a/user_templates/printer.cfg +++ b/user_templates/printer.cfg @@ -191,6 +191,7 @@ # [include config/hardware/accelerometers/adxl345_usb.cfg] # For KUBSA, ... # [include config/hardware/accelerometers/adxl345_usb_rampon.cfg] # For KUBSA with Rampon firmware, ... # [include config/hardware/accelerometers/adxl345_usb_rp2040_spi1.cfg] # For Fysetc PortableInputShaper, ... +# [include config/hardware/accelerometers/adxl345_Fystec_NIS.cfg] # For USB Nozzle Input Shapers # [include config/hardware/accelerometers/adxl345_skr.cfg] # For ADXL plugged in SKRv1.4 (not a conventional way) # [include config/hardware/accelerometers/adxl345_sb2040.cfg] # For ADXL plugged in Mellow Fly-SB2040 boards @@ -200,7 +201,7 @@ # [include config/hardware/accelerometers/adxl345_Fysetc_SB_Can_TH.cfg] # For ADXL plugged in Fysetc SB Can TH boards # [include config/hardware/accelerometers/adxl345_nitehawk_sb.cfg] # For built in ADXL sensor on the Nitehawk SB board -# [include config/hardware/accelerometers/lis2dw_usb_rp2040_spi1.cfg] # For BTT S2DW V1.0, ... +# [include config/hardware/accelerometers/lis2dw_usb_rp2040_spi1.cfg] # For BTT S2DW V1.0, ... # [include config/hardware/accelerometers/beacon_accelerometer.cfg] # For Beacon Rev H make sure Beacon. Do not forget to include the beacon_virtual_probe in the PROBE section! # ----------------------------------------------------------------------------------------