aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras
Commit message (Collapse)AuthorAgeFilesLines
* heaters: Make sure set_temp() command wakes up the idle_timeoutKevin O'Connor2021-03-053-8/+12
| | | | | | | | | Introduce a heaters.set_temperature() command and call that from commands that set a heater temperature. This new function calls toolhead.register_lookahead_callback() so that the idle_timeout gets notification that activity has occurred. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* st7920: Better support for emulated ST7920 displays (#3979)teeminus2021-03-012-44/+126
| | | | | Added new ST7920E display driver which is better suited for displays with emulated ST7920 Signed-off-by: Christian Kehe <teeminus@posteo.net>
* fan: Minor updates to tachometer handlingKevin O'Connor2021-03-012-5/+3
| | | | | | | | | | | Add new fields to Command_Templates.md. Remove unused self.rpm variable. Use an explicit get_frequency() method in keeping with Klipper's convention of not "peeking into member variables". Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* fan: Add tachometer supportAdrian Keet2021-03-012-1/+113
| | | | | | | | | | | | | | This adds new config options for fans: 'tachometer_pin' to specify the GPIO pin, and 'tachometer_ppr' (default 2) to specify the number of signal pulses per revolution. The rpm is also exposed by get_status for command templates and the API server. For fast fans (at least 10000 RPM), the polling interval can be shortened using the 'tachometer_poll_interval' option. There is a new mcu object for a generic edge counter, which repeatedly polls a GPIO pin and periodically reports the count to the host. Signed-off-by: Adrian Keet <arkeet@gmail.com>
* tmc: Fix order of init during sensorless homingKevin O'Connor2021-02-282-4/+11
| | | | | | | | | | | With commit 53b10d3a the setup of sensorless homing could occur before the driver was enabled which would cause the reinitialization of the driver settings to undo the sensorless homing setup. Use set_field() when setting the sensorless homing registers so that it wont conflict with a driver init. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: No need to delay init on a stepper enableKevin O'Connor2021-02-281-3/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Allow more retries on a TMC UART read error during background checksKevin O'Connor2021-02-281-1/+10
| | | | | | | Allow three retries if we can't contact the TMC driver at all when it is in UART mode. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc_uart: Minor change - make the baud rate setting more clearKevin O'Connor2021-02-271-1/+3
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Add support for periodic checking of driver statusKevin O'Connor2021-02-272-2/+78
| | | | | | | | Check the status of all Trinamic stepper motor drivers once a second. If the driver reports an error then invoke a shutdown. Also log any serious warnings. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Reinitialize on every driver enableKevin O'Connor2021-02-271-32/+36
| | | | | | | | | | | | | Send the full TMC stepper motor driver initialization sequence every time the driver is enabled. Don't raise an error on startup if unable to contact a tmc2208/tmc2209 driver. If the driver is still unavailable when it is enabled then a shutdown will be issued. This allows users to troubleshoot (and possibly bring up communication to the driver) prior to enabling the driver. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2660: Fix tmc register readingKevin O'Connor2021-02-271-30/+35
| | | | | | | | | The tmc2660 appears to send responses as soon as the clk starts toggling. That means the 20 bit response is at the top of the 24bit sent message. Also, this implies that RDSEL must already have the correct value in the prior message. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2660: Use common warning/error flag names and descriptionsKevin O'Connor2021-02-271-43/+30
| | | | | | | | Where the tmc2660 flags match other drivers, use lowercase so that the same monitoring code can be used for all the tmc drivers. Also, use the same field formatters where applicable. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc5160: Merge field formatters into tmc2130.pyKevin O'Connor2021-02-272-5/+1
| | | | | | | | The tmc5160 field formatters were mostly duplicates of the tmc2130 - add the "reset" field to tmc2130.py so both drivers have similar reporting. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Always report values after a SET_TMC_CURRENT commandKevin O'Connor2021-02-271-14/+15
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Move SET_TMC_CURRENT command to TMCCommandHelper()Kevin O'Connor2021-02-276-68/+37
| | | | | | | Refactor the tmc driver implementations so that there is a single implementation of the SET_TMC_CURRENT command. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2660: Add set_current()/get_current() helpers to TMC2660CurrentHelperKevin O'Connor2021-02-271-9/+15
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc5160: Add set_current()/get_current() helpers to TMC5160CurrentHelperKevin O'Connor2021-02-271-14/+18
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2130: Add set_current()/get_current() helper functions to TMCCurrentHelperKevin O'Connor2021-02-271-16/+20
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* virtual_sdcard: exact filename match before case insensitive oneAndre LeBlanc2021-02-261-1/+3
| | | | | | | | | currently, if there are 2 files on the virtual sd card whose names differ only in case (eg. MyFile.gcode vs myfile.gcode) the actual file that gets loaded is at best unpredictable. this patch checks for an exact match before attempting a case-insensitive one. Signed-off-by: Andre LeBlanc <andrepleblanc@gmail.com>
* tmc2130: Add spi daisy chain supportMarco D'Alessio2021-02-262-16/+61
| | | | | | | | This patch adds the ability to daisy-chain multiple tmc2130 and tmc5160 drivers. Signed-off-by: Marco D'Alessio <marco@wrecklab.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Improve error message on missing microsteps configKevin O'Connor2021-02-231-1/+2
| | | | | | | If microsteps is missing, warn about it in the stepper config section, not the tmc config section. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* Revert "bme280: Rename sensor_type from BME280 to bme280"Kevin O'Connor2021-02-201-1/+1
| | | | | | | | | This reverts commit ac61f8b72603e9d08832250026e48093dd66aec4. Many temperature sensors are capitalized, so don't make this chaneg to the bme280. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* menu: Default menu should check extruders have heaters (#3969)Janar Sööt2021-02-201-2/+2
| | | | | | For the hotend targets check also available heaters. It'll solve crash when using shared heaters. Signed-off-by: Janar Sööt <janar.soot@gmail.com>
* menu: redesigned name scroller & menu rendering (#3837)Janar Sööt2021-02-202-93/+95
| | | Signed-off-by: Janar Sööt <janar.soot@gmail.com>
* bme280: Rename sensor_type from BME280 to bme280Kevin O'Connor2021-02-201-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* temperature_host: Rename "path" config to "sensor_path"Kevin O'Connor2021-02-201-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* temperature_host: Improve backwards compatibility checkKevin O'Connor2021-02-191-2/+5
| | | | | | Don't register two names for the same instance of the sensor. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* temperature_host: Rename rpi_temperature and add support for custom pathsEvgenii2021-02-192-13/+16
| | | | | Signed-off-by: Evgenii Shavrin <shavrin0591@gmail.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* probe: Add last_z_result to get the latest z result in an Macro (#3835)Christian S2021-02-181-1/+4
| | | Signed-off-by: Christian Schnellrieder <schnello.android@gmail.com>
* idle_timeout: Add help to SET_IDLE_TIMEOUT (#3945)Arjan Mels2021-02-181-1/+3
| | | Signed-off-by: Arjan Mels <github@mels.email>
* ds18b20: new module for 1-wire temperature sensor (#3462)Alan Lord2021-02-022-1/+79
| | | | | | | | | Initial commit of code to support 1-wire (Dallas) sensors such as the DS18B20. Requires Linux kernel drivers to create a file in /sysfs which is read by this module, and temperature typically returned to a temperature_fan. Signed-off-by: Alan Lord <alanslists@gmail.com> Signed-off-by: Josh Headapohl <joshhead@gmail.com>
* temperature_fan: Add MAX_SPEED and MIN_SPEED to SET_TEMPERATURE_FAN_TARGET ↵Lane Roberts2021-02-021-6/+34
| | | | | | | command (#3873) Allows setting min_speed and max_speed at runtime, rather than updating the config and restarting. Signed-off-by Lane Roberts <nolatari@vandarin.net>
* resonance_tester: Increase test max_accel to 10K and max_freq to 133 HzDmitry Butyugin2021-02-021-2/+3
| | | | Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
* resonance_tester: Disable input shaping for resonance testingDmitry Butyugin2021-02-021-0/+11
| | | | Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
* adxl345: Add accelerometer chip name to the raw data file nameDmitry Butyugin2021-02-021-6/+9
| | | | Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
* htu21d: Implement support for min_temp/max_temp checksKevin O'Connor2021-02-011-2/+8
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* bme280: Implement support for min_temp/max_temp checksKevin O'Connor2021-02-011-1/+7
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* spi_temperature: Improve handling of min_temp/max_temp overflowsKevin O'Connor2021-02-011-3/+3
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* lm75: Implement support for min_temp/max_temp checksKevin O'Connor2021-02-011-2/+8
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* lm75: Use getfloat() for reading the lm75_report_time parameterKevin O'Connor2021-02-011-10/+4
| | | | | | Reported by @theopensourcer. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* hd44780: Add hd44780 protocol init configThomas Kroll2021-01-311-1/+6
| | | | | | | LDO OLED needs a different init string. Fixes: #3722 Signed-off-by: Thomas Kroll <t.kroll@outlook.com>
* htu21d: Fix time reporting of temperature measurementsKevin O'Connor2021-01-241-1/+2
| | | | | | The temperature callback takes a "print time" not a "system time". Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* rpi_temperature: Fix time reporting of temperature measurementsKevin O'Connor2021-01-241-1/+2
| | | | | | The temperature callback takes a "print time" not a "system time". Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* temperature_mcu: Improve handling when in debug output modeKevin O'Connor2021-01-241-0/+2
| | | | | | | Call mcu_adc.setup_minmax() even in debug output mode so that the debugging output contains a more accurate configuration. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* bme280: Disable bme280 when using debug outputKevin O'Connor2021-01-241-0/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* rpi_temperature: Fix missing get_report_time_delta() callbackKevin O'Connor2021-01-241-0/+3
| | | | | | Reported by @ronald5555. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* rpi_temperature: Disable rpi_temperature when using debug outputKevin O'Connor2021-01-241-0/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* rpi_temperature: Minor formatting changesKevin O'Connor2021-01-241-19/+10
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* temperature_mcu: Disable the temperature_mcu when using debug outputKevin O'Connor2021-01-241-0/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* menu: Update menu.cfg sd_card menu enable condition (#3826)Chip2021-01-241-5/+35
| | | | | Change SD card enable condition and add Cancel printing option. Signed-off-by: John Smith <login721@gmail.com>