Skip to content

Commit a2ca1fe

Browse files
authored
Merge pull request #8641 from gojimmypi/pr-espressif-examples-update
Espressif updates. Kconfig, WOLFSSL_VIS_FOR_TESTS, ESP32P4
2 parents f29f928 + 40c52bd commit a2ca1fe

18 files changed

Lines changed: 245 additions & 79 deletions

File tree

.wolfssl_known_macro_extras

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ CONFIG_IDF_TARGET_ESP32C2
8181
CONFIG_IDF_TARGET_ESP32C3
8282
CONFIG_IDF_TARGET_ESP32C6
8383
CONFIG_IDF_TARGET_ESP32H2
84+
CONFIG_IDF_TARGET_ESP32P4
8485
CONFIG_IDF_TARGET_ESP32S2
8586
CONFIG_IDF_TARGET_ESP32S3
8687
CONFIG_IDF_TARGET_ESP8266

IDE/Espressif/ESP-IDF/examples/template/CMakeLists.txt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ else()
1414
add_compile_definitions(WOLFSSL_ESP_NO_WATCHDOG=1)
1515
endif()
1616

17-
1817
# The wolfSSL CMake file should be able to find the source code.
1918
# Otherwise, assign an environment variable or set it here:
2019
#
@@ -129,7 +128,7 @@ endif()
129128
# an unintuitive error about Unknown CMake command "esptool_py_flash_project_args".
130129

131130
if(0)
132-
message(STATUS "Begin optional PROTOCOL_EXAMPLES_DIR include")
131+
message(STATUS "Begin optional PROTOCOL_EXAMPLES_DIR include")
133132
# This example uses an extra component for common functions such as Wi-Fi and Ethernet connection.
134133
set (PROTOCOL_EXAMPLES_DIR $ENV{IDF_PATH}/examples/common_components/protocol_examples_common)
135134

@@ -140,7 +139,7 @@ if(0)
140139
else()
141140
message(STATUS "NOT FOUND: PROTOCOL_EXAMPLES_DIR=${PROTOCOL_EXAMPLES_DIR}")
142141
endif()
143-
message(STATUS "End optional PROTOCOL_EXAMPLES_DIR include")
142+
message(STATUS "End optional PROTOCOL_EXAMPLES_DIR include")
144143
endif()
145144

146145
include($ENV{IDF_PATH}/tools/cmake/project.cmake)

IDE/Espressif/ESP-IDF/examples/template/components/wolfssl/include/user_settings.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,18 +110,21 @@
110110
/* We don't use WiFi, so don't compile in the esp-sdk-lib WiFi helpers: */
111111
/* #define USE_WOLFSSL_ESP_SDK_WIFI */
112112
#define TEST_ESPIDF_ALL_WOLFSSL
113-
113+
#define WOLFSSL_VIS_FOR_TESTS
114114
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_BENCHMARK)
115115
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_benchmark */
116116
/* We don't use WiFi, so don't compile in the esp-sdk-lib WiFi helpers: */
117117
/* #define USE_WOLFSSL_ESP_SDK_WIFI */
118118
#define WOLFSSL_BENCHMARK_FIXED_UNITS_KB
119+
#define WOLFSSL_VIS_FOR_TESTS
119120
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_TLS_CLIENT)
120121
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_client */
121122
#define USE_WOLFSSL_ESP_SDK_WIFI
123+
#define WOLFSSL_VIS_FOR_TESTS
122124
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_TLS_SERVER)
123125
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_server */
124126
#define USE_WOLFSSL_ESP_SDK_WIFI
127+
#define WOLFSSL_VIS_FOR_TESTS
125128

126129
/* wolfSSH Examples */
127130
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_WOLFSSH_TEMPLATE)

IDE/Espressif/ESP-IDF/examples/template/main/Kconfig.projbuild

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,6 @@ choice WOLFSSL_EXAMPLE_CHOOSE
6565
help
6666
See wolfSSL/wolfssh on GitHub.
6767

68-
config WOLFSSL_EXAMPLE_NAME_WOLFSSH_ECHOSERVER
69-
bool "SSH Echo Server"
70-
help
71-
See wolfSSL/wolfssh on GitHub.
72-
7368
config WOLFSSL_EXAMPLE_NAME_ESP32_SSH_SERVER
7469
bool "SSH to UART Server for the ESP32"
7570
help
@@ -95,12 +90,6 @@ choice WOLFSSL_EXAMPLE_CHOOSE
9590
help
9691
See wolfSSL/wolfTPM on GitHub.
9792

98-
config WOLFSSL_APPLE_HOMEKIT
99-
bool "Apple HomeKit for the ESP32"
100-
help
101-
See AchimPieters/esp32-homekit-demo on GitHub.
102-
103-
10493
config WOLFSSL_EXAMPLE_NAME_NONE
10594
bool "Other"
10695
help

IDE/Espressif/ESP-IDF/examples/wolfssl_benchmark/components/wolfssl/include/user_settings.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,13 @@
110110
/* We don't use WiFi, so don't compile in the esp-sdk-lib WiFi helpers: */
111111
/* #define USE_WOLFSSL_ESP_SDK_WIFI */
112112
#define TEST_ESPIDF_ALL_WOLFSSL
113-
113+
#define WOLFSSL_VIS_FOR_TESTS
114114
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_BENCHMARK)
115115
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_benchmark */
116116
/* We don't use WiFi, so don't compile in the esp-sdk-lib WiFi helpers: */
117117
/* #define USE_WOLFSSL_ESP_SDK_WIFI */
118118
#define WOLFSSL_BENCHMARK_FIXED_UNITS_KB
119+
#define WOLFSSL_VIS_FOR_TESTS
119120
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_TLS_CLIENT)
120121
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_client */
121122
#define USE_WOLFSSL_ESP_SDK_WIFI

IDE/Espressif/ESP-IDF/examples/wolfssl_benchmark/main/Kconfig.projbuild

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,102 @@
1+
# Kconfig main
2+
#
3+
# Copyright (C) 2006-2025 wolfSSL Inc.
4+
#
5+
# This file is part of wolfSSL.
6+
#
7+
# wolfSSL is free software; you can redistribute it and/or modify
8+
# it under the terms of the GNU General Public License as published by
9+
# the Free Software Foundation; either version 2 of the License, or
10+
# (at your option) any later version.
11+
#
12+
# wolfSSL is distributed in the hope that it will be useful,
13+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
14+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15+
# GNU General Public License for more details.
16+
#
17+
# You should have received a copy of the GNU General Public License
18+
# along with this program; if not, write to the Free Software
19+
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
20+
#
21+
22+
# Kconfig File Version 5.7.2.001 for wolfssl_template
23+
124
menu "Example Configuration"
225

26+
choice WOLFSSL_EXAMPLE_CHOOSE
27+
prompt "Choose Example (See wolfssl/include/user_settings.h)"
28+
default WOLFSSL_EXAMPLE_NAME_NONE
29+
help
30+
The user settings file can be adjusted to specific wolfSSL examples.
31+
32+
config WOLFSSL_EXAMPLE_NAME_TEMPLATE
33+
bool "wolfSSL Template"
34+
help
35+
The sample template app compiles in wolfSSL and prints the current wolfSSL Version. Nothing more.
36+
37+
config WOLFSSL_EXAMPLE_NAME_TEST
38+
bool "wolfSSL Test"
39+
help
40+
This app tests all cryptographic functions currently enabled. See also Benchmark performance app.
41+
42+
config WOLFSSL_EXAMPLE_NAME_BENCHMARK
43+
bool "wolfSSL Benchmark"
44+
help
45+
Benchmark performance app. See also cryptographic test.
46+
47+
config WOLFSSL_EXAMPLE_NAME_TLS_CLIENT
48+
bool "TLS Client"
49+
help
50+
TLS Client Example app. Needs WiFi and a listening server on port 11111.
51+
52+
config WOLFSSL_EXAMPLE_NAME_TLS_SERVER
53+
bool "TLS Server"
54+
help
55+
TLS Server Example app. Needs WiFi. More interesting with a TLS client using port 11111.
56+
57+
config WOLFSSL_EXAMPLE_NAME_WOLFSSH_TEMPLATE
58+
bool "SSH Template App"
59+
help
60+
Bare-bones Hello World app that only compiles in wolfSSL and wolfSSH.
61+
See wolfSSL/wolfssh on GitHub.
62+
63+
config WOLFSSL_EXAMPLE_NAME_WOLFSSH_ECHOSERVER
64+
bool "SSH Echo Server"
65+
help
66+
See wolfSSL/wolfssh on GitHub.
67+
68+
config WOLFSSL_EXAMPLE_NAME_ESP32_SSH_SERVER
69+
bool "SSH to UART Server for the ESP32"
70+
help
71+
See wolfSSL/wolfssh-examples on GitHub.
72+
73+
config WOLFSSL_EXAMPLE_NAME_ESP8266_SSH_SERVER
74+
bool "SSH to UART Server for the ESP8266"
75+
help
76+
See wolfSSL/wolfssh-examples on GitHub.
77+
78+
config WOLFSSL_EXAMPLE_NAME_WOLFMQTT_TEMPLATE
79+
bool "MQTT Template"
80+
help
81+
See wolfSSL/wolfmqtt on GitHub.
82+
83+
config WOLFSSL_EXAMPLE_NAME_WOLFMQTT_AWS_IOT_MQTT
84+
bool "MQTT AWS IoT"
85+
help
86+
See wolfSSL/wolfmqtt on GitHub.
87+
88+
config WOLFTPM_EXAMPLE_NAME_ESPRESSIF
89+
bool "TPM Test Example for the ESP32"
90+
help
91+
See wolfSSL/wolfTPM on GitHub.
92+
93+
config WOLFSSL_EXAMPLE_NAME_NONE
94+
bool "Other"
95+
help
96+
A specific example app is not defined.
97+
98+
endchoice
99+
3100
config BENCH_ARGV
4101
string "Arguments for benchmark test"
5102
default "-lng 0"

IDE/Espressif/ESP-IDF/examples/wolfssl_benchmark/sdkconfig.defaults

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Set the known example app config to template example (see user_settings.h)
2-
CONFIG_WOLFSSL_EXAMPLE_NAME_WOLFSSL_BENCHMARK=y
2+
CONFIG_WOLFSSL_EXAMPLE_NAME_BENCHMARK=y
33

44
# CONFIG_EXAMPLE_WIFI_SSID="myssid"
55
# CONFIG_EXAMPLE_WIFI_PASSWORD="mypassword"

IDE/Espressif/ESP-IDF/examples/wolfssl_client/CMakeLists.txt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ else()
1414
add_compile_definitions(WOLFSSL_ESP_NO_WATCHDOG=1)
1515
endif()
1616

17-
1817
# The wolfSSL CMake file should be able to find the source code.
1918
# Otherwise, assign an environment variable or set it here:
2019
#
@@ -129,7 +128,7 @@ endif()
129128
# an unintuitive error about Unknown CMake command "esptool_py_flash_project_args".
130129

131130
if(0)
132-
message(STATUS "Begin optional PROTOCOL_EXAMPLES_DIR include")
131+
message(STATUS "Begin optional PROTOCOL_EXAMPLES_DIR include")
133132
# This example uses an extra component for common functions such as Wi-Fi and Ethernet connection.
134133
set (PROTOCOL_EXAMPLES_DIR $ENV{IDF_PATH}/examples/common_components/protocol_examples_common)
135134

@@ -140,7 +139,7 @@ if(0)
140139
else()
141140
message(STATUS "NOT FOUND: PROTOCOL_EXAMPLES_DIR=${PROTOCOL_EXAMPLES_DIR}")
142141
endif()
143-
message(STATUS "End optional PROTOCOL_EXAMPLES_DIR include")
142+
message(STATUS "End optional PROTOCOL_EXAMPLES_DIR include")
144143
endif()
145144

146145
include($ENV{IDF_PATH}/tools/cmake/project.cmake)

IDE/Espressif/ESP-IDF/examples/wolfssl_client/components/wolfssl/include/user_settings.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,18 +110,21 @@
110110
/* We don't use WiFi, so don't compile in the esp-sdk-lib WiFi helpers: */
111111
/* #define USE_WOLFSSL_ESP_SDK_WIFI */
112112
#define TEST_ESPIDF_ALL_WOLFSSL
113-
113+
#define WOLFSSL_VIS_FOR_TESTS
114114
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_BENCHMARK)
115115
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_benchmark */
116116
/* We don't use WiFi, so don't compile in the esp-sdk-lib WiFi helpers: */
117117
/* #define USE_WOLFSSL_ESP_SDK_WIFI */
118118
#define WOLFSSL_BENCHMARK_FIXED_UNITS_KB
119+
#define WOLFSSL_VIS_FOR_TESTS
119120
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_TLS_CLIENT)
120121
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_client */
121122
#define USE_WOLFSSL_ESP_SDK_WIFI
123+
#define WOLFSSL_VIS_FOR_TESTS
122124
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_TLS_SERVER)
123125
/* See https://github.com/wolfSSL/wolfssl/tree/master/IDE/Espressif/ESP-IDF/examples/wolfssl_server */
124126
#define USE_WOLFSSL_ESP_SDK_WIFI
127+
#define WOLFSSL_VIS_FOR_TESTS
125128

126129
/* wolfSSH Examples */
127130
#elif defined(CONFIG_WOLFSSL_EXAMPLE_NAME_WOLFSSH_TEMPLATE)

IDE/Espressif/ESP-IDF/examples/wolfssl_client/main/Kconfig.projbuild

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,6 @@ choice WOLFSSL_EXAMPLE_CHOOSE
6565
help
6666
See wolfSSL/wolfssh on GitHub.
6767

68-
config WOLFSSL_EXAMPLE_NAME_WOLFSSH_ECHOSERVER
69-
bool "SSH Echo Server"
70-
help
71-
See wolfSSL/wolfssh on GitHub.
72-
7368
config WOLFSSL_EXAMPLE_NAME_ESP32_SSH_SERVER
7469
bool "SSH to UART Server for the ESP32"
7570
help
@@ -95,12 +90,6 @@ choice WOLFSSL_EXAMPLE_CHOOSE
9590
help
9691
See wolfSSL/wolfTPM on GitHub.
9792

98-
config WOLFSSL_APPLE_HOMEKIT
99-
bool "Apple HomeKit for the ESP32"
100-
help
101-
See AchimPieters/esp32-homekit-demo on GitHub.
102-
103-
10493
config WOLFSSL_EXAMPLE_NAME_NONE
10594
bool "Other"
10695
help

0 commit comments

Comments
 (0)