2025-06-06 1:25 AM - last edited on 2025-06-17 12:06 PM by Andrew Neil
Hi, in custom_stm.h, should add manually #include "ble.h" to works
Solved! Go to Solution.
2025-06-17 10:23 AM - edited 2025-06-17 10:23 AM
Hello @nima.askari
I've personally generated a code on the STM32WB using the STM32_WPAN and the P2P server application type. After compilation, everything works fine and no need to add the file manually (using the STM32CubeMX V6.14.1 and the STM32CubeIDE V1.18.1). If you have the need to use the ble.h and it is not included, you need to ad it manually.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2025-06-06 1:28 AM
Are you referring to some specific example?
Please give details.
How to write your question to maximize your chances to find a solution
2025-06-17 10:23 AM - edited 2025-06-17 10:23 AM
Hello @nima.askari
I've personally generated a code on the STM32WB using the STM32_WPAN and the P2P server application type. After compilation, everything works fine and no need to add the file manually (using the STM32CubeMX V6.14.1 and the STM32CubeIDE V1.18.1). If you have the need to use the ble.h and it is not included, you need to ad it manually.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2025-06-17 11:08 PM
hello, After compile yes, but if you use any ble function in main.c, you got error. i used this code:
/* USER CODE BEGIN 2 */
uint32_t ttt = HAL_GetTick();
uint8_t data[255] = {0};
/* USER CODE END 2 */
/* Init code for STM32_WPAN */
MX_APPE_Init();
/* Infinite loop */
/* USER CODE BEGIN WHILE */
while (1)
{
/* USER CODE END WHILE */
MX_APPE_Process();
/* USER CODE BEGIN 3 */
if ((HAL_GetTick() > 5000) && (HAL_GetTick() - ttt >= 10))
{
ttt = HAL_GetTick();
data[0]++;
Custom_STM_App_Update_Char(CUSTOM_STM_DATA_AQU, data);
}
}
/* USER CODE END 3 */
2025-06-27 10:01 AM
Hello @nima.askari
If you are going to add a function. It may require adding new files to your project to make it work.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.