🩹 Fix MARLIN_F446Zx_TRONXY variant (#25659)

Followup to 9be1554f
This commit is contained in:
ellensp 2023-04-10 21:16:52 +12:00 committed by Scott Lahteine
parent 81d4f8f26a
commit d05acb7626

View File

@ -176,11 +176,11 @@ void myshow(int fre, int times) // YSZ-WORK
RCC->AHB1ENR |= 1 << 6; // port G clock RCC->AHB1ENR |= 1 << 6; // port G clock
GPIOG->MODER &= ~(3UL << 2 * index); // clear old mode GPIOG->MODER &= ~(3UL << 2 * index); // clear old mode
GPIOG->MODER |= 1 << 2 * index; // mode is output GPIOG->MODER |= 1 << 2 * index; // mode is output
GPIOG->OSPEEDR &= ~(3UL << 2 * index) // Clear old output speed GPIOG->OSPEEDR &= ~(3UL << 2 * index); // Clear old output speed
GPIOG->OSPEEDR |= 2 << 2 * index; // Set output speed GPIOG->OSPEEDR |= 2 << 2 * index; // Set output speed
GPIOG->OTYPER &= ~(1UL << index) // clear old output GPIOG->OTYPER &= ~(1UL << index); // clear old output
GPIOG->OTYPER |= 0 << index; // Set the output mode to push-pull GPIOG->OTYPER |= 0 << index; // Set the output mode to push-pull
GPIOG->PUPDR &= ~(3 << 2 * index) // Clear the original settings first GPIOG->PUPDR &= ~(3 << 2 * index); // Clear the original settings first
GPIOG->PUPDR |= 1 << 2 * index; // Set new up and down GPIOG->PUPDR |= 1 << 2 * index; // Set new up and down
while (times != 0) { while (times != 0) {
GPIOG->BSRR = 1UL << index; GPIOG->BSRR = 1UL << index;