Skip to main content
Associate
April 17, 2025
Solved

mbedTLS client example STM32Cube_FW_F7_V1.17.0

  • April 17, 2025
  • 1 reply
  • 372 views

Hi, I'm running the following example project:

STM32Cube_FW_F7_V1.17.0\Projects\STM32F769I-Discovery\Applications\mbedTLS\SSL_Client

on the development board STM32F769I-Discovery.

Seems like the application uses the .h file 

STM32Cube_FW_F7_V1.17.0\Middlewares\Third_Party\mbedTLS\include\mbedtls\config.h

to configure the embedTLS module.

The project also includes this .h file for configuration of mbedTLS:

STM32Cube_FW_F7_V1.17.0\Projects\STM32F769I-Discovery\Applications\mbedTLS\SSL_Client\Inc\mbedtls_config.h

But it doesn't seem like it's used, why is that? 

BR

Jonas

 

Best answer by Guillaume K

In every mbedtls include file there is a check on MBEDTLS_CONFIG_FILE C define:

#if !defined(MBEDTLS_CONFIG_FILE)
#include "config.h"
#else
#include MBEDTLS_CONFIG_FILE
#endif

If it is defined, the file indicated in it is included instead of mbedtls\config.h 

It is defined in the SSL_Client example project files : MBEDTLS_CONFIG_FILE=<mbedtls_config.h>

 

1 reply

Guillaume K
ST Employee
April 18, 2025

In every mbedtls include file there is a check on MBEDTLS_CONFIG_FILE C define:

#if !defined(MBEDTLS_CONFIG_FILE)
#include "config.h"
#else
#include MBEDTLS_CONFIG_FILE
#endif

If it is defined, the file indicated in it is included instead of mbedtls\config.h 

It is defined in the SSL_Client example project files : MBEDTLS_CONFIG_FILE=<mbedtls_config.h>