cancel
Showing results for 
Search instead for 
Did you mean: 

Equivalent to SHCI_GetWirelessFwInfo in STM32 SWBA to obtain the stack version

mpc
Associate II

Hi, team

 

I previously worked with a SWB (dual core) microcontroller, and I was able to obtain the stack version using the SHCI_GetWirelessFwInfo function. Now, I am working with a SWBA (single core) but I was unable to find an equivalent function to do it. Do you know if there is an equivalent?, I want to know the stack version on compilation time or runtime, it does not matter.

 

Thanks in advance.

1 REPLY 1
_Joe_
ST Employee

Hi,

Here is an equivalent function used in the examples of the STM32CubeWBA package (Excerpt from an example of version 1.8.0) :

/* Host Stack Version: 0.15, 0.16... */
uint8_t HCI_Version = 0;
uint16_t HCI_Subversion = 0;
uint8_t LMP_Version = 0;
uint16_t Company_Identifier = 0;
uint16_t LMP_Subversion = 0;

hci_read_local_version_information(&HCI_Version, &HCI_Subversion, &LMP_Version, &Company_Identifier, &LMP_Subversion);
a_GATT_DevInfoData[12] = (uint8_t)((uint16_t)HCI_Subversion & 0xff);
LOG_INFO_APP("-- DEVICE INFO CHAR : Host Stack version = 0x%02X\n", a_GATT_DevInfoData[12]);

/* Host Stack Type: Full, Basic, Basic Plus... */
a_GATT_DevInfoData[13] = (uint8_t)(((uint16_t)HCI_Subversion & 0xff00) >> 8);
LOG_INFO_APP("-- DEVICE INFO CHAR : Host Stack Type = 0x%02X\n", a_GATT_DevInfoData[13]);

Here are the values associated with each host stack.

Hex Code Stack Name
0x00 Full Stack
0x10 Basic Plus
0x20 Basic Features
0x40 Peripheral Only
0x80 LL Only
0xA0 LL Only Basic


BR, 
Joé