Commit Graph

3226 Commits

Author SHA1 Message Date
Kevin O'Connor d3a7d992aa display: Remove unused self.lcd_type variable
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-21 12:12:29 -04:00
kakou-fr 961f68629a
manual_stepper: Fix sensorless endstop for manual_stepper (#2621)
Signed-off-by: Jeremy Briffaut <kakou@kakou.org>
2020-03-20 21:11:36 -04:00
Chester 35d951dabf
config: Add BigTreeTech GTR board generic config file (#2626)
This config was not yet available - I have updated all the pin defines, starting with the BTT SKR board which is the most similar board + tested it on my printer which is currently working with the TMC5160 drivers using software SPI. I have not tested it with other drivers etc but the config should work for them. 

Signed-off-by: Chester Lowrey <hilo90mhz@gmail.com>
2020-03-20 21:02:24 -04:00
Kevin O'Connor acd165cbea stepcompress: Implement a step+dir+step filter
Some stepper motor drivers do not respond well to rapid "step +
direction change + step" events.  In particular, it is believed this
can cause "over current" events on the tmc2208 drivers when they are
in "stealthchop" mode.  Detect these events and remove them from the
generated step times.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-13 21:53:48 -04:00
Kevin O'Connor d86bf0b927 stepcompress: Move code around in stepcompress.c
Just code movement - no code changes.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-13 21:53:48 -04:00
Kevin O'Connor 5e39d346ed display: Use the active extruder in the default 16x4 screen layout
Change the default layout to show the active extruder (not always the
first extruder).

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-13 21:50:38 -04:00
Kevin O'Connor f2dd4b001d display: Use a separate display group for 16x4 multiple extruders
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-13 21:46:36 -04:00
Garth Snyder 0ba83c5b04
docs: clarify behavior of M204 with only one of P or T (#2564)
Signed-off-by: Garth Snyder <garth@garthsnyder.com>
2020-03-11 13:03:48 -04:00
Kevin O'Connor 986e9c884a display: Fix percent progress rendering on 16x4 multi-extruder layout
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-08 17:55:53 -04:00
Kevin O'Connor 3850b3d27a docs: Fix date of menu change in Config_Changes.md
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-08 17:42:22 -04:00
Arksine aa7d24b0af display: add support for multiple displays
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2020-03-08 17:38:24 -04:00
Kevin O'Connor 6d5ce309a5 menu: Remove the "test" menu from the default menu
It is likely only developers will be interested in testing the menu
system, so no need to have it in the default menu.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-08 17:38:24 -04:00
Kevin O'Connor d39c4fe628 menu: Disable support for "deck" and "card" menu items
Disable support for customizing the main lcd display content via the
menu system.  Advise users to use the new display_data config sections
as a replacement.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-08 17:38:24 -04:00
Kevin O'Connor 2cf03ffa23 display: Replace hard-coded display with new config based display
Introduce a new config based system for specifying the on-screen
contents of an lcd screen.  The default screen configuration (found in
klippy/extras/display/display.cfg) is the same as the previous
hard-coded display, so this should not change behavior for existing
users.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-08 17:38:21 -04:00
Kevin O'Connor 5acc181624 display_status: Separate out M73 and M117 handling to new module
Move M73 and M117 handling from display.py to a new display_status.py
module.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-08 17:36:14 -04:00
Willy Hsiao 7fb7f0d331
config: Pin logic on MKS SGEN L generic config (#2606)
Correct TMC2130 diag1_pin logic - the diag1_pin logic should be inverted and pulled up.

Use pullup for endstops - pullups should be used here.

Signed-off-by: Wen-Jeng Hsiao <isuperwilly@gmail.com>
2020-03-08 14:36:09 -04:00
Kevin O'Connor b3cfe55b39 clocksync: Remove no longer used get_adjusted_freq() function
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-06 16:35:02 -05:00
Kevin O'Connor 62fcc5a56f mcu: Calculate homing rest_ticks via standard print_time_to_clock() call
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-06 16:33:54 -05:00
Kevin O'Connor a61d483e21 tmc_uart: Use nominal mcu frequency in baud calculation
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-06 16:29:18 -05:00
Kevin O'Connor e872290c47 Revert "itersolve: Implement a step+dir+step filter"
This reverts commit c9cb462f90.

The step flushing for this commit was not complete.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-05 18:37:02 -05:00
Kevin O'Connor a074af7c87 adc_temperature: Add builtin definition for PT1000 sensors
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-05 11:46:01 -05:00
Kevin O'Connor 8d10379ad8 config: Move BME description within example-extras.cfg
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-05 11:41:38 -05:00
clearchris f87e29c775 armcm_boot: Additional code for broken bootloaders
Explicitly disable the SysTick interrupt and explicitly set the stack
pointer, as some bootloaders aren't handling this correctly.

Signed-off-by: Chris Lombardi <clearchris@hotmail.com>
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:50:56 -05:00
Kevin O'Connor 79e2376993 stm32: Add support for a bootloader on stm32f0
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:50:56 -05:00
Kevin O'Connor c9cb462f90 itersolve: Implement a step+dir+step filter
Some stepper motor drivers do not respond well to rapid "step +
direction change + step" events.  In particular, it is believed this
can cause "over current" events on the tmc2208 drivers when they are
in "stealthchop" mode.  Detect these events and remove them from the
generated step times.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:43:47 -05:00
Kevin O'Connor 8f8c1e2c58 itersolve: Reset bounds search on a direction change
If the stepper changes direction then the average velocity since the
last step pulse isn't a good indicator of the next step pulse.
Instead, reset the bounds checking to use a low starting guess.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:43:47 -05:00
Kevin O'Connor 271e412ae6 itersolve: Simplify main itersolve_gen_steps_range() loop
Reorder the loop to try and make the code flow a little simpler.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:43:47 -05:00
Kevin O'Connor bc6c3ba92f stepcompress: Remove "queue append" abstraction
The queue_append system predates the iterative solver - it was useful
when many different kinematic functions directly added steps to the
step compression queues.  With the iterative solver being the only
source of step generation, it is simpler to directly add steps from
the iterative solver code.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:43:47 -05:00
Kevin O'Connor d6c2e24f4c tmc5160: Support setting GLOBALSCALER to fine tune current selection
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 19:40:32 -05:00
Kevin O'Connor 121249c999 stm32: Revert "stm32: performance improvement for spi on stm32f0"
This reverts commit a2c309a2b0.

The above commit is causing crashes on the stm32f103xb chip when spi
is in use.  It's unclear what the cause of the regression is, but the
optimization isn't required so revert it until the root cause can be
determined.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 18:33:34 -05:00
Kevin O'Connor e9e0f59204 stepper: Add some comments on s->position tracking
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-04 14:30:41 -05:00
Kevin O'Connor 63ba7d231e docs: Minor updates to Code_Overview.md
Minor indentation change.  Update for change to stepcompress_append().

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-02 21:54:22 -05:00
David Smith c0f72a2c38
safe_z_home: Support note_z_not_homed() in kinematics (#2500)
Signed-off-by: David Smith <davidosmith@gmail.com>
2020-03-01 23:00:41 -05:00
kakou-fr 7a3cbc1e23
config: Example for MMU2S DIY (#2566)
Configuration file for MMU2S DIY

Signed-off-by: Jeremy Briffaut <kakou@kakou.org>
2020-03-01 22:08:37 -05:00
Denis Ignatenko f84542cd20
hall_filament_width_sensor: Added virtual runout sensor (#2535)
Signed-off-by: Denis Ignatenko deniss979@gmail.com
2020-03-01 22:05:12 -05:00
Kevin O'Connor 26523d77ba docs: Minor wording change to Endstop_Phase.md
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-03-01 11:40:13 -05:00
Kevin O'Connor 31b2c3ea7a stm32: Fix broken clock setup on stm32f1
Commit bd6c25c9 introduced a typo that caused the clock divisors to
not be set correctly on stm32f1.

Reported by @brianrjones69.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-29 13:14:12 -05:00
Kevin O'Connor 1c06ea8afe toolhead: Minor comment addition to calc_junction()
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-28 22:27:23 -05:00
Kevin O'Connor c197fdb03d heater: Fix misspelling of Celsius
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-27 11:31:51 -05:00
Angelol125 16e59511c3
config: Update printer-seemecnc-rostock-max-v2-2015.cfg (#2561)
Update printer-seemecnc-rostock-max-v2-2015.cfg to include the [display] and [board_pins] sections needed for Reprap 20x4 LCD display (#2561).

Signed-off-by: Angelo Lagis <angelo_lagis@hotmail.com>
2020-02-25 15:54:49 -05:00
FanDjango 16ecf15a91
bltouch: BTLOUCH V3.0/V3.1 Enable 5V/OD mode set commands (#2540)
Signed-off-by: Mike Stiemke <fandjango@gmx.de>
2020-02-23 22:32:07 -05:00
Kevin O'Connor 245917bf03 mcu: Introduce new lookup_query_command() command wrapper
Use new mcu.lookup_query_command() for all commands that query
information from the micro-controller.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-20 13:24:53 -05:00
Kevin O'Connor 332038ea01 serialhdl: Convert queries to use new notify message ack system
Convert standard queries to use the acknowledgments of the sent
command to determine if the response was received or not.  This also
controls command retransmissions (should the response have been lost).

The tmc_uart.py will continue to use the old mechanism as the tmcuart
responses are not sent synchronously with the query command.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-20 12:01:21 -05:00
Kevin O'Connor c6c360c4e1 serialqueue: Support notification of when a command is processed
Add ability for the host code to get a notification when the ack for a
command sent to the micro-controller is received.  This is in
preparation for improved detection of message loss between mcu and
host.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-20 12:01:21 -05:00
Kevin O'Connor 7b90830ae5 serialqueue: Remove unused serialqueue_encode_and_send() function
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-20 12:01:21 -05:00
Kevin O'Connor 98c7c7603e basecmd: No need for finalize_config command to send "config" response
The host code always issues a get_config command immediately after
finalize_config, so there is no need to send the two config response
messages.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-20 12:01:21 -05:00
Kevin O'Connor e03f75e758 tmc: Revert incorrect changes to TPWMTHRS setting
It's not valid to set the TPWMTHRS in a "klippy:connect" event handler
because the TMCVirtualPinHelper and TMCCommandHelper classes were
expecting that field to be set during the config reading phase.

Revert "tmc: Fix typo preventing stealthchop threshold from being set"
This reverts commit 7d76067ff9.

Revert "tmc: Query the stepper step_distance from the stepper object"
This reverts commit 67b2852249.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-20 11:41:35 -05:00
Kevin O'Connor 15f21be5ec manual_stepper: Support ignoring errors on STOP_ON_ENDSTOP
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-19 13:38:22 -05:00
Kevin O'Connor 804f95ebe4 homing: Don't raise a TimeoutError from home_wait()
Change home_wait() to return if the homing operation completed
succesfully or not.  This simplifies the callers.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-19 12:20:00 -05:00
Kevin O'Connor fbbbbc85cf homing: Replace notify callback with a completion
Update the endstop code to return its trigger completion object during
home_start().  Update the toolhead class to take a completion object
(instead of creating its own).  This reduces the number of
intermediate callbacks needed during a homing operation.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-19 11:45:44 -05:00