Commit Graph

5030 Commits

Author SHA1 Message Date
Adam f4a3dfa53f
docs: Update Measuring_Resonances.md (#6234)
Clarifying the ADXL345 on pi instructions. Previously, the instructions on installing the linux klipper instance were in a confusing place.

Signed-off-by: Adam Kramer <akramer@gmail.com>
2023-06-28 19:35:35 -04:00
Eric Callahan b9247810b9 virtual_sdcard: reset file position and size to integer zero
This resolves an issue with API server clients that always
expect these values be be integers.

Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-06-23 20:33:42 -04:00
Eric Callahan d32a833455 bed_mesh: fix fade regression
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-06-21 21:17:17 -04:00
Boris-Chengbiao Zhou 1374c701ab hc32f460: Disable JTAG/SWD on pins so they can be used for GPIO/serial
This change is required to sucessfully use PA13/PA14 for UART. Otherwise
they function as SWDIO/SWCLK.

Relevant excerpt from the reference manual (translated):
The initial state of PA13, PA14, PA15, PB3, and PB4 ports is that the
JTAG/SWD function is valid after reset. When configuring FSEL[5:0] to
select the function, you need to write 0 to the corresponding bit of the
register PSPCR to invalidate the JTAG/SWD function.

Signed-off-by: Boris-Chengbiao Zhou <bobo1239@web.de>
2023-06-20 12:05:32 -04:00
Boris-Chengbiao Zhou 623ebf2fb1 hc32f460: Use correct USART for PH2/PB10 pins
This fixes serial communication when selecting the PH2/PB10 pins.

The chip datasheet (not reference manual) assigns pins to one of two
communication function groups (`Func_Grp1/2`). Pins in group 1 have
access to USART1/2 while group 2 has access to USART3/4. PH2/PB10 belong
to group 2 so we now correctly use USART3 for them.

Signed-off-by: Boris-Chengbiao Zhou <bobo1239@web.de>
2023-06-20 12:05:32 -04:00
Kevin O'Connor 2ae3dd2f78 docs: Improve documentation of i2c_software_scl_pin/i2c_software_sda_pin
Reported by @rootiest

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-06-20 12:00:59 -04:00
Eric Callahan 9a77d8859b docs: note rri deprecation in config_changes
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-06-20 11:48:17 -04:00
Eric Callahan 8fe18f27a9 docs: update Bed Mesh documentation
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-06-20 11:48:17 -04:00
Eric Callahan 1ad4c0fd6e bed_mesh: improve zero reference offset
The relative_reference_index will now refer to a coordinate that is
static and cannot be changed at runtime.  If new mesh parameters
are specifed and the reference lies outside of the mesh then the
reference location will be probed.

Additionally this introduces a 'zero_reference_position' option which
accepts a specific X/Y coordinate.  This may be used in place of the
relative_reference_index.

Signed-off-by: Eric Callahan <arksine.code@gmail.com>
2023-06-20 11:48:17 -04:00
Eric Callahan 775092fc01 bed_mesh: generate new points before each calibration
When mesh parameters change the substituted indices need to be
updated, even when using the default point set.   Always generate
new points to perform this update rather than cache
the "orig_points".

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-06-20 11:48:17 -04:00
Kevin O'Connor 0245073c55 serialhdl: Catch os.error on can.interface.Bus() call
It seems opening the canbus socket can sometimes throw an os.error (in
addition to can.CanError).  Catch that error to avoid Klipper
reporting an internal error.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-06-17 19:32:06 -04:00
JamesH1978 38e79dffb6
config: remove move_to_previous from Ender 3 S1 configs (#6245)
This PR is to remove `move_to_previous: true` from the ender 3 S1 and S1 plus configs. This is a confusing option, it is not really useful on these type of printers and can cause issue to the end user

Signed_off_by; James Hartley <james@hartleyns.com>
2023-06-16 17:32:13 -04:00
Luke V 9cb2656914
atsamd: Fixes for samc21 and compiler optimizations (#6198)
Signed-off-by: Luke Vuksta <wulfstawulfsta@gmail.com>
2023-06-16 16:41:08 -04:00
Alex Voinea 5ee72d320c tmc: Configurable `multistep_filt`
Signed-off-by: Alex Voinea <voinea.dragos.alexandru@gmail.com>
2023-06-16 16:38:42 -04:00
IronAegis90 6cbb6f144b
config: Update printer-creality-cr10-smart-pro-2022.cfg (#6253)
Clarified the necessary steps for successfully flashing the firmware to the MCU.

Signed-off-by: Doug Whitlock <doug@thewhitlock.family>
2023-06-16 16:35:12 -04:00
Kevin O'Connor 6ce2bd61cc test: Add stm32f042 regression build test
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-06-08 12:59:30 -04:00
Kevin O'Connor 15d302901f Kconfig: Support selecting optional features on chips with small flash size
Add a new HAVE_LIMITED_CODE_SIZE symbol that enables a menu to select
optional features.  This symbol is enabled on chips with small build
sizes.

Replace the HAVE_GPIO_BITBANGING with four new symbols:
WANT_GPIO_BITBANGING, WANT_DISPLAYS, WANT_SENSORS, WANT_SOFTWARE_SPI,
and WANT_SOFTWARE_I2C.  This allows users a little more flexibility
when selecting features they need.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-06-08 12:59:30 -04:00
BIGTREETECH 645a1b8364
i2c_software: Implementation of software i2c (#6141)
Signed-off-by: Alan.Ma from BigTreeTech <tech@biqu3d.com>
2023-06-07 20:55:46 -04:00
Steve Gotthardt b389c70d5a
hc32f460: update for HC32F460 - clock, flash add, serial (#6235)
Add clock speed selection

Add Flash App Address selection

Add alternate serial connection and remove company specific names

Signed-off-by: Steven Gotthardt <gotthardt@gmail.com>
2023-06-06 22:13:04 -04:00
Jason W. Thompson 3bbae611f9 config: Correct year in documentation for ender 3 v2 neo
The header documentation currently shows the year the Creality Ender 3 V2 Neo as being the 2020 model. This is likely a copy/paste error from the header of the original Creality Ender 3 V2 config. The year the Creality Ender 3 V2 Neo came out was in 2022 as indicated by the name of this config file. This patch fixes the copy/paste typo by updating the year in the header documentation from 2020 to 2022.

Signed-off-by: Jason W. Thompson <jason@jasonthompson.dev>
2023-06-06 22:09:16 -04:00
Dmitry Butyugin a3c00d0bed input_shaper: Correctly initialize input shaper stepper_kinematics
If the stepper already executed some steps with the basic
stepper_kinematics, subsequent creation of a new one for input_shaper
would result in stepcompress errors unless position and time tracking
flags are also copied over.

Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
2023-06-06 20:17:49 -04:00
Dmitry Butyugin e15bad4844 input_shaper: Fixed tracking of step_generation_scan_time
Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
2023-06-06 20:17:49 -04:00
Dmitry Butyugin 345934bd68 idex_modes: Native input shaping support with dual carriages
Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
2023-06-06 20:17:49 -04:00
Dmitry Butyugin 98ed0a8168 test: Regression test for hybrid corexy input shaping with dual carriage
Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
2023-06-06 20:17:49 -04:00
Kevin O'Connor 90e1477d72 docs: Fix link in Sponsors.md
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-06-05 22:14:51 -04:00
Kevin O'Connor a919594b66 docs: Update Sponsors.md
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-06-05 19:24:22 -04:00
Eric Callahan 0539e9f266 bme280: use consistent report time for BME680
Sample the BME680 every .8 seconds, matching that of the
BME280.  This resolves an issue where `get_report_time_delta()`
returns a value that doesn't match the actual delta.

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-05-31 13:43:07 -04:00
Kevin O'Connor ddf0994ba2 parsecandump: New utility to parse Klipper messages in a candump capture
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-30 20:18:41 -04:00
Kevin O'Connor 14ff50c94d docs: Add new CANBUS_Troubleshooting.md document
Add information on troubleshooting canbus connections.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-30 20:16:28 -04:00
Kevin O'Connor 23bbbaa21b Kconfig: Change default CANbus frequency to 1000000
Change the default CANbus frequency from 500000 to 1000000.  A higher
frequency allows for greater data transfer rates, lower latency of
messages, and should overall be more robust.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-30 20:08:06 -04:00
Kevin O'Connor 81e4636f42 docs: Update CANBUS.md
Recommend USB to CAN adapter and no longer recommend using the
waveshare rpi hat.

Recommend using allow-hotplug for all USB adapters.

Note bandwidth limitations when using USB to CAN bridge mode.

Note that a USB to CAN mcu is not a USB serial device.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-30 20:06:59 -04:00
Kevin O'Connor 5f0d252b40 docs: Minor update to Config_Changes.md dates
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-25 12:53:06 -04:00
Dmitry Butyugin 624d360a34 resonance_tester: Apply input shaper params on SHAPER_CALIBRATE
Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
2023-05-25 12:52:29 -04:00
Dmitry Butyugin 16c53992d6 resonance_tester: Support CHIPS= parameter in SHAPER_CALIBRATE command
Signed-off-by: Dmitry Butyugin <dmbutyugin@google.com>
2023-05-25 12:48:17 -04:00
Frans-Willem Hardijzer ec61f10f0f
hybrid_corexy: Fix changing dual-carriage carriage will inadvertently set axis to homed, even if it wasn't. (#6183)
In hybrid_corexy and hybrid_corexz, the update_limits function is (only) called by the DualCarriage implementation, whenever the carriage changes.
Unfortunately, these limits also keep track of homing status, when they're unhomed they are set to 1 to -1 (invalid range).
As a fix, if the limit was set to "unhomed", we keep it that way, and only update it with the new rail limits if it was already properly homed before.

Signed-off-by: Frans-willem Hardijzer <fw@hardijzer.nl>
2023-05-25 11:55:07 -04:00
Stefan Dej 37315bf336 stm32: add PB5/PB6 as CAN pins - required for BTT U2C v2.x
Signed-off-by: Stefan Dej <meteyou@gmail.com>
2023-05-20 11:31:28 -04:00
Chris 7511151ac9
docs: Add gcode_button to the Status Reference docs (#6201)
Add gcode_button to the Status Reference docs

Signed-off-by: Chris Laprade <chris@rootiest.com>
2023-05-14 10:19:42 -04:00
xpeng 2471918f08
config: Change the position_max value of Kobra Go to the physic limit (#6200)
Fixed the bed_mesh out of range issue

Signed-off-by: Yipeng Zhou <yipeng_zhou@foxmail.com>
2023-05-14 10:18:07 -04:00
Frederic Morin 33b18fd62b stm32f7: add support for stm32f7 and remram board
Signed-off-by: Frederic Morin <frederic.morin.8@gmail.com>
2023-05-07 11:15:05 -04:00
Eric Callahan a3eebab4f2 util: report git version info as a dict
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-05-04 14:07:14 -04:00
Eric Callahan b89a049fdb klippy: report repo branch, remote, and tracking url
Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
2023-05-04 14:07:14 -04:00
Kevin O'Connor 3bd0be40d5 lib: Update to latest can2040 code
Disable tx state machine before resetting it
Check for rx message with same id as tx but different payload
Do not use canrx line to alter bit timing of cantx line
Improve bit time synchronization with slow transmitters
Implement tx synchronization to faster transmitters

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-03 10:45:41 -04:00
Kevin O'Connor 1a24e7c5b6 klippy: Report repo version as "dirty" if there are untracked python files
Check for untracked files in the klippy/extras/ and klippy/kinematics/
directories and report those files in the log.  This helps identify
code modifications when inspecting a log.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-05-02 11:40:18 -04:00
Wulfsta 3b0729c949 atsamd: Add support for SAMC21
Signed-off-by: Luke Vuksta <wulfstawulfsta@gmail.com>
2023-05-01 13:56:32 -04:00
Wulfsta 06e5c577bd lib: Add Atmel SAM C21 headers
Signed-off-by: Luke Vuksta <wulfstawulfsta@gmail.com>
2023-05-01 13:56:32 -04:00
Thomas Lété 6414e1772d
config : Longer LK4 X (#6185)
New printer : Longer LK4X configuration

This configuration is based on the one provided by Longer with some tweaks.

Signed-off-by: Thomas Lété <bistory@gmail.com>
2023-05-01 13:30:32 -04:00
Kevin O'Connor 1987742545 lib: Update to latest can2040 code
Fix tx hang after error frame during tx

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-04-29 11:49:53 -04:00
Kevin O'Connor bec1d957d2 rp2040: Handle USB resets
On a USB bus reset the controller address needs to be reset to zero.
Otherwise, the device becomes unresponsive after a USB reset and will
remain unresponsive until a power cycle.  This often shows up in the
Linux system logs as "device descriptor read/64, error -32" messages.

Make sure USB_INTE_BUS_RESET_BITS is enabled and clear the USB address
on a bus reset.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-04-25 00:05:04 -04:00
Kevin O'Connor b17ae55f5b usb_canbus: Rework USB message transmit prioritization
There is no need to heavily prioritize the sending of canbus packets
over USB.  A single check to flush the incoming canbus packets is
sufficient.

Also, be sure to wake up canserial_notify_tx() even if canhw_send()
blocks.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-04-24 11:31:06 -04:00
Kevin O'Connor 28f11244c3 usb_canbus: No need to check if canserial can accept a packet
The canserial code already advertizes a receive window, so the host
should never flood the canserial code.  Remove the extra scheduling
checks to simplify the usb_canbus code.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2023-04-24 11:31:06 -04:00