Skip to content

Commit 173aa6a

Browse files
committed
fix: 修复FGPIO相关错误
1 parent cacc36f commit 173aa6a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

projects/HSLink-Pro/src/DAP_config.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ __STATIC_INLINE uint8_t DAP_GetProductFirmwareVersionString (char *str) {
284284
#define SWD_SPI_BASE_CLOCK_NAME clock_spi1
285285

286286
#define PIN_GPIOM_BASE HPM_GPIOM
287-
#define PIN_GPIO HPM_FGPIO
287+
#define PIN_GPIO HPM_GPIO0
288288
#define PIN_SWDIO_DIR_GPIO HPM_GPIO0
289289

290290
#if defined(USE_HPM_BOARD_JTAG_GPIO) && (USE_HPM_BOARD_JTAG_GPIO == 1)
@@ -352,8 +352,8 @@ Configures the DAP Hardware I/O pins for JTAG mode:
352352
*/
353353
__STATIC_INLINE void gpiom_configure_pin_control_setting(uint16_t gpio_index)
354354
{
355-
gpiom_set_pin_controller(PIN_GPIOM_BASE, GPIO_GET_PORT_INDEX(gpio_index), GPIO_GET_PIN_INDEX(gpio_index), gpiom_core0_fast);
356-
gpiom_enable_pin_visibility(PIN_GPIOM_BASE, GPIO_GET_PORT_INDEX(gpio_index), GPIO_GET_PIN_INDEX(gpio_index), gpiom_core0_fast);
355+
gpiom_set_pin_controller(PIN_GPIOM_BASE, GPIO_GET_PORT_INDEX(gpio_index), GPIO_GET_PIN_INDEX(gpio_index), gpiom_soc_gpio0);
356+
gpiom_enable_pin_visibility(PIN_GPIOM_BASE, GPIO_GET_PORT_INDEX(gpio_index), GPIO_GET_PIN_INDEX(gpio_index), gpiom_soc_gpio0);
357357
gpiom_lock_pin(PIN_GPIOM_BASE, GPIO_GET_PORT_INDEX(gpio_index), GPIO_GET_PIN_INDEX(gpio_index));
358358
}
359359

0 commit comments

Comments
 (0)