Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
b9d7970
feat(wifi_remote): Move to esp-protocols
mantriyogesh Jan 2, 2024
a80dc28
feat(wifi_remote): Added generation step for wifi_remote based on IDF
david-cermak Mar 4, 2024
5e5c970
bump(wifi_remote): Initial version 0.1.12
david-cermak Mar 13, 2024
e44f9e9
feat(wifi_remote): Add support for simple eppp based RPC
david-cermak Apr 10, 2024
487ce9e
fix(wifi_remote): Add examples to CI
david-cermak Apr 11, 2024
2034441
fix(wifi_remote): Make services restartable, code cleanup
david-cermak Apr 11, 2024
01bd47e
bump(wifi_remote): 0.1.12 -> 0.2.0
david-cermak Apr 25, 2024
1bc2ba9
fix(wifi_remote): Updated eppp dependency not to use fixed version
david-cermak May 6, 2024
8248299
fix(wifi_remote): Added misc wifi API in eppp impl
david-cermak May 7, 2024
432efbd
bump(wifi_remote): 0.2.0 -> 0.2.1
david-cermak May 7, 2024
a20ed63
fix(wifi_remote): Do not restrict EPPP config to RSA keys only
david-cermak May 20, 2024
c1e2355
fix(wifi_remote): Fix build test to download only idf-build-apps deps
david-cermak May 27, 2024
dd90f2a
fix(wifi_remote): Added more netif options for eppp connection
david-cermak May 28, 2024
3fa45ae
bump(wifi_remote): 0.2.1 -> 0.2.2
david-cermak May 28, 2024
3084fae
fix(wifi_remote): Lock server before marshalling events
david-cermak May 30, 2024
6552604
fix(wifi_remote): Fix server event/command race condtion using eventfd
david-cermak May 30, 2024
4cbfa1e
bump(wifi_remote): 0.2.2 -> 0.2.3
david-cermak Jun 5, 2024
520235d
feat(wifi_remote): Make wifi_remote depend on esp_hosted
SohKamYung-Espressif Jun 14, 2024
49acc6d
feat(wifi_remote): add esp_wifi_internal_tx_by_ref
SohKamYung-Espressif Jun 21, 2024
fe5c938
bump(wifi_remote): 0.2.3 -> 0.3.0
david-cermak Jun 24, 2024
50a296a
fix(wifi_remote): Fix checking API compat against reference dir
david-cermak Sep 3, 2024
5c72770
fix(wifi_remote): Update per espressif/esp-idf@27f61966
david-cermak Sep 3, 2024
87b0b76
feat(wifi_remote): Add slave selection and peview targets
david-cermak Sep 3, 2024
60554f2
fix(wifi_remote): Depend on esp_hosted only on targets with no WiFi
david-cermak Sep 3, 2024
4606b2e
feat(wifi_remote): Support for IDF v5.4 via a separate dir
david-cermak Sep 18, 2024
a4dfe7b
fix(wifi_remote): Fix CI builds to generate configs per slave selection
david-cermak Sep 18, 2024
7868b70
feat(wifi_remote): Support for IDF v5.3 in a separate directory
david-cermak Sep 18, 2024
705205b
feat(wifi_remote): Add build test for current IDF examples
david-cermak Sep 18, 2024
9bd9111
fix(wifi_remote): Update per v5.4 espressif/esp-idf@97e42349
david-cermak Sep 24, 2024
81b3d98
fix(wifi_remote): Fix CMake to use inherent IDF build vars
david-cermak Sep 26, 2024
d526186
feat(wifi_remote): Make esp_hosted default RPC library
david-cermak Aug 30, 2024
e1904e2
bump(wifi_remote): 0.3.0 -> 0.4.0
david-cermak Sep 26, 2024
ce18349
fix(ci): Update CI/scripts
david-cermak Oct 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
128 changes: 128 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
name: "esp_wifi_remote: build-tests"

on:
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened, labeled]

jobs:
wifi_remote_api_compat:
name: Check API compatibility of WiFi Remote
strategy:
matrix:
idf_ver: ["latest", "release-v5.3"]
runs-on: ubuntu-20.04
container: espressif/idf:${{ matrix.idf_ver }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Check that headers are the same as generated
shell: bash
run: |
. ${IDF_PATH}/export.sh
pip install idf-component-manager idf-build-apps --upgrade
cp -r ./components/esp_wifi_remote ./components/esp_wifi_remote_base
cd ./components/esp_wifi_remote/scripts
python generate_and_check.py --base-dir ../../esp_wifi_remote_base

build_wifi_remote:
name: Build WiFi Remote Test
strategy:
matrix:
idf_ver: ["latest", "release-v5.3"]
test: [ { app: smoke_test, path: "test/smoke_test" }]
runs-on: ubuntu-20.04
container: espressif/idf:${{ matrix.idf_ver }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Checkout protocols
uses: actions/checkout@v3
with:
repository: espressif/esp-protocols
ref: wifi_remote-v0.4.0
sparse-checkout: |
ci/build_apps.py
ci/ignore_build_warnings.txt
sparse-checkout-cone-mode: false
path: protocols
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: ${{ matrix.idf_ver }}
- name: Build ${{ matrix.test.app }} with IDF-${{ matrix.idf_ver }}
shell: bash
run: |
. ${IDF_PATH}/export.sh
pip install idf-component-manager idf-build-apps --upgrade
python ./components/esp_wifi_remote/scripts/generate_slave_configs.py ./components/esp_wifi_remote/${{matrix.test.path}}
python $GITHUB_WORKSPACE/protocols/ci/build_apps.py ./components/esp_wifi_remote/${{matrix.test.path}} -vv --preserve-all

build_wifi_remote_example:
name: Build WiFi Remote Example
strategy:
matrix:
idf_ver: ["latest"]
example: [ { app: host, path: "examples/mqtt" }, { app: slave, path: "examples/server" }]
include:
- idf_ver: "latest"
example: { app: slave, path: "examples/server" }
warning: "Warning: The smallest app partition is nearly full"

runs-on: ubuntu-20.04
container: espressif/idf:${{ matrix.idf_ver }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Checkout protocols
uses: actions/checkout@v3
with:
repository: espressif/esp-protocols
ref: wifi_remote-v0.4.0
sparse-checkout: |
ci/build_apps.py
ci/ignore_build_warnings.txt
sparse-checkout-cone-mode: false
path: protocols
- name: Build ${{ matrix.example.app }} with IDF-${{ matrix.idf_ver }}
env:
EXPECTED_WARNING: ${{ matrix.warning }}
shell: bash
run: |
. ${IDF_PATH}/export.sh
pip install idf-component-manager idf-build-apps --upgrade
python $GITHUB_WORKSPACE/protocols/ci/build_apps.py ./components/esp_wifi_remote/${{matrix.example.path}} -vv --preserve-all

build_idf_examples_with_wifi_remote:
name: Build IDF examples with WiFi Remote
strategy:
matrix:
idf_ver: ["latest", "release-v5.3"]
idf_target: ["esp32p4", "esp32h2", "esp32s3"]
test: [ { app: idf_mqtt_example, path: "examples/protocols/mqtt/tcp" }]
runs-on: ubuntu-20.04
container: espressif/idf:${{ matrix.idf_ver }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: ${{ matrix.idf_ver }}
- name: Build ${{ matrix.test.app }} with IDF-${{ matrix.idf_ver }} for ${{ matrix.idf_target }}
shell: bash
run: |
. ${IDF_PATH}/export.sh
pip install idf-component-manager idf-build-apps --upgrade
export OVERRIDE_PATH=`pwd`/components/esp_wifi_remote
echo ${OVERRIDE_PATH}
sed -i '/espressif\/esp_wifi_remote:/a \ \ \ \ override_path: "${OVERRIDE_PATH}"' ${IDF_PATH}/${{matrix.test.path}}/main/idf_component.yml
cat ${IDF_PATH}/${{matrix.test.path}}/main/idf_component.yml
export PEDANTIC_FLAGS="-DIDF_CI_BUILD -Werror -Werror=deprecated-declarations -Werror=unused-variable -Werror=unused-but-set-variable -Werror=unused-function"
export EXTRA_CFLAGS="${PEDANTIC_FLAGS} -Wstrict-prototypes"
export EXTRA_CXXFLAGS="${PEDANTIC_FLAGS}"
cd ${IDF_PATH}/${{matrix.test.path}}
idf-build-apps find --config sdkconfig.ci* -vv --target ${{ matrix.idf_target }}
idf-build-apps build --config sdkconfig.ci* -vv --target ${{ matrix.idf_target }}
3 changes: 2 additions & 1 deletion .github/workflows/upload_component.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ jobs:
- name: Upload esp_wifi_remote to IDF Component Registry
uses: espressif/upload-components-ci-action@v1
with:
name: esp_wifi_remote
directories: >
components/console_cmd_wifi;
namespace: "espressif"
api_token: ${{ secrets.IDF_COMPONENT_API_TOKEN }}
8 changes: 8 additions & 0 deletions components/esp_wifi_remote/.cz.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
commitizen:
bump_message: 'bump(wifi_remote): $current_version -> $new_version'
pre_bump_hooks: python ../../ci/changelog.py esp_wifi_remote
tag_format: wifi_remote-v$version
version: 0.4.0
version_files:
- idf_component.yml
66 changes: 66 additions & 0 deletions components/esp_wifi_remote/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# Changelog

## [0.4.0](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.4.0)

### Features

- Make esp_hosted default RPC library ([1b62adbd](https://github.com/espressif/esp-protocols/commit/1b62adbd))
- Add build test for current IDF examples ([50c113e4](https://github.com/espressif/esp-protocols/commit/50c113e4))
- Support for IDF v5.3 in a separate directory ([bde97203](https://github.com/espressif/esp-protocols/commit/bde97203))
- Support for IDF v5.4 via a separate dir ([e9ac41e1](https://github.com/espressif/esp-protocols/commit/e9ac41e1))
- Add slave selection and peview targets ([345c4577](https://github.com/espressif/esp-protocols/commit/345c4577))

### Bug Fixes

- Fix CMake to use inherent IDF build vars ([c454ec09](https://github.com/espressif/esp-protocols/commit/c454ec09))
- Update per v5.4 espressif/esp-idf@97e42349 ([ff5dac70](https://github.com/espressif/esp-protocols/commit/ff5dac70))
- Fix CI builds to generate configs per slave selection ([8795d164](https://github.com/espressif/esp-protocols/commit/8795d164))
- Depend on esp_hosted only on targets with no WiFi ([7ca5ed1d](https://github.com/espressif/esp-protocols/commit/7ca5ed1d))
- Update per espressif/esp-idf@27f61966 ([2e53b81f](https://github.com/espressif/esp-protocols/commit/2e53b81f))
- Fix checking API compat against reference dir ([1a57a878](https://github.com/espressif/esp-protocols/commit/1a57a878))

## [0.3.0](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.3.0)

### Features

- add esp_wifi_internal_tx_by_ref ([ba35d14e](https://github.com/espressif/esp-protocols/commit/ba35d14e))
- Make wifi_remote depend on esp_hosted ([ac9972aa](https://github.com/espressif/esp-protocols/commit/ac9972aa))

## [0.2.3](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.2.3)

### Bug Fixes

- Fix server event/command race condtion using eventfd ([732b1d5](https://github.com/espressif/esp-protocols/commit/732b1d5))
- Lock server before marshalling events ([9e13870](https://github.com/espressif/esp-protocols/commit/9e13870))

## [0.2.2](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.2.2)

### Bug Fixes

- Added more netif options for eppp connection ([24ce867](https://github.com/espressif/esp-protocols/commit/24ce867))
- Do not restrict EPPP config to RSA keys only ([f05c765](https://github.com/espressif/esp-protocols/commit/f05c765), [#570](https://github.com/espressif/esp-protocols/issues/570))

## [0.2.1](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.2.1)

### Bug Fixes

- Added misc wifi API in eppp impl ([93256d1](https://github.com/espressif/esp-protocols/commit/93256d1))
- Updated eppp dependency not to use fixed version ([3a48c06](https://github.com/espressif/esp-protocols/commit/3a48c06))

## [0.2.0](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.2.0)

### Features

- Add support for simple eppp based RPC ([fd168d8](https://github.com/espressif/esp-protocols/commit/fd168d8))

### Bug Fixes

- Make services restartable, code cleanup ([6c82ce2](https://github.com/espressif/esp-protocols/commit/6c82ce2))
- Add examples to CI ([d2b7c55](https://github.com/espressif/esp-protocols/commit/d2b7c55))

## [0.1.12](https://github.com/espressif/esp-protocols/commits/wifi_remote-v0.1.12)

### Features

- Added generation step for wifi_remote based on IDF ([dfb00358](https://github.com/espressif/esp-protocols/commit/dfb00358))
- Move to esp-protocols ([edc3c2d](https://github.com/espressif/esp-protocols/commit/edc3c2d))
22 changes: 22 additions & 0 deletions components/esp_wifi_remote/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
set(IDF_VER_DIR "idf_v${IDF_VERSION_MAJOR}.${IDF_VERSION_MINOR}")

if(NOT CONFIG_ESP_WIFI_ENABLED)
set(src_wifi_is_remote esp_wifi_remote.c ${IDF_VER_DIR}/esp_wifi_with_remote.c esp_wifi_remote_net.c)
endif()

if(CONFIG_ESP_WIFI_REMOTE_LIBRARY_EPPP)
set(src_wifi_remote_eppp eppp/wifi_remote_rpc_client.cpp eppp/wifi_remote_rpc_server.cpp eppp/eppp_init.c)
else()
set(src_wifi_remote_weak ${IDF_VER_DIR}/esp_wifi_remote_weak.c)
endif()

idf_component_register(INCLUDE_DIRS include ${IDF_VER_DIR}/include
SRCS ${src_wifi_remote_weak}
${src_wifi_remote_eppp}
${src_wifi_is_remote}
PRIV_INCLUDE_DIRS eppp
REQUIRES esp_event esp_netif
PRIV_REQUIRES esp_wifi esp-tls vfs)

idf_component_get_property(wifi esp_wifi COMPONENT_LIB)
target_link_libraries(${wifi} PUBLIC ${COMPONENT_LIB})
14 changes: 14 additions & 0 deletions components/esp_wifi_remote/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
menu "Wi-Fi Remote"
config ESP_WIFI_REMOTE_ENABLED
bool
default y

orsource "./idf_v$ESP_IDF_VERSION/Kconfig.slave_select.in"
orsource "./idf_v$ESP_IDF_VERSION/Kconfig.soc_wifi_caps.in"
orsource "./Kconfig.rpc.in"

menu "Wi-Fi configuration"
orsource "./idf_v$ESP_IDF_VERSION/Kconfig.wifi.in"
endmenu

endmenu # Wi-Fi Remote
74 changes: 74 additions & 0 deletions components/esp_wifi_remote/Kconfig.rpc.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
choice ESP_WIFI_REMOTE_LIBRARY
prompt "Choose WiFi-remote implementation"
default ESP_WIFI_REMOTE_LIBRARY_HOSTED
help
Select type of WiFi Remote implementation

ESP-HOSTED is the default and most versatile option.
It's also possible to use EPPP, which uses PPPoS link between micros and NAPT, so it's slower
and less universal.

config ESP_WIFI_REMOTE_LIBRARY_HOSTED
bool "ESP-HOSTED"
config ESP_WIFI_REMOTE_LIBRARY_EPPP
bool "EPPP"
endchoice

if ESP_WIFI_REMOTE_LIBRARY_EPPP

config ESP_WIFI_REMOTE_EPPP_UART_TX_PIN
int "TXD Pin Number"
default 10
range 0 31
help
Pin number of UART TX.

config ESP_WIFI_REMOTE_EPPP_UART_RX_PIN
int "RXD Pin Number"
default 11
range 0 31
help
Pin number of UART RX.

config ESP_WIFI_REMOTE_EPPP_NETIF_PRIORITY
int "Routing priority of eppp netif"
default 100
range 0 256
help
Set the priority of the wifi-remote netif.
The bigger the number the higher the priority.
The interface which is up and with the highest priority will act as a default GW.

config ESP_WIFI_REMOTE_EPPP_NETIF_DESCRIPTION
string "eppp network interface description"
default "example_netif_sta"
help
Textual description of the wifi remote network interface.
By default it is set to "example_netif_sta" to be used in IDF protocol example
as default wifi station substitution.

config ESP_WIFI_REMOTE_EPPP_SERVER_CA
string "Servers CA certificate"
default "--- Please copy content of the CA certificate ---"

config ESP_WIFI_REMOTE_EPPP_CLIENT_CRT
string "Client certificate"
default "--- Please copy content of the Client certificate ---"

config ESP_WIFI_REMOTE_EPPP_CLIENT_KEY
string "Client key"
default "--- Please copy content of the Client key ---"

config ESP_WIFI_REMOTE_EPPP_CLIENT_CA
string "Clients CA certificate"
default "--- Please copy content of the CA certificate ---"

config ESP_WIFI_REMOTE_EPPP_SERVER_CRT
string "Server certificate"
default "--- Please copy content of the Client certificate ---"

config ESP_WIFI_REMOTE_EPPP_SERVER_KEY
string "Server key"
default "--- Please copy content of the Client key ---"

endif
Loading
Loading