mirror of
https://github.com/espressif/esp-protocols.git
synced 2025-12-23 07:12:32 +01:00
Compare commits
16 Commits
websocket-
...
eppp-v1.0.
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
33a3ec54b6 | ||
|
|
c91578c827 | ||
|
|
653328ba07 | ||
|
|
f8748e026d | ||
|
|
479122b21d | ||
|
|
e8ce8f4739 | ||
|
|
03df9ae957 | ||
|
|
35fa0b1d42 | ||
|
|
e9d9b3a8bd | ||
|
|
07e8eddcb6 | ||
|
|
78ae25598b | ||
|
|
ffeee3e87a | ||
|
|
6d5411941b | ||
|
|
e71365f835 | ||
|
|
8dbf0e4561 | ||
|
|
63bf70914b |
@@ -59,10 +59,11 @@ jobs:
|
||||
- name: Build with IDF-${{ matrix.idf_ver }}
|
||||
shell: bash
|
||||
run: |
|
||||
. ${GITHUB_WORKSPACE}/ci/config_env.sh
|
||||
. ${IDF_PATH}/export.sh
|
||||
python -m pip install idf-build-apps
|
||||
python ./ci/build_apps.py examples/mqtt -l -t linux
|
||||
timeout 5 ./examples/mqtt/build_linux_default/esp_mqtt_demo.elf | tee test.log || true
|
||||
python ./ci/build_apps.py examples/mqtt -l -t linux -r 'sdkconfig.ci'
|
||||
timeout 5 ./examples/mqtt/build_linux/esp_mqtt_demo.elf | tee test.log || true
|
||||
grep 'MQTT_EVENT_DATA' test.log
|
||||
|
||||
run_on_target:
|
||||
|
||||
12
.github/workflows/modem__target-test.yml
vendored
12
.github/workflows/modem__target-test.yml
vendored
@@ -34,18 +34,16 @@ jobs:
|
||||
IDF_TARGET: ${{ matrix.idf_target }}
|
||||
SDKCONFIG: sdkconfig.ci.${{ matrix.test.app }}
|
||||
shell: bash
|
||||
working-directory: ${{ env.TEST_DIR }}
|
||||
run: |
|
||||
. ${GITHUB_WORKSPACE}/ci/config_env.sh
|
||||
. ${IDF_PATH}/export.sh
|
||||
rm -rf sdkconfig build
|
||||
[ -f ${SDKCONFIG} ] && cp ${SDKCONFIG} sdkconfig.defaults
|
||||
idf.py set-target ${{ matrix.idf_target }}
|
||||
idf.py build
|
||||
$GITHUB_WORKSPACE/ci/clean_build_artifacts.sh ${GITHUB_WORKSPACE}/${TEST_DIR}/build
|
||||
python -m pip install idf-build-apps
|
||||
python ./ci/build_apps.py ${{ env.TEST_DIR }} -t ${{ matrix.idf_target }} -r 'sdkconfig.ci.${{ matrix.test.app }}'
|
||||
$GITHUB_WORKSPACE/ci/clean_build_artifacts.sh ${GITHUB_WORKSPACE}/${TEST_DIR}/build_${{ matrix.idf_target }}
|
||||
- uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: modem_target_bin_${{ matrix.idf_target }}_${{ matrix.idf_ver }}_${{ matrix.test.app }}
|
||||
path: ${{ env.TEST_DIR }}/build
|
||||
path: ${{ env.TEST_DIR }}/build_${{ matrix.idf_target }}
|
||||
if-no-files-found: error
|
||||
|
||||
target_tests_esp_modem:
|
||||
|
||||
6
.github/workflows/mosq__build.yml
vendored
6
.github/workflows/mosq__build.yml
vendored
@@ -18,6 +18,10 @@ jobs:
|
||||
exclude:
|
||||
- idf_ver: "release-v5.1"
|
||||
example: "serverless_mqtt" # serverless_mqtt is not supported due to esp-peer
|
||||
include:
|
||||
- idf_ver: "latest"
|
||||
example: "serverless_mqtt"
|
||||
warning: "'octal_mode' is deprecated"
|
||||
|
||||
runs-on: ubuntu-22.04
|
||||
container: espressif/idf:${{ matrix.idf_ver }}
|
||||
@@ -31,6 +35,8 @@ jobs:
|
||||
with:
|
||||
submodules: recursive
|
||||
- name: Build with IDF-${{ matrix.idf_ver }}
|
||||
env:
|
||||
EXPECTED_WARNING: ${{ matrix.warning }}
|
||||
shell: bash
|
||||
run: |
|
||||
. ${IDF_PATH}/export.sh
|
||||
|
||||
2
.github/workflows/pre_commit_check.yml
vendored
2
.github/workflows/pre_commit_check.yml
vendored
@@ -39,7 +39,7 @@ jobs:
|
||||
if ! pre-commit run --from-ref origin/HEAD --to-ref HEAD --hook-stage manual --show-diff-on-failure ; then
|
||||
echo ""
|
||||
echo "::notice::It looks like the commits in this PR have been made without having pre-commit hooks installed."
|
||||
echo "::notice::Please see https://github.com/espressif/esp-protocols/CONTRIBUTING.md for instructions."
|
||||
echo "::notice::Please see https://github.com/espressif/esp-protocols/blob/master/CONTRIBUTING.md for instructions."
|
||||
echo ""
|
||||
exit 1
|
||||
fi
|
||||
|
||||
3
.github/workflows/tls_cxx__build.yml
vendored
3
.github/workflows/tls_cxx__build.yml
vendored
@@ -25,6 +25,9 @@ jobs:
|
||||
- name: Build ${{ matrix.test.app }} with IDF-${{ matrix.idf_ver }}
|
||||
shell: bash
|
||||
run: |
|
||||
if [[ "${{ matrix.idf_ver }}" != "latest" ]]; then
|
||||
export EXPECTED_WARNING="unknown kconfig symbol 'MBEDTLS_SSL_COOKIE_C'"
|
||||
fi
|
||||
. ${IDF_PATH}/export.sh
|
||||
pip install idf-component-manager idf-build-apps --upgrade
|
||||
python ./ci/build_apps.py ./components/mbedtls_cxx/${{ matrix.test.path }} -vv --preserve-all
|
||||
|
||||
@@ -25,12 +25,8 @@ repos:
|
||||
(?x)^(
|
||||
.*.py
|
||||
)$
|
||||
- repo: https://github.com/myint/unify
|
||||
rev: v0.5
|
||||
hooks:
|
||||
- id: unify
|
||||
- repo: https://github.com/pre-commit/mirrors-yapf
|
||||
rev: "v0.32.0"
|
||||
- repo: https://github.com/google/yapf
|
||||
rev: "v0.43.0"
|
||||
hooks:
|
||||
- id: yapf
|
||||
args: ['style={based_on_style: google, column_limit: 160, indent_width: 4}']
|
||||
@@ -39,7 +35,7 @@ repos:
|
||||
hooks:
|
||||
- id: isort
|
||||
- repo: https://github.com/myint/eradicate/
|
||||
rev: v2.1.0
|
||||
rev: 3.0.0
|
||||
hooks:
|
||||
- id: eradicate
|
||||
- repo: https://github.com/espressif/check-copyright/
|
||||
|
||||
@@ -65,6 +65,7 @@ if __name__ == '__main__':
|
||||
|
||||
sys.exit(
|
||||
build_apps(apps,
|
||||
verbose=2,
|
||||
dry_run=False,
|
||||
keep_going=False,
|
||||
no_preserve=args.delete,
|
||||
|
||||
7
ci/config_env.sh
Executable file
7
ci/config_env.sh
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
# This script is used to set some common variables for the CI pipeline.
|
||||
|
||||
set -e
|
||||
|
||||
# MQTT public broker URI
|
||||
export CI_MQTT_BROKER_URI="test.mosquitto.org"
|
||||
@@ -3,6 +3,6 @@ commitizen:
|
||||
bump_message: 'bump(eppp): $current_version -> $new_version'
|
||||
pre_bump_hooks: python ../../ci/changelog.py eppp_link
|
||||
tag_format: eppp-v$version
|
||||
version: 1.0.0
|
||||
version: 1.0.1
|
||||
version_files:
|
||||
- idf_component.yml
|
||||
|
||||
@@ -1,5 +1,11 @@
|
||||
# Changelog
|
||||
|
||||
## [1.0.1](https://github.com/espressif/esp-protocols/commits/eppp-v1.0.1)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- Support for IPv4-only mode ([653328ba](https://github.com/espressif/esp-protocols/commit/653328ba), [#864](https://github.com/espressif/esp-protocols/issues/864))
|
||||
|
||||
## [1.0.0](https://github.com/espressif/esp-protocols/commits/eppp-v1.0.0)
|
||||
|
||||
### Features
|
||||
|
||||
@@ -65,12 +65,13 @@ static err_t tun_output_v4(struct netif *netif, struct pbuf *p, const ip4_addr_t
|
||||
LWIP_UNUSED_ARG(ipaddr);
|
||||
return tun_output(netif, p);
|
||||
}
|
||||
#if LWIP_IPV6
|
||||
static err_t tun_output_v6(struct netif *netif, struct pbuf *p, const ip6_addr_t *ipaddr)
|
||||
{
|
||||
LWIP_UNUSED_ARG(ipaddr);
|
||||
return tun_output(netif, p);
|
||||
}
|
||||
|
||||
#endif
|
||||
static err_t tun_init(struct netif *netif)
|
||||
{
|
||||
if (netif == NULL) {
|
||||
@@ -151,9 +152,12 @@ static void cmd_ping_on_ping_end(esp_ping_handle_t hdl, void *args)
|
||||
}
|
||||
if (IP_IS_V4(&target_addr)) {
|
||||
ESP_LOGD(TAG, "\n--- %s ping statistics ---\n", inet_ntoa(*ip_2_ip4(&target_addr)));
|
||||
} else {
|
||||
}
|
||||
#if LWIP_IPV6
|
||||
else {
|
||||
ESP_LOGD(TAG, "\n--- %s ping statistics ---\n", inet6_ntoa(*ip_2_ip6(&target_addr)));
|
||||
}
|
||||
#endif
|
||||
ESP_LOGI(TAG, "%" PRIu32 " packets transmitted, %" PRIu32 " received, %" PRIu32 "%% packet loss, time %" PRIu32 "ms\n",
|
||||
transmitted, received, loss, total_time_ms);
|
||||
esp_ping_delete_session(hdl);
|
||||
@@ -168,7 +172,11 @@ esp_err_t eppp_check_connection(esp_netif_t *netif)
|
||||
ip_addr_t target_addr = {0};
|
||||
esp_netif_ip_info_t ip;
|
||||
esp_netif_get_ip_info(netif, &ip);
|
||||
#if LWIP_IPV6
|
||||
target_addr.u_addr.ip4.addr = ip.gw.addr;
|
||||
#else
|
||||
target_addr.addr = ip.gw.addr;
|
||||
#endif
|
||||
config.target_addr = target_addr;
|
||||
esp_ping_callbacks_t cbs = {
|
||||
.cb_args = netif,
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
CONFIG_LWIP_IPV6=n
|
||||
@@ -1,4 +1,4 @@
|
||||
version: 1.0.0
|
||||
version: 1.0.1
|
||||
url: https://github.com/espressif/esp-protocols/tree/master/components/eppp_link
|
||||
description: The component provides a general purpose PPP connectivity, typically used as WiFi-PPP router
|
||||
dependencies:
|
||||
|
||||
@@ -13,5 +13,5 @@ CONFIG_EXAMPLE_MODEM_PPP_APN="lpwa.vodafone.com"
|
||||
CONFIG_EXAMPLE_MQTT_TEST_TOPIC="/ci/esp-modem/pppos-client"
|
||||
CONFIG_EXAMPLE_PAUSE_NETIF_TO_CHECK_SIGNAL=y
|
||||
CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y
|
||||
CONFIG_ESP32_PANIC_PRINT_HALT=y
|
||||
CONFIG_EXAMPLE_DETECT_MODE_BEFORE_CONNECT=y
|
||||
CONFIG_EXAMPLE_MQTT_BROKER_URI="mqtt://${CI_MQTT_BROKER_URI}"
|
||||
|
||||
@@ -8,7 +8,6 @@ CONFIG_LWIP_PPP_ENABLE_IPV6=n
|
||||
CONFIG_EXAMPLE_SERIAL_CONFIG_USB=y
|
||||
CONFIG_EXAMPLE_MODEM_DEVICE_A7670=y
|
||||
CONFIG_EXAMPLE_MODEM_PPP_APN="lpwa.vodafone.com"
|
||||
CONFIG_EXAMPLE_MODEM_PPP_AUTH_NONE=y
|
||||
CONFIG_EXAMPLE_MQTT_TEST_TOPIC="/ci/esp-modem/pppos-client"
|
||||
CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y
|
||||
CONFIG_ESP32_PANIC_PRINT_HALT=y
|
||||
CONFIG_EXAMPLE_MQTT_BROKER_URI="mqtt://${CI_MQTT_BROKER_URI}"
|
||||
|
||||
@@ -11,9 +11,8 @@ CONFIG_EXAMPLE_MODEM_DEVICE_SIM800=y
|
||||
CONFIG_EXAMPLE_MODEM_DEVICE_BG96=n
|
||||
CONFIG_EXAMPLE_MODEM_PPP_APN="lpwa.vodafone.com"
|
||||
CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y
|
||||
CONFIG_ESP32_PANIC_PRINT_HALT=y
|
||||
CONFIG_COMPILER_CXX_EXCEPTIONS=y
|
||||
CONFIG_ESP_MAIN_TASK_STACK_SIZE=8192
|
||||
CONFIG_EXAMPLE_CLOSE_CMUX_AT_END=y
|
||||
CONFIG_EXAMPLE_MQTT_TEST_TOPIC="/ci/esp-modem/pppos-client"
|
||||
CONFIG_BROKER_URI="mqtt://test.mosquitto.org"
|
||||
CONFIG_BROKER_URI="mqtt://${CI_MQTT_BROKER_URI}"
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
CONFIG_MBEDTLS_SSL_PROTO_DTLS=y
|
||||
CONFIG_MBEDTLS_SSL_COOKIE_C=y
|
||||
CONFIG_PTHREAD_TASK_STACK_SIZE_DEFAULT=8192
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
CONFIG_IDF_TARGET="esp32"
|
||||
CONFIG_MBEDTLS_SSL_PROTO_DTLS=y
|
||||
CONFIG_MBEDTLS_SSL_COOKIE_C=y
|
||||
CONFIG_PTHREAD_TASK_STACK_SIZE_DEFAULT=8192
|
||||
|
||||
@@ -154,7 +154,7 @@
|
||||
} \
|
||||
}
|
||||
|
||||
#define queueFree(type, queue) while (queue) { type * _q = queue; queue = queue->next; free(_q); }
|
||||
#define queueFree(type, queue) while (queue) { type * _q = queue; queue = queue->next; mdns_mem_free(_q); }
|
||||
|
||||
#define PCB_STATE_IS_PROBING(s) (s->state > PCB_OFF && s->state < PCB_ANNOUNCE_1)
|
||||
#define PCB_STATE_IS_ANNOUNCING(s) (s->state > PCB_PROBE_3 && s->state < PCB_RUNNING)
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
From 600c9baaa622cd0885697829bcc5e22fa0a79e68 Mon Sep 17 00:00:00 2001
|
||||
From: David Cermak <cermak@espressif.com>
|
||||
Date: Fri, 25 Jul 2025 17:20:10 +0200
|
||||
Subject: [PATCH] fix(media_lib): Remove deprecated API for get_stack_frame API
|
||||
|
||||
---
|
||||
components/media_lib_sal/port/media_lib_os_freertos.c | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/components/media_lib_sal/port/media_lib_os_freertos.c b/components/media_lib_sal/port/media_lib_os_freertos.c
|
||||
index d248d59..1117926 100644
|
||||
--- a/components/media_lib_sal/port/media_lib_os_freertos.c
|
||||
+++ b/components/media_lib_sal/port/media_lib_os_freertos.c
|
||||
@@ -369,7 +369,11 @@ static int _get_stack_frame(void** addr, int n)
|
||||
TaskSnapshot_t snap_shot;
|
||||
TaskHandle_t cur_task = xTaskGetCurrentTaskHandle();
|
||||
vTaskGetSnapshot(cur_task, &snap_shot);
|
||||
- snap_shot.pxTopOfStack = pxTaskGetStackStart(cur_task);;
|
||||
+#if (ESP_IDF_VERSION > ESP_IDF_VERSION_VAL(5, 5, 0))
|
||||
+ snap_shot.pxTopOfStack = xTaskGetStackStart(cur_task);
|
||||
+#else
|
||||
+ snap_shot.pxTopOfStack = pxTaskGetStackStart(cur_task);
|
||||
+#endif
|
||||
esp_backtrace_get_start(&(frame.pc), &(frame.sp), &(frame.next_pc));
|
||||
|
||||
for (int i = 0; i < n; i++) {
|
||||
--
|
||||
2.43.0
|
||||
@@ -14,6 +14,7 @@ COMPONENTS_SRC="${EXTRACTED_DIR}/components"
|
||||
COMPONENTS_DST="${ESP_PEER_DIR}/components"
|
||||
PATCH_FILE_1="${THIS_DIR}/Remove-deprecated-freeRTOS-header.patch"
|
||||
PATCH_FILE_2="${THIS_DIR}/libpeer-Add-direct-dependency-to-libsrtp.patch"
|
||||
PATCH_FILE_3="${THIS_DIR}/Remove-deprecated-API-for-get_stack_fr.patch"
|
||||
|
||||
# Download if not exists
|
||||
if [ ! -d "$EXTRACTED_DIR" ]; then
|
||||
@@ -22,6 +23,7 @@ if [ ! -d "$EXTRACTED_DIR" ]; then
|
||||
unzip -o "$ZIP_PATH" -d "$ESP_PEER_DIR"
|
||||
patch -p1 -d "$EXTRACTED_DIR" < "$PATCH_FILE_1"
|
||||
patch -p1 -d "$EXTRACTED_DIR" < "$PATCH_FILE_2"
|
||||
patch -p1 -d "$EXTRACTED_DIR" < "$PATCH_FILE_3"
|
||||
mv ${EXTRACTED_DIR}/components ${ESP_PEER_DIR}
|
||||
mv ${ESP_PEER_DIR}/components/esp_webrtc/impl/peer_default ${ESP_PEER_DIR}/components
|
||||
fi
|
||||
|
||||
2
examples/mqtt/sdkconfig.ci
Normal file
2
examples/mqtt/sdkconfig.ci
Normal file
@@ -0,0 +1,2 @@
|
||||
# CONFIG_ESP_EVENT_POST_FROM_ISR is not set
|
||||
CONFIG_BROKER_URL="mqtt://${CI_MQTT_BROKER_URI}"
|
||||
Reference in New Issue
Block a user