Commit Graph

2860 Commits

Author SHA1 Message Date
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
Kevin O'Connor e3a5e2d271 reactor: Support multiple waiting timers on a single completion
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-19 10:49:56 -05:00
Kevin O'Connor 0e37f8c9b3 graph_extruder: Internal updates to graph calculation
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-18 12:38:45 -05:00
Kevin O'Connor 17f2b4e960 config: Fix minor typo in printer-lulzbot-taz6-2017.cfg
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-18 12:11:19 -05:00
Chris Lee 90500c331a config: Update TAZ6 configuration
Support probing the corner washers for the bed tilt using G29,
flesh out the rest of the configuration for the display, and add
support for the Aerostruder (commented out by default).

Signed-Off-By: Chris Lee <clee@mg8.org>
2020-02-18 12:10:09 -05:00
Kevin O'Connor 29c6c89327 probe: Don't allow errors to propagate from "gcode:command_error" event
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-18 11:47:04 -05:00
Matt Shirley 477b83469c
config: add mesh_min to printer-wanhao-duplicator-9-2018.cfg (#2525)
This is a small change I forgot to make when copying my config to this template.

Signed-off-by: Matt Shirley <mdshw5@gmail.com>
2020-02-17 20:59:08 -05:00
Christian S aa0a889b04
menu: Set speed for move actions (#2520)
Signed-off-by: Christian Schnellrieder <schnellrieder.cs@gmail.com>
2020-02-17 20:52:54 -05:00
Kevin O'Connor 01d985a739 docs: Recommend RPi 2 or later in Installation.md
Reported by @patrickkettner.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-17 20:49:32 -05:00
Kevin O'Connor 5304c4141c filament_switch_sensor: Query "printing" status instead of tracking it
It's simpler to query the "printing" status from the idle_timeout
module on an event than it is to track changes to the printing status.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-17 17:07:54 -05:00
Kevin O'Connor b6368173cf filament_switch_sensor: Collapse event disable flags
Introduce min_event_systime and rework the previous start_time,
last_event_time, and event_running flags into this one state tracking
variable.

This also makes a minor change to the behavior of the event_delay - it
is now calculated from the time the command completes execution
(instead of from when the event is first detected).  This may make a
difference if there is a long running g-code command occurring during
the detection event.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-17 16:57:27 -05:00
Kevin O'Connor 6716007420 filament_switch_sensor: Minor optimization to note_filament_present()
Avoid calling into the OS to obtain the system time if the filament
state hasn't changed.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-17 16:51:00 -05:00
Arksine 718da75910 filament_switch_sensor: Add a get_status() method
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2020-02-17 16:48:43 -05:00
Arksine 9415071482 filament_switch_sensor: Execute events using reactor callbacks
This removes the possibility of re-entry to callers of  note_filament_present().

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2020-02-17 16:48:43 -05:00
Arksine 740c0ae636 filament_switch_sensor: Replace BaseSensor with RunoutHelper
Rather than inherit from the BaseSensor, filament sensor implementatons
may instantiate the RunoutHelper and update the filament state via its
note_filament_present method.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2020-02-17 16:48:43 -05:00
FanDjango 086c131bbf bltouch: Add support for stow_on_each_sample
Signed-off-by: Mike Stiemke <fandjango@gmx.de>
2020-02-15 17:58:56 -05:00
Kevin O'Connor 1dd952ac65 probe: Add multi_probe_begin() / multi_probe_end() callbacks
Add support for notifying the low-level probing handlers that a
multiple probe sequence is occurring.  This is in preparation for the
bltouch code.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2020-02-15 17:52:44 -05:00