Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HC32: fix WDT reset when saving UBL mesh #27084

Merged
merged 1 commit into from
May 15, 2024

Conversation

shadow578
Copy link
Contributor

Description

While setting up UBL, i found that the WDT would reset the printer when trying to save a the mesh.

After some debugging, i've found the auto-configuration function in the IWatchdog library to fail configuring when a 5s timeout, instead configuring a timeout after ~2s.

to mitigate this issue, 2 changes were implemented:

  1. lower the PCLK3 clock to 25MHz (in this PR)
  2. update the auto-config function of the IWatchdog library (in fix watchdog autoconfiguring a timeout below the target shadow578/framework-arduino-hc32f46x#26)

Either of these would be sufficient to fix the reset "symptom", but both are necessary to get the watchdog to behave as expected.

Requirements

Any HC32 based board

Benefits

Fixes unexpected watchdog timeouts when saving UBL mesh data.

Configurations

N/A

Related Issues

N/A

@thinkyhead thinkyhead added T: HAL & APIs Topic related to the HAL and internal APIs. A: STM32 labels May 15, 2024
@thinkyhead thinkyhead merged commit 6b5e19c into MarlinFirmware:bugfix-2.1.x May 15, 2024
62 checks passed
@shadow578 shadow578 deleted the fix/hc32-wdt branch May 16, 2024 06:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: STM32 T: HAL & APIs Topic related to the HAL and internal APIs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants