aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBIGTREETECH <38851044+bigtreetech@users.noreply.github.com>2024-01-22 09:23:12 +0800
committerGitHub <noreply@github.com>2024-01-21 20:23:12 -0500
commitdaf875e6e4b8cb461a57623ecac37cf0f1f240e8 (patch)
tree402102c8bd96efe0b119e7dc6070a9f0bec76fa7 /src
parentd785b396a72b57c073ce5bdf7a9d5e9fe39fc914 (diff)
downloadkutter-daf875e6e4b8cb461a57623ecac37cf0f1f240e8.tar.gz
kutter-daf875e6e4b8cb461a57623ecac37cf0f1f240e8.tar.xz
kutter-daf875e6e4b8cb461a57623ecac37cf0f1f240e8.zip
stm32g0: Disable internal pull-down resistors on UCPDx CCx pins, because klipper never uses UCPD (#6462)
Signed-off-by: Alan.Ma from BigTreeTech <tech@biqu3d.com>
Diffstat (limited to 'src')
-rw-r--r--src/stm32/stm32g0.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/stm32/stm32g0.c b/src/stm32/stm32g0.c
index 7408612a..819a5edd 100644
--- a/src/stm32/stm32g0.c
+++ b/src/stm32/stm32g0.c
@@ -162,6 +162,8 @@ bootloader_request(void)
void
armcm_main(void)
{
+ // Disable internal pull-down resistors on UCPDx CCx pins
+ SYSCFG->CFGR1 |= (SYSCFG_CFGR1_UCPD1_STROBE | SYSCFG_CFGR1_UCPD2_STROBE);
SCB->VTOR = (uint32_t)VectorTable;
// Reset clock registers (in case bootloader has changed them)