Commit Graph

5123 Commits

Author SHA1 Message Date
Kevin O'Connor 0ccf5f8e47 github: Temporarily disable close_reviewer_needed automation
Temporarily disable the closing of PRs marked as "reviewer needed".

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-12-05 17:57:11 -05:00
Will Puckett fc102edc24
hard_pwm: Add pin defs for STM32F070 and STM32F072 (#6409)
Define hard_pwm pins for STM32F070 and STM32F072, and update KConfig accordingly. 

Signed-off-by: Will Puckett <willpuckett@gmail.com>
2023-12-05 17:44:51 -05:00
Kevin O'Connor 05d5451347 docs: Improve max_accel documentation in Config_Reference.md
Note that the max_accel parameter is the actual acceleration used in
most movements.

Note that the accel/velocity limits can be changed using the
SET_VELOCITY_LIMIT command.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-12-05 17:42:53 -05:00
Thijs Triemstra 795ce490a0
doc: updates to Installation.md (#6398)
omit rpi device version nrs

rpi2 or newer

Signed-off-by: Thijs Triemstra <info@collab.nl>
2023-12-03 21:10:59 -05:00
CODeRUS 38221df83a
avr: enable small code size options for 328 and 328p (#6411)
Signed-off-by: Andrei Kozhevnikov <coderusinbox@gmail.com>
2023-11-29 11:31:49 -05:00
Kevin O'Connor 03f69cd81a tmc: Query latest value during _init_registers()
The set_register() code may block, and it therefore may be possible
that the loop in _init_registers() could occur in parallel with other
updates.  That could result in a "OrderedDict mutated during
iteration" error.

Avoid the error by querying the latest value during each iteration of
the loop.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-28 21:24:41 -05:00
Andrei Ignat ea2f6bc0f5
exclude_object: Don't use gcmd.respond_error() (#6407)
gcmd.respond_error() has been deprecated: 61524542d2

Signed-off-by: Andrei Ignat <andrei@ignat.se>
2023-11-22 11:53:38 -05:00
Kevin O'Connor bb4711c5d3 tmc5160: Increase maximum current error check
It's possible to build and configure tmc5160 drivers with external
mosfets that support more than 3 amps.  The actual maximum for tmc5160
drivers is dependent on how the board is wired and the mosfets used.
Increase the error check to 10 amps.  This error checking is primarily
intended to catch "obvious misconfigurations" (eg, specifying
milli-amps instead of amps), and the new value of 10 amps should
suffice for this task.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-20 18:15:46 -05:00
Kevin O'Connor 187cc2f1b8 configfile: Improve support for python3.12
It seems python3.12 has removed support for readfp() - use read_file()
instead.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-16 22:28:40 -05:00
vaxxi 3c8f202dfa
bmp280: Add support for BMP180 sensor (#6370)
Extends the BMxx80 category with support for the older BMP180 sensor, providing temperature and humidity output.

Signed-off-by: VAXXi Popescu <github@vaxxi.net>
2023-11-16 22:27:44 -05:00
docgalaxyblock 83df4a8627 stm32: enable 64KiB bootloader offset for all F4
Signed-off-by: Joshua Schlicker <potter-91@web.de>
2023-11-16 22:09:59 -05:00
Kevin O'Connor 29b7550ce5 pwm_tool: Add support for high-speed PWM pin updates
The output_pin module is only capable of updating an output pin at
most once every 100ms.  Add a new pwm_tool module that is capable of
queuing updates in the micro-controller and thus allowing for much
higher update rates.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-16 22:07:15 -05:00
Kevin O'Connor 48a05eaa54 stepcompress: Add support for queuing messages that consume move queue space
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-16 22:07:15 -05:00
Thijs Triemstra 4688c21c54
klippy: Replace deprecated logger.warn with logger.warning (#6385)
Replace deprecated logger.warn with logger.warning

logger.warn will be removed in Python 3.13

Signed-off-by: Thijs Triemstra <info@collab.nl>
2023-11-16 22:06:13 -05:00
Herb McNew 3f8f30d612
config: Update printer-sovol-sv06-plus-2023.cfg (#6401)
In testing with a user on Discord we discovered the sensorless homing thresholds were out of line with what Sovol ships with Marlin. This aligns with their settings.

Signed-off-by: Herb McNew <herb.mcnew@gmail.com>
2023-11-16 21:57:45 -05:00
Herb McNew 74473322e5
config: Add Sovol SV06 Plus (#6397)
New configuration for the Sovol SV06 Plus
Initial pass at adding a printer configuration for the Sovol SV06
Plus based on the existing Sovol SV06 config. Updated for the larger
build volume, added filament runout sensor, and removed any references
to the LCD screen since the stock screen doesn't work with Klipper.

Signed-off-by: Herb McNew <herb.mcnew@gmail.com>
2023-11-14 13:15:46 -05:00
Kevin O'Connor 0d67d9c45d docs: Note the release of v0.12.0
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-10 18:36:19 -05:00
Kevin O'Connor 0acf3035e8 docs: Update Features.md
Note additional features that have been added recently.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-10 18:35:59 -05:00
Pedro Lamas 9e765daeed bed_screws: Reset on move error
Signed-off-by: Pedro Lamas <pedrolamas@gmail.com>
2023-11-02 13:08:53 -04:00
Wayne Manion 233f50424c
config: Update generic-bigtreetech-skr-pico-v1.0.cfg (#6376)
Add RP2040 internal temperature sensor

Signed-off-by: Wayne Manion <treowayne@gmail.com>
2023-11-02 13:03:01 -04:00
Kevin O'Connor 64a97431b5 docs: Update Contact.md to note other common ways to obtain Klipper log file
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-01 19:04:13 -04:00
Kevin O'Connor 03982f2c7e docs: Update the Contact document
Try to make it more clear that Discord is not Discourse, as the two
similarly sounding services are often confused by users unfamiliar
with them.

The Klipper Discourse and Klipper Discord are available for many
topics related to Klipper - reword some sections to make their use
more open.

Avoid referring to the Klipper github repo in this Contact document as
we no longer use Klipper github issues at all.

Remove the table of contents as it is largely redundant for the
document.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-11-01 19:04:13 -04:00
Kevin O'Connor bee7ec720b config: Add new generic-bigtreetech-octopus-pro-v1.1.cfg config
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-30 14:29:43 -04:00
Kevin O'Connor 9b15293547 config: Clarify stepper enable comment in Octopus boards
Make sure the stepper enable_pin comment shows an inverted pin.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-30 14:29:43 -04:00
Kevin O'Connor a629b87ae0 config: Split generic-bigtreetech-octopus.cfg into separate files
Use two different files for the Octopus Pro and Octopus (non-Pro).
The configs are the same in practice, but the difference in version
and naming can lead to confusion.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-30 14:29:43 -04:00
Kevin O'Connor f7567a0db9 Revert "toolhead: Use dict for step generation flush times. (#6303)"
This reverts commit 6749985302.

A defect was found in the above commit (the input shaper code calls
note_step_generateion_scan_time() for many steppers, so the
input_shaper class can't be used as the index).

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-21 15:46:08 -04:00
Viesturs Zariņš 6749985302
toolhead: Use dict for step generation flush times. (#6303)
Makes the API to extruder and input shaper more robust, avoiding the need to track the old delay.

Signed-off-by: Viesturs Zariņš <viesturz@gmail.com>
2023-10-19 13:28:16 -04:00
Tom Dunn 0c521b601d Config_checks: Missing ! in pin inversion example in Verify endstops
In the "Verify endstops" section there is an example of adding an
exclamation point to the pin definition to invert its logic.  I
believe the intention in the example is to keep the hardware pull-up
^ and follow it with ! to invert the pin logic, but the ! is missing.

Signed-off-by: Tom Dunn <thomas.dunn@gmail.com>
2023-10-19 13:13:57 -04:00
Aaron B. Haun 593486fadc docs: Fix a typo in serial bootloader entry docs
Signed-off-by: Aaron B. Haun <aaron@haun.guru>
2023-10-19 13:10:05 -04:00
Luke V dd01e99c59
atsam: Add support for CAN on atsame70 (#6366)
Signed-off-by: Luke Vuksta <wulfstawulfsta@gmail.com>
2023-10-19 13:01:59 -04:00
Alex Maclean b1f597c550
atsam: Remove USB endpoint header (#6365)
The atsam USB hardware only requires that the ACM endpoint be endpoint
3.  As of commit 11828387 the atsam chips can therefore use the
default USB endpoints.

This will allow CAN bridge support for the SAME70 to function
(upstream host driver has hardcoded endpoints).

Signed-off-by: Alex Maclean <monkeh@monkeh.net>
2023-10-12 21:02:26 -04:00
Aaron B. Haun ecc9bbf52a docs: add info about requesting bootloaders
Signed-off-by: Aaron B. Haun <aaron@haun.guru>
2023-10-12 20:53:31 -04:00
Kevin O'Connor 5edc7fee7e config: Fix trailing space in printer-creality-ender5-2019.cfg
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-09 13:34:58 -04:00
ghostoverflow256 7eabf02f5b
config: Update printer-creality-ender5-2019.cfg to add instructions for silent boards (#6326)
Recently tested on my ender 5 pro that came from creality with a v1.1.5 board. Works. Tested all endstops, motors, and heaters. 

Signed-off-by: Jake Aronleigh <jakestar98@outlook.com>
2023-10-09 13:28:49 -04:00
Kevin O'Connor 83ef0e135e stm32: Make sure to limit tx during usbfs startup
Wait for two tx packets before startup, and make sure one of those
packets is acked before sending a third tx packet.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-05 00:47:42 -04:00
Kevin O'Connor 447125faae serialqueue: Eventually time out if unable to write CANbus messages
Klipper logs an error on a failed CANbus write.  Unfortunately, if the
bus becomes permanently disabled (eg, due to a user removing power to
devices on the CANbus) then it can result in the logs filling with
error messages.

Permanently disable the low-level processing of messages if CANbus
writes continually fail for at least 10 seconds.  This avoids filling
the log with redundant messages.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-04 22:42:14 -04:00
Kevin O'Connor 043f18da26 stm32: Fix usbfs spurious USB packet transmit on startup
Commit cd8d57c2 added USB double buffering mode on transmits.
However, when enabling double buffering mode, the hardware seems to
always send at least two packets.  Spurious transmissions could cause
the Linux gs_usb driver to get confused, which could lead to the can0
device becoming unavailable on restarts.  Fix by waiting for two USB
packets to be available before enabling the endpoint.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-04 22:11:22 -04:00
Kevin O'Connor 615db729e7 stm32: Only enable one direction on usbfs double buffered end points
The bulk out endpoint should not be enabled in tx mode, and the bulk
in endpoint should not be enabled in rx mode.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-04 18:49:46 -04:00
Kevin O'Connor 6adff3954b usb_canbus: Prioritize local response sending over new host messages
Prioritize sending responses back to the host over transmitting new
messages from the host.  Otherwise, the gs_usb host usb
acknowledgments could saturate the usb bandwidth for extended periods.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:29:17 -04:00
Kevin O'Connor 78ae83c314 usb_canbus: Add a local queue for USB messages received from host
Read USB messages arriving from the host into a queue.  This makes it
less likely that USB "bulk out" packets will be NAK'ed on the USB bus,
which improves USB bus utilization.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:29:17 -04:00
Kevin O'Connor 5b204866c5 usb_canbus: Rename UsbCan.queue to UsbCan.canhw_queue
Rename the internal variable names.  This is in preparation for
support of a USB message queue.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:29:17 -04:00
Kevin O'Connor 472fd32cab rp2040: Add support for double buffering on USB bulk tx packets
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:28:13 -04:00
Kevin O'Connor 90427fe30e rp2040: Add support for double buffering on USB bulk rx packets
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:28:13 -04:00
Kevin O'Connor bdeec0f56d rp2040: Open code usb_read_packet() and usb_write_packet() in callers
Copy the code for these two functions to their respective callers.
This is in preparation for double buffer support.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:28:13 -04:00
Kevin O'Connor 83eecae028 rp2040: Add helper functions to usbserial.c
Add helper functions for manipulating the buffer memory and packet
control registers.  This is in preparation for double buffer support.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:28:13 -04:00
Kevin O'Connor cd8d57c2c6 stm32: Add usbfs double buffer support for bulk tx messages
Implement the usbfs fast buffer switching mechanism on the "bulk in"
endpoint.  This can improve the overall USB throughput and bus
utilization.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:26:46 -04:00
Kevin O'Connor b1361d9e5b stm32: Add usbfs double buffer support for bulk rx messages
Implement the usbfs fast buffer switching mechanism on the "bulk out"
endpoint.  This can improve the overall USB throughput and bus
utilization.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:26:46 -04:00
Kevin O'Connor 01ac5334e9 stm32: Update usbfs to support setting both buffers for each endpoint
The usbfs device supports two buffers for each endpoint - typically
one for rx and one for tx.  Add support for explicit handling of both
buffers.  This is in preparation for improved "double buffering"
support.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:26:46 -04:00
Kevin O'Connor 1e3ace2170 stm32: Improve usbfs epr register handling
Replace the set_stat_x_bits() functions with a single calc_epr_bits()
function.  This new function supports setting bits other than the stat
field in the epr register.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:26:46 -04:00
Kevin O'Connor aa726cb7cb lib: Update to latest can2040 code
Add support for can2040_stop()
Add data_state_go_error() helper
Add new can2040_get_statistics() API function
Call report_note_discarding() after setting MS_DISCARD state
Convert report_is_rx_eof_pending() to report_is_not_in_tx()

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-10-03 23:24:18 -04:00