Skip to main content
OFauc.1
Associate II
March 16, 2021
Question

STM32WL "DEBUG_SUBGHZSPI" alternate functions to debug Radio SPI ?

  • March 16, 2021
  • 1 reply
  • 714 views

Hi all.

I found out there are specific DEBUG_SUBGHZSPI_* alternate functions (DS13105 STM32WLE5xx)

.

But there is not much information about these functions.

Can these AF be used to 'mirror' SUBGHZSPI pins for debugging / captures ?

Thanks

Olivier

This topic has been closed for replies.

1 reply

YBOUV.1
ST Employee
April 20, 2021

Hi,

in Core/Src/sys_debug.c, these pins can be activated with by setting the DEBUGGER_ON to 1

Please, see the code below:

/*Radio Spi Dbg on PA4/5/6/7*/
 
 GPIO_InitStruct.Mode = GPIO_MODE_AF_PP;
 
 GPIO_InitStruct.Pull = GPIO_NOPULL;
 
 GPIO_InitStruct.Pin = (GPIO_PIN_4 | GPIO_PIN_5 | GPIO_PIN_6 | GPIO_PIN_7);
 
 GPIO_InitStruct.Alternate = GPIO_AF13_DEBUG_SUBGHZSPI;
 
 __HAL_RCC_GPIOA_CLK_ENABLE();
 
 HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);
 
 
 
 /* Busy on PA12*/
 
 GPIO_InitStruct.Mode = GPIO_MODE_AF_PP;
 
 GPIO_InitStruct.Pull = GPIO_NOPULL;
 
 GPIO_InitStruct.Pin = (GPIO_PIN_12);
 
 GPIO_InitStruct.Alternate = GPIO_AF6_RF_BUSY;
 
 __HAL_RCC_GPIOA_CLK_ENABLE() ;
 
 HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);