From a551133493b9b405a256439f1616e506fe9ce8f4 Mon Sep 17 00:00:00 2001 From: Yakun Xu Date: Fri, 28 Feb 2020 04:55:56 +0800 Subject: [PATCH] [build] rename example platform POSIX to simulation (#4555) Having examples/posix and src/core/posix is confusing. This commit renames the examples posix platform to simulation. --- .travis.yml | 22 ++++---- .travis/before_install.sh | 8 +-- .travis/check-ncp-rcp-migrate | 2 +- .travis/check-posix-app-pty | 2 +- .travis/script.sh | 55 +++++++++---------- Makefile.am | 2 +- configure.ac | 14 ++--- etc/docker/Makefile | 12 ++-- etc/docker/codelab_otsim/Dockerfile | 2 +- etc/docker/ot_sim/Dockerfile | 2 +- etc/docker/ot_sim/README.md | 2 +- etc/docker/ot_sim/start_sim | 2 +- .../{Makefile-posix => Makefile-simulation} | 10 ++-- examples/apps/cli/README.md | 2 +- examples/apps/cli/main.c | 4 +- examples/apps/ncp/main.c | 4 +- examples/platforms/Makefile.am | 8 +-- examples/platforms/Makefile.platform.am | 4 +- .../{posix => simulation}/CMakeLists.txt | 26 ++++----- .../{posix => simulation}/Makefile.am | 21 +++---- .../Makefile.platform.am | 6 +- .../platforms/{posix => simulation}/README.md | 8 +-- .../platforms/{posix => simulation}/alarm.c | 6 +- .../platforms/{posix => simulation}/diag.c | 2 +- .../platforms/{posix => simulation}/entropy.c | 2 +- .../platforms/{posix => simulation}/flash.c | 2 +- .../platforms/{posix => simulation}/logging.c | 2 +- .../platforms/{posix => simulation}/misc.c | 2 +- .../openthread-core-simulation-config.h} | 10 ++-- .../{posix => simulation}/platform-config.h | 20 +++---- .../platform-simulation.h} | 6 +- .../platforms/{posix => simulation}/radio.c | 54 +++++++++--------- .../{posix => simulation}/spi-stubs.c | 4 +- .../platforms/{posix => simulation}/system.c | 6 +- .../{posix/uart-posix.c => simulation/uart.c} | 10 ++-- .../virtual_time}/alarm-sim.c | 6 +- .../virtual_time}/platform-sim.c | 14 ++--- include/openthread/platform/debug_uart.h | 2 +- script/bootstrap | 4 +- script/test | 6 +- src/cli/README.md | 2 +- src/cli/README_COAP.md | 2 +- src/cli/README_COAPS.md | 2 +- src/cli/README_COMMISSIONING.md | 4 +- src/posix/README.md | 2 +- tests/toranj/build.sh | 12 ++-- tests/unit/Makefile.am | 2 +- .../ti/ti-openthread_1.01.0_manifest.html | 8 +-- 48 files changed, 205 insertions(+), 205 deletions(-) rename examples/{Makefile-posix => Makefile-simulation} (96%) rename examples/platforms/{posix => simulation}/CMakeLists.txt (79%) rename examples/platforms/{posix => simulation}/Makefile.am (84%) rename examples/platforms/{posix => simulation}/Makefile.platform.am (92%) rename examples/platforms/{posix => simulation}/README.md (82%) rename examples/platforms/{posix => simulation}/alarm.c (98%) rename examples/platforms/{posix => simulation}/diag.c (98%) rename examples/platforms/{posix => simulation}/entropy.c (99%) rename examples/platforms/{posix => simulation}/flash.c (99%) rename examples/platforms/{posix => simulation}/logging.c (99%) rename examples/platforms/{posix => simulation}/misc.c (98%) rename examples/platforms/{posix/openthread-core-posix-config.h => simulation/openthread-core-simulation-config.h} (94%) rename examples/platforms/{posix => simulation}/platform-config.h (83%) rename examples/platforms/{posix/platform-posix.h => simulation/platform-simulation.h} (98%) rename examples/platforms/{posix => simulation}/radio.c (94%) rename examples/platforms/{posix => simulation}/spi-stubs.c (96%) rename examples/platforms/{posix => simulation}/system.c (97%) rename examples/platforms/{posix/uart-posix.c => simulation/uart.c} (96%) rename examples/platforms/{posix/sim => simulation/virtual_time}/alarm-sim.c (97%) rename examples/platforms/{posix/sim => simulation/virtual_time}/platform-sim.c (95%) diff --git a/.travis.yml b/.travis.yml index e88a0dbd3..cb44dfc6d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -94,23 +94,23 @@ jobs: - env: BUILD_TARGET="gn-build" VERBOSE=1 os: linux script: .travis/script.sh - - env: BUILD_TARGET="posix-distcheck" VERBOSE=1 VIRTUAL_TIME=1 + - env: BUILD_TARGET="simulation-distcheck" VERBOSE=1 VIRTUAL_TIME=1 os: linux compiler: clang script: .travis/script.sh - - env: BUILD_TARGET="posix-32-bit" VERBOSE=1 VIRTUAL_TIME=1 + - env: BUILD_TARGET="simulation-32-bit" VERBOSE=1 VIRTUAL_TIME=1 os: linux compiler: gcc script: .travis/script.sh - - env: BUILD_TARGET="posix-32-bit" VERBOSE=1 VIRTUAL_TIME=1 TIME_SYNC=1 + - env: BUILD_TARGET="simulation-32-bit" VERBOSE=1 VIRTUAL_TIME=1 TIME_SYNC=1 os: linux compiler: gcc script: .travis/script.sh - - env: BUILD_TARGET="posix-ncp" VERBOSE=1 VIRTUAL_TIME=1 + - env: BUILD_TARGET="simulation-ncp" VERBOSE=1 VIRTUAL_TIME=1 os: linux compiler: gcc script: .travis/script.sh - - env: BUILD_TARGET="posix-mtd" VERBOSE=1 VIRTUAL_TIME=1 + - env: BUILD_TARGET="simulation-mtd" VERBOSE=1 VIRTUAL_TIME=1 os: linux compiler: gcc script: .travis/script.sh @@ -144,7 +144,7 @@ jobs: os: linux compiler: gcc script: .travis/script.sh - - env: BUILD_TARGET="posix" CC="gcc-5" CXX="g++-5" + - env: BUILD_TARGET="simulation" CC="gcc-5" CXX="g++-5" os: linux compiler: gcc addons: @@ -153,7 +153,7 @@ jobs: - gcc-5 - g++-5 script: .travis/script.sh - - env: BUILD_TARGET="posix" CC="gcc-6" CXX="g++-6" + - env: BUILD_TARGET="simulation" CC="gcc-6" CXX="g++-6" os: linux compiler: gcc addons: @@ -162,7 +162,7 @@ jobs: - gcc-6 - g++-6 script: .travis/script.sh - - env: BUILD_TARGET="posix" CC="gcc-7" CXX="g++-7" + - env: BUILD_TARGET="simulation" CC="gcc-7" CXX="g++-7" os: linux compiler: gcc addons: @@ -171,7 +171,7 @@ jobs: - gcc-7 - g++-7 script: .travis/script.sh - - env: BUILD_TARGET="posix" CC="gcc-8" CXX="g++-8" + - env: BUILD_TARGET="simulation" CC="gcc-8" CXX="g++-8" os: linux compiler: gcc addons: @@ -180,7 +180,7 @@ jobs: - gcc-8 - g++-8 script: .travis/script.sh - - env: BUILD_TARGET="posix" CC="gcc-9" CXX="g++-9" + - env: BUILD_TARGET="simulation" CC="gcc-9" CXX="g++-9" os: linux compiler: gcc addons: @@ -191,7 +191,7 @@ jobs: - gcc-9 - g++-9 script: .travis/script.sh - - env: BUILD_TARGET="posix-ncp-spi" VERBOSE=1 + - env: BUILD_TARGET="simulation-ncp-spi" VERBOSE=1 os: linux compiler: gcc script: .travis/script.sh diff --git a/.travis/before_install.sh b/.travis/before_install.sh index 66d698a05..4328f3496 100755 --- a/.travis/before_install.sh +++ b/.travis/before_install.sh @@ -48,10 +48,10 @@ cd /tmp || die pip3 install cmake case "${BUILD_TARGET}" in - posix-distcheck|posix-32-bit|posix-app-cli|posix-mtd|posix-ncp|posix-app-ncp|v1.2) + simulation-distcheck|simulation-32-bit|posix-app-cli|simulation-mtd|simulation-ncp|posix-app-ncp|v1.2) pip install --upgrade pip || die pip install -r $TRAVIS_BUILD_DIR/tests/scripts/thread-cert/requirements.txt || die - [ $BUILD_TARGET != posix-ncp -a $BUILD_TARGET != posix-app-ncp ] || { + [ $BUILD_TARGET != simulation-ncp -a $BUILD_TARGET != posix-app-ncp ] || { # Packages used by ncp tools. pip install git+https://github.com/openthread/pyspinel || die } @@ -156,11 +156,11 @@ cd /tmp || die arm-none-eabi-gcc --version || die } - [ $BUILD_TARGET != posix-32-bit -a $BUILD_TARGET != posix-mtd ] || { + [ $BUILD_TARGET != simulation-32-bit -a $BUILD_TARGET != simulation-mtd ] || { sudo apt-get install g++-multilib || die } - [ $BUILD_TARGET != posix-distcheck ] || { + [ $BUILD_TARGET != simulation-distcheck ] || { sudo apt-get install llvm-runtime || die } diff --git a/.travis/check-ncp-rcp-migrate b/.travis/check-ncp-rcp-migrate index 968a35acb..4c0775b7b 100755 --- a/.travis/check-ncp-rcp-migrate +++ b/.travis/check-ncp-rcp-migrate @@ -42,7 +42,7 @@ at_exit() { } build() { - make -f examples/Makefile-posix + make -f examples/Makefile-simulation make -f src/posix/Makefile-posix } diff --git a/.travis/check-posix-app-pty b/.travis/check-posix-app-pty index 747ae314e..656598e83 100755 --- a/.travis/check-posix-app-pty +++ b/.travis/check-posix-app-pty @@ -47,7 +47,7 @@ at_exit() { } build() { - make -f examples/Makefile-posix + make -f examples/Makefile-simulation make -f src/posix/Makefile-posix PLATFORM_NETIF=1 PLATFORM_UDP=1 UDP_FORWARD=0 } diff --git a/.travis/script.sh b/.travis/script.sh index f4b4f8d3a..163026abb 100755 --- a/.travis/script.sh +++ b/.travis/script.sh @@ -80,7 +80,7 @@ python --version || die --enable-mtd \ --enable-ncp \ --enable-radio-only \ - --with-examples=posix || die + --with-examples=simulation || die scan-build --status-bugs -analyze-headers -v make -j2 || die @@ -93,7 +93,7 @@ python --version || die --enable-mtd \ --enable-ncp \ --enable-radio-only \ - --with-examples=posix || die + --with-examples=simulation || die scan-build --status-bugs -analyze-headers -v make -j2 || die } @@ -415,23 +415,23 @@ build_samr21() { build_samr21 } -[ $BUILD_TARGET != posix ] || { +[ $BUILD_TARGET != simulation ] || { git checkout -- . || die git clean -xfd || die mkdir build && cd build || die - cmake -GNinja -DOT_PLATFORM=posix -DOT_COMPILE_WARNING_AS_ERROR=ON .. || die + cmake -GNinja -DOT_PLATFORM=simulation -DOT_COMPILE_WARNING_AS_ERROR=ON .. || die ninja || die cd .. || die git checkout -- . || die git clean -xfd || die ./bootstrap || die - CPPFLAGS=-DOPENTHREAD_CONFIG_LOG_LEVEL=OT_LOG_LEVEL_NONE make -f examples/Makefile-posix || die + CPPFLAGS=-DOPENTHREAD_CONFIG_LOG_LEVEL=OT_LOG_LEVEL_NONE make -f examples/Makefile-simulation || die git checkout -- . || die git clean -xfd || die ./bootstrap || die - CPPFLAGS=-DOPENTHREAD_CONFIG_LOG_LEVEL=OT_LOG_LEVEL_DEBG make -f examples/Makefile-posix || die + CPPFLAGS=-DOPENTHREAD_CONFIG_LOG_LEVEL=OT_LOG_LEVEL_DEBG make -f examples/Makefile-simulation || die export CPPFLAGS=" \ -DOPENTHREAD_CONFIG_ANNOUNCE_SENDER_ENABLE=1 \ @@ -477,7 +477,7 @@ build_samr21() { git checkout -- . || die git clean -xfd || die ./bootstrap || die - make -f examples/Makefile-posix || die + make -f examples/Makefile-simulation || die export CPPFLAGS=" \ -DOPENTHREAD_CONFIG_BORDER_ROUTER_ENABLE=1 \ @@ -494,12 +494,12 @@ build_samr21() { git checkout -- . || die git clean -xfd || die ./bootstrap || die - CPPFLAGS=-DOPENTHREAD_CONFIG_HEAP_EXTERNAL_ENABLE=1 make -f examples/Makefile-posix || die + CPPFLAGS=-DOPENTHREAD_CONFIG_HEAP_EXTERNAL_ENABLE=1 make -f examples/Makefile-simulation || die git checkout -- . || die git clean -xfd || die ./bootstrap || die - CPPFLAGS=-DOPENTHREAD_CONFIG_MAC_RETRY_SUCCESS_HISTOGRAM_ENABLE=1 make -f examples/Makefile-posix || die + CPPFLAGS=-DOPENTHREAD_CONFIG_MAC_RETRY_SUCCESS_HISTOGRAM_ENABLE=1 make -f examples/Makefile-simulation || die git checkout -- . || die git clean -xfd || die @@ -508,7 +508,7 @@ build_samr21() { --enable-ncp \ --enable-ftd \ --enable-mtd \ - --with-examples=posix \ + --with-examples=simulation \ --disable-docs \ --disable-tests \ --with-vendor-extension=./src/core/common/extension_example.cpp || die @@ -520,7 +520,7 @@ build_samr21() { ./configure \ --enable-cli \ --enable-mtd \ - --with-examples=posix \ + --with-examples=simulation \ --disable-docs \ --disable-tests || die make -j 8 || die @@ -539,7 +539,7 @@ build_samr21() { --enable-ftd \ --enable-mtd \ --enable-radio-only \ - --with-examples=posix || die + --with-examples=simulation || die make -j 8 || die export CPPFLAGS=" \ @@ -552,30 +552,30 @@ build_samr21() { --enable-ncp \ --enable-ftd \ --enable-mtd \ - --with-examples=posix \ + --with-examples=simulation \ --disable-docs \ --disable-tests \ --with-ncp-vendor-hook-source=./src/ncp/example_vendor_hook.cpp || die make -j 8 || die } -[ $BUILD_TARGET != posix-distcheck ] || { +[ $BUILD_TARGET != simulation-distcheck ] || { export ASAN_SYMBOLIZER_PATH=`which llvm-symbolizer` || die export ASAN_OPTIONS=symbolize=1 || die - export DISTCHECK_CONFIGURE_FLAGS= CPPFLAGS=-DOPENTHREAD_POSIX_VIRTUAL_TIME=1 || die + export DISTCHECK_CONFIGURE_FLAGS= CPPFLAGS=-DOPENTHREAD_SIMULATION_VIRTUAL_TIME=1 || die ./bootstrap || die - REFERENCE_DEVICE=1 make -f examples/Makefile-posix distcheck || die + REFERENCE_DEVICE=1 make -f examples/Makefile-simulation distcheck || die } -[ $BUILD_TARGET != posix-32-bit ] || { +[ $BUILD_TARGET != simulation-32-bit ] || { ./bootstrap || die - REFERENCE_DEVICE=1 COVERAGE=1 CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 make -f examples/Makefile-posix check || die + REFERENCE_DEVICE=1 COVERAGE=1 CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 make -f examples/Makefile-simulation check || die } [ $BUILD_TARGET != posix-app-cli ] || { ./bootstrap || die # enable code coverage for OpenThread transceiver only - COVERAGE=1 VIRTUAL_TIME_UART=1 make -f examples/Makefile-posix || die + COVERAGE=1 VIRTUAL_TIME_UART=1 make -f examples/Makefile-simulation || die # readline supports pipe, editline does not REFERENCE_DEVICE=1 COVERAGE=1 READLINE=readline make -f src/posix/Makefile-posix || die REFERENCE_DEVICE=1 COVERAGE=1 PYTHONUNBUFFERED=1 OT_CLI_PATH="$(pwd)/$(ls output/posix/*/bin/ot-cli) -v" RADIO_DEVICE="$(pwd)/$(ls output/*/bin/ot-rcp)" make -f src/posix/Makefile-posix check || die @@ -616,22 +616,21 @@ build_samr21() { .travis/check-ncp-rcp-migrate || die } -[ $BUILD_TARGET != posix-mtd ] || { +[ $BUILD_TARGET != simulation-mtd ] || { ./bootstrap || die - REFERENCE_DEVICE=1 COVERAGE=1 CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 USE_MTD=1 make -f examples/Makefile-posix check || die + REFERENCE_DEVICE=1 COVERAGE=1 CFLAGS=-m32 CXXFLAGS=-m32 LDFLAGS=-m32 USE_MTD=1 make -f examples/Makefile-simulation check || die } -[ $BUILD_TARGET != posix-ncp-spi ] || { +[ $BUILD_TARGET != simulation-ncp-spi ] || { CPPFLAGS="-DOPENTHREAD_CONFIG_NCP_SPI_ENABLE=1" ./bootstrap || die - make -f examples/Makefile-posix check configure_OPTIONS="--enable-ncp --enable-ftd --with-examples=posix" || die + make -f examples/Makefile-simulation check configure_OPTIONS="--enable-ncp --enable-ftd --with-examples=simulation" || die } [ $BUILD_TARGET != posix-app-ncp ] || { ./bootstrap || die - REFERENCE_DEVICE=1 COVERAGE=1 VIRTUAL_TIME_UART=1 make -f examples/Makefile-posix || die - # enable code coverage for OpenThread posix radio + REFERENCE_DEVICE=1 COVERAGE=1 VIRTUAL_TIME_UART=1 make -f examples/Makefile-simulation || die REFERENCE_DEVICE=1 COVERAGE=1 READLINE=readline make -f src/posix/Makefile-posix || die REFERENCE_DEVICE=1 COVERAGE=1 PYTHONUNBUFFERED=1 OT_NCP_PATH="$(pwd)/$(ls output/posix/*/bin/ot-ncp)" RADIO_DEVICE="$(pwd)/$(ls output/*/bin/ot-rcp)" NODE_TYPE=ncp-sim make -f src/posix/Makefile-posix check || die } @@ -641,9 +640,9 @@ build_samr21() { REFERENCE_DEVICE=1 READLINE=readline RCP_SPI=1 make -f src/posix/Makefile-posix || die } -[ $BUILD_TARGET != posix-ncp ] || { +[ $BUILD_TARGET != simulation-ncp ] || { ./bootstrap || die - REFERENCE_DEVICE=1 COVERAGE=1 PYTHONUNBUFFERED=1 NODE_TYPE=ncp-sim make -f examples/Makefile-posix check || die + REFERENCE_DEVICE=1 COVERAGE=1 PYTHONUNBUFFERED=1 NODE_TYPE=ncp-simulation make -f examples/Makefile-simulation check || die } [ $BUILD_TARGET != toranj-test-framework ] || { @@ -654,7 +653,7 @@ build_samr21() { git checkout -- . || die git clean -xfd || die ./bootstrap || die - make -f examples/Makefile-posix || die + make -f examples/Makefile-simulation || die git checkout -- . || die git clean -xfd || die diff --git a/Makefile.am b/Makefile.am index 2073c16fa..471ca4e72 100644 --- a/Makefile.am +++ b/Makefile.am @@ -37,7 +37,7 @@ AM_DISTCHECK_CONFIGURE_FLAGS = \ --enable-mtd \ --enable-ncp \ --enable-radio-only \ - --with-examples=posix \ + --with-examples=simulation \ $(NULL) SUBDIRS = \ diff --git a/configure.ac b/configure.ac index e1869f439..739ad6fce 100644 --- a/configure.ac +++ b/configure.ac @@ -828,7 +828,7 @@ AC_MSG_CHECKING([whether to build examples]) AC_ARG_WITH(examples, [AS_HELP_STRING([--with-examples=TARGET], - [Build example applications for one of: posix, cc1352, cc2538, cc2650, cc2652, efr32mg12, efr32mg13, efr32mg21, + [Build example applications for one of: simulation, cc1352, cc2538, cc2650, cc2652, efr32mg12, efr32mg13, efr32mg21, gp712, kw41z, nrf52811, nrf52833, nrf52840, qpg6095, samr21 @<:@default=no@:>@. Note that building example applications also builds the associated OpenThread platform libraries and any third_party libraries needed to support the examples.])], @@ -836,7 +836,7 @@ AC_ARG_WITH(examples, case "${with_examples}" in no) ;; - posix|cc1352|cc2538|cc2650|cc2652|efr32mg12|efr32mg13|efr32mg21|gp712|kw41z|nrf52811|nrf52833|nrf52840|qpg6095|samr21) + simulation|cc1352|cc2538|cc2650|cc2652|efr32mg12|efr32mg13|efr32mg21|gp712|kw41z|nrf52811|nrf52833|nrf52840|qpg6095|samr21) if test ${enable_posix_app} = "yes"; then AC_MSG_RESULT(ERROR) AC_MSG_ERROR([--with-examples must be no when POSIX apps are enabled by --enable-posix-app]) @@ -852,7 +852,7 @@ AC_ARG_WITH(examples, AM_CONDITIONAL([OPENTHREAD_ENABLE_EXAMPLES], [test ${with_examples} != "no"]) -AM_CONDITIONAL([OPENTHREAD_EXAMPLES_POSIX], [test "${with_examples}" = "posix"]) +AM_CONDITIONAL([OPENTHREAD_EXAMPLES_SIMULATION],[test "${with_examples}" = "simulation"]) AM_CONDITIONAL([OPENTHREAD_EXAMPLES_CC1352], [test "${with_examples}" = "cc1352"]) AM_CONDITIONAL([OPENTHREAD_EXAMPLES_CC2538], [test "${with_examples}" = "cc2538"]) AM_CONDITIONAL([OPENTHREAD_EXAMPLES_CC2650], [test "${with_examples}" = "cc2650"]) @@ -868,7 +868,7 @@ AM_CONDITIONAL([OPENTHREAD_EXAMPLES_NRF52840], [test "${with_examples}" = "nrf5 AM_CONDITIONAL([OPENTHREAD_EXAMPLES_QPG6095], [test "${with_examples}" = "qpg6095"]) AM_CONDITIONAL([OPENTHREAD_EXAMPLES_SAMR21], [test "${with_examples}" = "samr21"]) -AM_COND_IF([OPENTHREAD_EXAMPLES_POSIX], CPPFLAGS="${CPPFLAGS} -DOPENTHREAD_EXAMPLES_POSIX=1", CPPFLAGS="${CPPFLAGS} -DOPENTHREAD_EXAMPLES_POSIX=0") +AM_COND_IF([OPENTHREAD_EXAMPLES_SIMULATION], CPPFLAGS="${CPPFLAGS} -DOPENTHREAD_EXAMPLES_SIMULATION=1", CPPFLAGS="${CPPFLAGS} -DOPENTHREAD_EXAMPLES_SIMULATION=0") AM_CONDITIONAL([OPENTHREAD_EXAMPLES_NRF528XX], [test OPENTHREAD_EXAMPLES_NRF52811 || test OPENTHREAD_EXAMPLES_NRF52833 || test OPENTHREAD_EXAMPLES_NRF52840]) @@ -925,7 +925,7 @@ AM_CONDITIONAL([OPENTHREAD_ENABLE_PLATFORM], [test ${with_platform} != "no"]) OPENTHREAD_ENABLE_PLATFORM=${with_platform} -AM_CONDITIONAL([OPENTHREAD_PLATFORM_POSIX], [test "${with_platform}" = "posix"]) +AM_CONDITIONAL([OPENTHREAD_PLATFORM_SIMULATION],[test "${with_platform}" = "simulation"]) AM_CONDITIONAL([OPENTHREAD_PLATFORM_CC1352], [test "${with_platform}" = "cc1352"]) AM_CONDITIONAL([OPENTHREAD_PLATFORM_CC2538], [test "${with_platform}" = "cc2538"]) AM_CONDITIONAL([OPENTHREAD_PLATFORM_CC2650], [test "${with_platform}" = "cc2650"]) @@ -988,7 +988,7 @@ NL_ENABLE_DOCS([auto],[NO]) AM_CONDITIONAL(OPENTHREAD_BUILD_DOCS, [test "${nl_cv_build_docs}" = "yes"]) -AM_CONDITIONAL(OPENTHREAD_POSIX, [test "${enable_posix_app}" = "yes" -o "${with_examples}" = "posix"]) +AM_CONDITIONAL(OPENTHREAD_POSIX, [test "${enable_posix_app}" = "yes" -o "${with_examples}" = "simulation"]) # # Checks for libraries and packages. @@ -1099,7 +1099,7 @@ examples/platforms/kw41z/Makefile examples/platforms/nrf528xx/Makefile examples/platforms/qpg6095/Makefile examples/platforms/samr21/Makefile -examples/platforms/posix/Makefile +examples/platforms/simulation/Makefile examples/platforms/utils/Makefile tools/Makefile tools/harness-automation/Makefile diff --git a/etc/docker/Makefile b/etc/docker/Makefile index 1d105a96a..5e83df2a3 100644 --- a/etc/docker/Makefile +++ b/etc/docker/Makefile @@ -1,7 +1,7 @@ VERSION=0.1 -all: arm32v7_linux x86_linux sim +all: arm32v7_linux x86_linux simulation arm32v7_linux: arm32v7_ubuntu_wpantund docker build -t openthread/wpantund_arm32v7_linux arm32v7_ubuntu_wpantund && \ @@ -15,11 +15,11 @@ x86_linux: x86_ubuntu_wpantund docker tag openthread/wpantund_amd64_linux openthread/wpantund_amd64_linux:$(VERSION) && \ docker push openthread/wpantund_amd64_linux:$(VERSION) -sim: ot_sim - docker build -t openthread/sim ot_sim && \ - docker push openthread/sim && \ - docker tag openthread/sim openthread/sim:$(VERSION) && \ - docker push openthread/sim:$(VERSION) +simulation: ot_simulation + docker build -t openthread/simulation ot_sim && \ + docker push openthread/simulation && \ + docker tag openthread/simulation openthread/simulation:$(VERSION) && \ + docker push openthread/simulation:$(VERSION) publish_manifest: docker manifest create openthread/wpantund openthread/wpantund_arm32v7_linux openthread/wpantund_amd64_linux diff --git a/etc/docker/codelab_otsim/Dockerfile b/etc/docker/codelab_otsim/Dockerfile index 14c01ce7c..e8e470d74 100644 --- a/etc/docker/codelab_otsim/Dockerfile +++ b/etc/docker/codelab_otsim/Dockerfile @@ -36,4 +36,4 @@ RUN cd ~/src && \ git clone --recursive https://github.com/openthread/openthread.git && \ cd openthread && \ ./bootstrap && \ - make -f examples/Makefile-posix + make -f examples/Makefile-simulation diff --git a/etc/docker/ot_sim/Dockerfile b/etc/docker/ot_sim/Dockerfile index 4387603c3..26984ccfb 100644 --- a/etc/docker/ot_sim/Dockerfile +++ b/etc/docker/ot_sim/Dockerfile @@ -7,7 +7,7 @@ RUN apk add -U autoconf automake ca-certificates flex git g++ libtool linux-head RUN git clone --recursive https://github.com/openthread/openthread.git && \ cd /openthread && \ ./bootstrap && \ - make -f examples/Makefile-posix + make -f examples/Makefile-simulation FROM alpine:3.6 diff --git a/etc/docker/ot_sim/README.md b/etc/docker/ot_sim/README.md index 6fb47916f..b329a1705 100644 --- a/etc/docker/ot_sim/README.md +++ b/etc/docker/ot_sim/README.md @@ -3,7 +3,7 @@ To start the OpenThread simulator, run: ``` -docker run --rm -d --name otsim openthread/sim tail -F /dev/null +docker run --rm -d --name otsim openthread/simulation tail -F /dev/null ``` or ``` diff --git a/etc/docker/ot_sim/start_sim b/etc/docker/ot_sim/start_sim index ad774917d..485d0dad3 100755 --- a/etc/docker/ot_sim/start_sim +++ b/etc/docker/ot_sim/start_sim @@ -1,2 +1,2 @@ #!/bin/bash -docker run --rm -d --name otsim openthread/sim tail -F /dev/null +docker run --rm -d --name otsim openthread/simulation tail -F /dev/null diff --git a/examples/Makefile-posix b/examples/Makefile-simulation similarity index 96% rename from examples/Makefile-posix rename to examples/Makefile-simulation index 85b32ca6d..2ee983eed 100644 --- a/examples/Makefile-posix +++ b/examples/Makefile-simulation @@ -73,7 +73,7 @@ configure_OPTIONS = \ --enable-mtd \ --enable-ncp \ --enable-radio-only \ - --with-examples=posix \ + --with-examples=simulation \ $(NULL) # Platform specific switches @@ -91,11 +91,11 @@ COMMONCFLAGS += -DOPENTHREAD_CONFIG_NCP_UART_ENABLE=1 endif # NCP_SPI == 1 ifeq ($(VIRTUAL_TIME),1) -COMMONCFLAGS += -DOPENTHREAD_POSIX_VIRTUAL_TIME=1 +COMMONCFLAGS += -DOPENTHREAD_SIMULATION_VIRTUAL_TIME=1 endif ifeq ($(VIRTUAL_TIME_UART),1) -COMMONCFLAGS += -DOPENTHREAD_POSIX_VIRTUAL_TIME_UART=1 +COMMONCFLAGS += -DOPENTHREAD_SIMULATION_VIRTUAL_TIME_UART=1 endif include $(dir $(abspath $(lastword $(MAKEFILE_LIST))))/common-switches.mk @@ -103,8 +103,8 @@ include $(dir $(abspath $(lastword $(MAKEFILE_LIST))))/common-switches.mk TopSourceDir := $(dir $(shell readlink $(firstword $(MAKEFILE_LIST)))).. AbsTopSourceDir := $(dir $(realpath $(firstword $(MAKEFILE_LIST)))).. -CONFIG_FILE = OPENTHREAD_PROJECT_CORE_CONFIG_FILE='\"openthread-core-posix-config.h\"' -CONFIG_FILE_PATH = $(AbsTopSourceDir)/examples/platforms/posix/ +CONFIG_FILE = OPENTHREAD_PROJECT_CORE_CONFIG_FILE='\"openthread-core-simulation-config.h\"' +CONFIG_FILE_PATH = $(AbsTopSourceDir)/examples/platforms/simulation/ COMMONCFLAGS += \ -D$(CONFIG_FILE) \ -I$(CONFIG_FILE_PATH) \ diff --git a/examples/apps/cli/README.md b/examples/apps/cli/README.md index 8ba05bc2a..4d95b086f 100644 --- a/examples/apps/cli/README.md +++ b/examples/apps/cli/README.md @@ -7,7 +7,7 @@ This example application exposes OpenThread configuration and management APIs vi ```bash $ cd $ ./bootstrap -$ make -f examples/Makefile-posix +$ make -f examples/Makefile-simulation ``` ## 2. Start node 1 diff --git a/examples/apps/cli/main.c b/examples/apps/cli/main.c index 934b4a5db..5257df5b6 100644 --- a/examples/apps/cli/main.c +++ b/examples/apps/cli/main.c @@ -37,7 +37,7 @@ #include "openthread-system.h" -#if OPENTHREAD_EXAMPLES_POSIX +#if OPENTHREAD_EXAMPLES_SIMULATION #include #include @@ -71,7 +71,7 @@ int main(int argc, char *argv[]) { otInstance *instance; -#if OPENTHREAD_EXAMPLES_POSIX +#if OPENTHREAD_EXAMPLES_SIMULATION if (setjmp(gResetJump)) { alarm(0); diff --git a/examples/apps/ncp/main.c b/examples/apps/ncp/main.c index 8fdd54427..8ff7912b5 100644 --- a/examples/apps/ncp/main.c +++ b/examples/apps/ncp/main.c @@ -36,7 +36,7 @@ #include "openthread-system.h" -#if OPENTHREAD_EXAMPLES_POSIX +#if OPENTHREAD_EXAMPLES_SIMULATION #include #include @@ -70,7 +70,7 @@ int main(int argc, char *argv[]) { otInstance *instance; -#if OPENTHREAD_EXAMPLES_POSIX +#if OPENTHREAD_EXAMPLES_SIMULATION if (setjmp(gResetJump)) { alarm(0); diff --git a/examples/platforms/Makefile.am b/examples/platforms/Makefile.am index 82d9b2465..212646e31 100644 --- a/examples/platforms/Makefile.am +++ b/examples/platforms/Makefile.am @@ -41,7 +41,7 @@ DIST_SUBDIRS = \ gp712 \ kw41z \ nrf528xx \ - posix \ + simulation \ qpg6095 \ samr21 \ utils \ @@ -93,8 +93,8 @@ if OPENTHREAD_PLATFORM_NRF528XX SUBDIRS += nrf528xx endif -if OPENTHREAD_PLATFORM_POSIX -SUBDIRS += posix +if OPENTHREAD_PLATFORM_SIMULATION +SUBDIRS += simulation endif if OPENTHREAD_PLATFORM_QPG6095 @@ -122,7 +122,7 @@ PRETTY_SUBDIRS = \ gp712 \ kw41z \ nrf528xx \ - posix \ + simulation \ qpg6095 \ samr21 \ utils \ diff --git a/examples/platforms/Makefile.platform.am b/examples/platforms/Makefile.platform.am index 2fd657e5b..c2c9f91a9 100644 --- a/examples/platforms/Makefile.platform.am +++ b/examples/platforms/Makefile.platform.am @@ -97,6 +97,6 @@ if OPENTHREAD_EXAMPLES_SAMR21 include $(top_srcdir)/examples/platforms/samr21/Makefile.platform.am endif # OPENTHREAD_EXAMPLES_SAMR21 -if OPENTHREAD_EXAMPLES_POSIX -include $(top_srcdir)/examples/platforms/posix/Makefile.platform.am +if OPENTHREAD_EXAMPLES_SIMULATION +include $(top_srcdir)/examples/platforms/simulation/Makefile.platform.am endif diff --git a/examples/platforms/posix/CMakeLists.txt b/examples/platforms/simulation/CMakeLists.txt similarity index 79% rename from examples/platforms/posix/CMakeLists.txt rename to examples/platforms/simulation/CMakeLists.txt index 0a7f896cd..889f26891 100644 --- a/examples/platforms/posix/CMakeLists.txt +++ b/examples/platforms/simulation/CMakeLists.txt @@ -26,17 +26,17 @@ # POSSIBILITY OF SUCH DAMAGE. # -set(OT_PLATFORM_LIB "openthread-posix" PARENT_SCOPE) +set(OT_PLATFORM_LIB "openthread-simulation" PARENT_SCOPE) if(NOT OT_CONFIG) - set(OT_CONFIG "openthread-core-posix-config.h") + set(OT_CONFIG "openthread-core-simulation-config.h") set(OT_CONFIG ${OT_CONFIG} PARENT_SCOPE) endif() list(APPEND OT_PLATFORM_DEFINES "_BSD_SOURCE=1" "_DEFAULT_SOURCE=1" - "OPENTHREAD_EXAMPLES_POSIX=1" + "OPENTHREAD_EXAMPLES_SIMULATION=1" "OPENTHREAD_POSIX=1" "OPENTHREAD_CONFIG_NCP_UART_ENABLE=1" ) @@ -44,7 +44,7 @@ set(OT_PLATFORM_DEFINES ${OT_PLATFORM_DEFINES} PARENT_SCOPE) list(APPEND OT_PLATFORM_DEFINES "OPENTHREAD_PROJECT_CORE_CONFIG_FILE=\"${OT_CONFIG}\"") -add_library(openthread-posix +add_library(openthread-simulation alarm.c diag.c entropy.c @@ -54,28 +54,28 @@ add_library(openthread-posix radio.c spi-stubs.c system.c - uart-posix.c - sim/alarm-sim.c - sim/platform-sim.c + uart.c + virtual_time/alarm-sim.c + virtual_time/platform-sim.c $ ) -set_property(TARGET openthread-posix PROPERTY C_STANDARD 99) +set_property(TARGET openthread-simulation PROPERTY C_STANDARD 99) find_library(LIBRT rt) if(LIBRT) - target_link_libraries(openthread-posix PRIVATE ${LIBRT}) + target_link_libraries(openthread-simulation PRIVATE ${LIBRT}) endif() -target_link_libraries(openthread-posix PRIVATE openthread-platform-utils) +target_link_libraries(openthread-simulation PRIVATE openthread-platform-utils) -target_compile_definitions(openthread-posix PUBLIC ${OT_PLATFORM_DEFINES}) +target_compile_definitions(openthread-simulation PUBLIC ${OT_PLATFORM_DEFINES}) -target_compile_options(openthread-posix PRIVATE +target_compile_options(openthread-simulation PRIVATE ${OT_CFLAGS} ) -target_include_directories(openthread-posix PRIVATE +target_include_directories(openthread-simulation PRIVATE ${OT_PUBLIC_INCLUDES} ${OT_PRIVATE_INCLUDES} ${PROJECT_SOURCE_DIR}/examples/platforms diff --git a/examples/platforms/posix/Makefile.am b/examples/platforms/simulation/Makefile.am similarity index 84% rename from examples/platforms/posix/Makefile.am rename to examples/platforms/simulation/Makefile.am index fe9e3dca3..a62d0232f 100644 --- a/examples/platforms/posix/Makefile.am +++ b/examples/platforms/simulation/Makefile.am @@ -28,9 +28,9 @@ include $(abs_top_nlbuild_autotools_dir)/automake/pre.am -lib_LIBRARIES = libopenthread-posix.a +lib_LIBRARIES = libopenthread-simulation.a -libopenthread_posix_a_CPPFLAGS = \ +libopenthread_simulation_a_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/examples/platforms \ -I$(top_srcdir)/src/core \ @@ -44,17 +44,18 @@ PLATFORM_SOURCES = \ flash.c \ logging.c \ misc.c \ - openthread-core-posix-config.h \ - platform-posix.h \ + openthread-core-simulation-config.h \ + platform-config.h \ + platform-simulation.h \ radio.c \ spi-stubs.c \ system.c \ - uart-posix.c \ - sim/alarm-sim.c \ - sim/platform-sim.c \ + uart.c \ + virtual_time/alarm-sim.c \ + virtual_time/platform-sim.c \ $(NULL) -libopenthread_posix_a_SOURCES = \ +libopenthread_simulation_a_SOURCES = \ $(PLATFORM_SOURCES) \ $(NULL) @@ -63,11 +64,11 @@ PRETTY_FILES = \ $(NULL) Dash = - -libopenthread_posix_a_LIBADD = \ +libopenthread_simulation_a_LIBADD = \ $(shell find $(top_builddir)/examples/platforms/utils $(Dash)type f $(Dash)name "*.o") if OPENTHREAD_BUILD_COVERAGE -libopenthread_posix_a_CPPFLAGS += \ +libopenthread_simulation_a_CPPFLAGS += \ -DOPENTHREAD_ENABLE_COVERAGE \ $(NULL) diff --git a/examples/platforms/posix/Makefile.platform.am b/examples/platforms/simulation/Makefile.platform.am similarity index 92% rename from examples/platforms/posix/Makefile.platform.am rename to examples/platforms/simulation/Makefile.platform.am index b875e6325..d2cb725a9 100644 --- a/examples/platforms/posix/Makefile.platform.am +++ b/examples/platforms/simulation/Makefile.platform.am @@ -27,11 +27,11 @@ # # -# posix platform-specific Makefile +# Simulation platform-specific Makefile # -LDADD_COMMON += \ - $(top_builddir)/examples/platforms/posix/libopenthread-posix.a \ +LDADD_COMMON += \ + $(top_builddir)/examples/platforms/simulation/libopenthread-simulation.a \ $(NULL) if OPENTHREAD_TARGET_LINUX diff --git a/examples/platforms/posix/README.md b/examples/platforms/simulation/README.md similarity index 82% rename from examples/platforms/posix/README.md rename to examples/platforms/simulation/README.md index 7f4bae0e6..cc3bdb6f5 100644 --- a/examples/platforms/posix/README.md +++ b/examples/platforms/simulation/README.md @@ -1,6 +1,6 @@ -# OpenThread on POSIX Emulation Example +# OpenThread Simulation on POSIX -This directory contains example platform drivers for POSIX emulation. +This directory contains example platform drivers for simulation on POSIX. ## Build Examples @@ -9,7 +9,7 @@ This directory contains example platform drivers for POSIX emulation. ```bash $ cd $ ./bootstrap -$ make -f examples/Makefile-posix +$ make -f examples/Makefile-simulation ``` After a successful build, the `elf` files are found in: @@ -21,7 +21,7 @@ After a successful build, the `elf` files are found in: ```bash $ cd $ mkdir build && cd build -$ cmake -GNinja -DOT_PLATFORM=posix .. +$ cmake -GNinja -DOT_PLATFORM=simulation .. $ ninja ``` diff --git a/examples/platforms/posix/alarm.c b/examples/platforms/simulation/alarm.c similarity index 98% rename from examples/platforms/posix/alarm.c rename to examples/platforms/simulation/alarm.c index 808b2e654..236f1c46d 100644 --- a/examples/platforms/posix/alarm.c +++ b/examples/platforms/simulation/alarm.c @@ -26,9 +26,9 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 #include #include @@ -316,4 +316,4 @@ uint16_t otPlatTimeGetXtalAccuracy(void) } #endif -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 diff --git a/examples/platforms/posix/diag.c b/examples/platforms/simulation/diag.c similarity index 98% rename from examples/platforms/posix/diag.c rename to examples/platforms/simulation/diag.c index b3cade987..ddb8c2659 100644 --- a/examples/platforms/posix/diag.c +++ b/examples/platforms/simulation/diag.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include diff --git a/examples/platforms/posix/entropy.c b/examples/platforms/simulation/entropy.c similarity index 99% rename from examples/platforms/posix/entropy.c rename to examples/platforms/simulation/entropy.c index 815f11393..bcb04a420 100644 --- a/examples/platforms/posix/entropy.c +++ b/examples/platforms/simulation/entropy.c @@ -32,7 +32,7 @@ * */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include diff --git a/examples/platforms/posix/flash.c b/examples/platforms/simulation/flash.c similarity index 99% rename from examples/platforms/posix/flash.c rename to examples/platforms/simulation/flash.c index 2df47dff8..060c02f2f 100644 --- a/examples/platforms/posix/flash.c +++ b/examples/platforms/simulation/flash.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include diff --git a/examples/platforms/posix/logging.c b/examples/platforms/simulation/logging.c similarity index 99% rename from examples/platforms/posix/logging.c rename to examples/platforms/simulation/logging.c index 21f3e590c..007a94369 100644 --- a/examples/platforms/posix/logging.c +++ b/examples/platforms/simulation/logging.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include diff --git a/examples/platforms/posix/misc.c b/examples/platforms/simulation/misc.c similarity index 98% rename from examples/platforms/posix/misc.c rename to examples/platforms/simulation/misc.c index 35fe8b6fc..aefbca5de 100644 --- a/examples/platforms/posix/misc.c +++ b/examples/platforms/simulation/misc.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include diff --git a/examples/platforms/posix/openthread-core-posix-config.h b/examples/platforms/simulation/openthread-core-simulation-config.h similarity index 94% rename from examples/platforms/posix/openthread-core-posix-config.h rename to examples/platforms/simulation/openthread-core-simulation-config.h index 465c69b22..6d801827a 100644 --- a/examples/platforms/posix/openthread-core-posix-config.h +++ b/examples/platforms/simulation/openthread-core-simulation-config.h @@ -28,12 +28,12 @@ /** * @file - * This file includes posix compile-time configuration constants + * This file includes simulation compile-time configuration constants * for OpenThread. */ -#ifndef OPENTHREAD_CORE_POSIX_CONFIG_H_ -#define OPENTHREAD_CORE_POSIX_CONFIG_H_ +#ifndef OPENTHREAD_CORE_SIMULATION_CONFIG_H_ +#define OPENTHREAD_CORE_SIMULATION_CONFIG_H_ #ifndef OPENTHREAD_RADIO #define OPENTHREAD_RADIO 0 @@ -45,7 +45,7 @@ * The platform-specific string to insert into the OpenThread version string. * */ -#define OPENTHREAD_CONFIG_PLATFORM_INFO "POSIX" +#define OPENTHREAD_CONFIG_PLATFORM_INFO "SIMULATION" /** * @def OPENTHREAD_CONFIG_LOG_OUTPUT @@ -145,4 +145,4 @@ #define OPENTHREAD_CONFIG_PARENT_SEARCH_ENABLE 1 #endif -#endif // OPENTHREAD_CORE_POSIX_CONFIG_H_ +#endif // OPENTHREAD_CORE_SIMULATION_CONFIG_H_ diff --git a/examples/platforms/posix/platform-config.h b/examples/platforms/simulation/platform-config.h similarity index 83% rename from examples/platforms/posix/platform-config.h rename to examples/platforms/simulation/platform-config.h index d7fc98d72..11f446ff4 100644 --- a/examples/platforms/posix/platform-config.h +++ b/examples/platforms/simulation/platform-config.h @@ -33,33 +33,33 @@ */ /** - * @def OPENTHREAD_POSIX_UART_BAUDRATE + * @def OPENTHREAD_SIMULATION_UART_BAUDRATE * * This setting configures the baud rate of the UART. * */ -#ifndef OPENTHREAD_POSIX_UART_BAUDRATE -#define OPENTHREAD_POSIX_UART_BAUDRATE B115200 +#ifndef OPENTHREAD_SIMULATION_UART_BAUDRATE +#define OPENTHREAD_SIMULATION_UART_BAUDRATE B115200 #endif /** - * @def OPENTHREAD_POSIX_VIRTUAL_TIME + * @def OPENTHREAD_SIMULATION_VIRTUAL_TIME * - * This setting configures whether to use virtual time (used for simulation) in POSIX platform. + * This setting configures whether to use virtual time (used for simulation) in simulation platform. * */ -#ifndef OPENTHREAD_POSIX_VIRTUAL_TIME -#define OPENTHREAD_POSIX_VIRTUAL_TIME 0 +#ifndef OPENTHREAD_SIMULATION_VIRTUAL_TIME +#define OPENTHREAD_SIMULATION_VIRTUAL_TIME 0 #endif /** - * @def OPENTHREAD_POSIX_VIRTUAL_TIME_UART + * @def OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART * * This setting configures whether to use virtual time for UART. * */ -#ifndef OPENTHREAD_POSIX_VIRTUAL_TIME_UART -#define OPENTHREAD_POSIX_VIRTUAL_TIME_UART 0 +#ifndef OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART +#define OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART 0 #endif /** diff --git a/examples/platforms/posix/platform-posix.h b/examples/platforms/simulation/platform-simulation.h similarity index 98% rename from examples/platforms/posix/platform-posix.h rename to examples/platforms/simulation/platform-simulation.h index 4829bf0b7..0cf363b2b 100644 --- a/examples/platforms/posix/platform-posix.h +++ b/examples/platforms/simulation/platform-simulation.h @@ -32,8 +32,8 @@ * This file includes the platform-specific initializers. */ -#ifndef PLATFORM_POSIX_H_ -#define PLATFORM_POSIX_H_ +#ifndef PLATFORM_SIMULATION_H_ +#define PLATFORM_SIMULATION_H_ #include #include @@ -230,4 +230,4 @@ void otSimSendUartWriteEvent(const uint8_t *aData, uint16_t aLength); */ bool platformRadioIsTransmitPending(void); -#endif // PLATFORM_POSIX_H_ +#endif // PLATFORM_SIMULATION_H_ diff --git a/examples/platforms/posix/radio.c b/examples/platforms/simulation/radio.c similarity index 94% rename from examples/platforms/posix/radio.c rename to examples/platforms/simulation/radio.c index 5d1d6f44b..4147bfc57 100644 --- a/examples/platforms/posix/radio.c +++ b/examples/platforms/simulation/radio.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include @@ -56,14 +56,14 @@ enum enum { - POSIX_RECEIVE_SENSITIVITY = -100, // dBm + SIM_RECEIVE_SENSITIVITY = -100, // dBm - POSIX_HIGH_RSSI_SAMPLE = -30, // dBm - POSIX_LOW_RSSI_SAMPLE = -98, // dBm - POSIX_HIGH_RSSI_PROB_INC_PER_CHANNEL = 5, + SIM_HIGH_RSSI_SAMPLE = -30, // dBm + SIM_LOW_RSSI_SAMPLE = -98, // dBm + SIM_HIGH_RSSI_PROB_INC_PER_CHANNEL = 5, }; -#if OPENTHREAD_POSIX_VIRTUAL_TIME +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME extern int sSockFd; extern uint16_t sPortOffset; #else @@ -75,8 +75,8 @@ static uint16_t sPort = 0; enum { - POSIX_RADIO_CHANNEL_MIN = OT_RADIO_2P4GHZ_OQPSK_CHANNEL_MIN, - POSIX_RADIO_CHANNEL_MAX = OT_RADIO_2P4GHZ_OQPSK_CHANNEL_MAX, + SIM_RADIO_CHANNEL_MIN = OT_RADIO_2P4GHZ_OQPSK_CHANNEL_MIN, + SIM_RADIO_CHANNEL_MAX = OT_RADIO_2P4GHZ_OQPSK_CHANNEL_MAX, }; OT_TOOL_PACKED_BEGIN @@ -226,7 +226,7 @@ void otPlatRadioSetPromiscuous(otInstance *aInstance, bool aEnable) sPromiscuous = aEnable; } -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 static void initFds(void) { int fd; @@ -290,11 +290,11 @@ exit: exit(EXIT_FAILURE); } } -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 void platformRadioInit(void) { -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 char *offset; offset = getenv("PORT_OFFSET"); @@ -315,7 +315,7 @@ void platformRadioInit(void) } initFds(); -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 sReceiveFrame.mPsdu = sReceiveMessage.mPsdu; sTransmitFrame.mPsdu = sTransmitMessage.mPsdu; @@ -417,21 +417,21 @@ int8_t otPlatRadioGetRssi(otInstance *aInstance) { assert(aInstance != NULL); - int8_t rssi = POSIX_LOW_RSSI_SAMPLE; + int8_t rssi = SIM_LOW_RSSI_SAMPLE; uint8_t channel = sReceiveFrame.mChannel; uint32_t probabilityThreshold; - otEXPECT((POSIX_RADIO_CHANNEL_MIN <= channel) && channel <= (POSIX_RADIO_CHANNEL_MAX)); + otEXPECT((SIM_RADIO_CHANNEL_MIN <= channel) && channel <= (SIM_RADIO_CHANNEL_MAX)); // To emulate a simple interference model, we return either a high or // a low RSSI value with a fixed probability per each channel. The // probability is increased per channel by a constant. - probabilityThreshold = (channel - POSIX_RADIO_CHANNEL_MIN) * POSIX_HIGH_RSSI_PROB_INC_PER_CHANNEL; + probabilityThreshold = (channel - SIM_RADIO_CHANNEL_MIN) * SIM_HIGH_RSSI_PROB_INC_PER_CHANNEL; if (otRandomNonCryptoGetUint16() < (probabilityThreshold * 0xffff / 100)) { - rssi = POSIX_HIGH_RSSI_SAMPLE; + rssi = SIM_HIGH_RSSI_SAMPLE; } exit: @@ -469,7 +469,7 @@ static void radioReceive(otInstance *aInstance) { isTxDone = isAck && otMacFrameGetSequence(&sReceiveFrame) == otMacFrameGetSequence(&sTransmitFrame); } -#if OPENTHREAD_POSIX_VIRTUAL_TIME +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME // Simulate tx done when receiving the echo frame. else { @@ -555,7 +555,7 @@ void radioSendMessage(otInstance *aInstance) radioComputeCrc(&sTransmitMessage, sTransmitFrame.mLength); radioTransmit(&sTransmitMessage, &sTransmitFrame); -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 sTxWait = otMacFrameIsAckRequested(&sTransmitFrame); if (!sTxWait) @@ -577,7 +577,7 @@ void radioSendMessage(otInstance *aInstance) #else // Wait for echo radio in virtual time mode. sTxWait = true; -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME } bool platformRadioIsTransmitPending(void) @@ -585,7 +585,7 @@ bool platformRadioIsTransmitPending(void) return sState == OT_RADIO_STATE_TRANSMIT && !sTxWait; } -#if OPENTHREAD_POSIX_VIRTUAL_TIME +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME void platformRadioReceive(otInstance *aInstance, uint8_t *aBuf, uint16_t aBufLength) { assert(sizeof(sReceiveMessage) >= aBufLength); @@ -633,14 +633,14 @@ void platformRadioDeinit(void) close(sTxFd); } } -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME void platformRadioProcess(otInstance *aInstance, const fd_set *aReadFdSet, const fd_set *aWriteFdSet) { OT_UNUSED_VARIABLE(aReadFdSet); OT_UNUSED_VARIABLE(aWriteFdSet); -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 if (FD_ISSET(sRxFd, aReadFdSet)) { struct sockaddr_in sockaddr; @@ -681,7 +681,7 @@ void platformRadioProcess(otInstance *aInstance, const fd_set *aReadFdSet, const void radioTransmit(struct RadioMessage *aMessage, const struct otRadioFrame *aFrame) { -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 ssize_t rval; struct sockaddr_in sockaddr; @@ -698,7 +698,7 @@ void radioTransmit(struct RadioMessage *aMessage, const struct otRadioFrame *aFr perror("sendto(sTxFd)"); exit(EXIT_FAILURE); } -#else // OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#else // OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 struct Event event; event.mDelay = 1; // 1us for now @@ -707,7 +707,7 @@ void radioTransmit(struct RadioMessage *aMessage, const struct otRadioFrame *aFr memcpy(event.mData, aMessage, event.mDataLength); otSimSendEvent(&event); -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 } void radioSendAck(void) @@ -777,7 +777,7 @@ void otPlatRadioEnableSrcMatch(otInstance *aInstance, bool aEnable) otError otPlatRadioEnergyScan(otInstance *aInstance, uint8_t aScanChannel, uint16_t aScanDuration) { assert(aInstance != NULL); - assert(aScanChannel >= POSIX_RADIO_CHANNEL_MIN && aScanChannel <= POSIX_RADIO_CHANNEL_MAX); + assert(aScanChannel >= SIM_RADIO_CHANNEL_MIN && aScanChannel <= SIM_RADIO_CHANNEL_MAX); assert(aScanDuration > 0); return OT_ERROR_NOT_IMPLEMENTED; @@ -823,7 +823,7 @@ int8_t otPlatRadioGetReceiveSensitivity(otInstance *aInstance) { assert(aInstance != NULL); - return POSIX_RECEIVE_SENSITIVITY; + return SIM_RECEIVE_SENSITIVITY; } otRadioState otPlatRadioGetState(otInstance *aInstance) diff --git a/examples/platforms/posix/spi-stubs.c b/examples/platforms/simulation/spi-stubs.c similarity index 96% rename from examples/platforms/posix/spi-stubs.c rename to examples/platforms/simulation/spi-stubs.c index 4bfe34377..7c0dd629c 100644 --- a/examples/platforms/posix/spi-stubs.c +++ b/examples/platforms/simulation/spi-stubs.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include @@ -47,7 +47,7 @@ otError otPlatSpiSlaveEnable(otPlatSpiSlaveTransactionCompleteCallback aComplete OT_UNUSED_VARIABLE(aProcessCallback); OT_UNUSED_VARIABLE(aContext); - fprintf(stderr, "\nNo SPI support for posix platform."); + fprintf(stderr, "\nNo SPI support for simulation platform."); exit(0); return OT_ERROR_NOT_IMPLEMENTED; diff --git a/examples/platforms/posix/system.c b/examples/platforms/simulation/system.c similarity index 97% rename from examples/platforms/posix/system.c rename to examples/platforms/simulation/system.c index e509543de..f929870e0 100644 --- a/examples/platforms/posix/system.c +++ b/examples/platforms/simulation/system.c @@ -32,9 +32,9 @@ * This file includes the platform-specific initializers. */ -#include "platform-posix.h" +#include "platform-simulation.h" -#if OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 #include #include @@ -162,4 +162,4 @@ void otSysProcessDrivers(otInstance *aInstance) } } -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME == 0 +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME == 0 diff --git a/examples/platforms/posix/uart-posix.c b/examples/platforms/simulation/uart.c similarity index 96% rename from examples/platforms/posix/uart-posix.c rename to examples/platforms/simulation/uart.c index 04d32814a..1160a33f6 100644 --- a/examples/platforms/posix/uart-posix.c +++ b/examples/platforms/simulation/uart.c @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" #include #include @@ -43,7 +43,7 @@ #include "utils/code_utils.h" -#if OPENTHREAD_POSIX_VIRTUAL_TIME_UART == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART == 0 #ifdef OPENTHREAD_TARGET_LINUX #include int posix_openpt(int oflag); @@ -128,7 +128,7 @@ otError otPlatUartEnable(void) termios.c_cc[VTIME] = 0; // configure baud rate - otEXPECT_ACTION(cfsetispeed(&termios, OPENTHREAD_POSIX_UART_BAUDRATE) == 0, perror("cfsetispeed"); + otEXPECT_ACTION(cfsetispeed(&termios, OPENTHREAD_SIMULATION_UART_BAUDRATE) == 0, perror("cfsetispeed"); error = OT_ERROR_GENERIC); // set configuration @@ -151,7 +151,7 @@ otError otPlatUartEnable(void) termios.c_cflag |= HUPCL | CREAD | CLOCAL; // configure baud rate - otEXPECT_ACTION(cfsetospeed(&termios, OPENTHREAD_POSIX_UART_BAUDRATE) == 0, perror("cfsetospeed"); + otEXPECT_ACTION(cfsetospeed(&termios, OPENTHREAD_SIMULATION_UART_BAUDRATE) == 0, perror("cfsetospeed"); error = OT_ERROR_GENERIC); // set configuration @@ -317,7 +317,7 @@ void platformUartProcess(void) } } } -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME_UART == 0 +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART == 0 #if OPENTHREAD_CONFIG_ENABLE_DEBUG_UART && (OPENTHREAD_CONFIG_LOG_OUTPUT == OPENTHREAD_CONFIG_LOG_OUTPUT_DEBUG_UART) diff --git a/examples/platforms/posix/sim/alarm-sim.c b/examples/platforms/simulation/virtual_time/alarm-sim.c similarity index 97% rename from examples/platforms/posix/sim/alarm-sim.c rename to examples/platforms/simulation/virtual_time/alarm-sim.c index 5238782a7..479036fef 100644 --- a/examples/platforms/posix/sim/alarm-sim.c +++ b/examples/platforms/simulation/virtual_time/alarm-sim.c @@ -26,9 +26,9 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include "platform-posix.h" +#include "platform-simulation.h" -#if OPENTHREAD_POSIX_VIRTUAL_TIME +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME #include #include @@ -193,4 +193,4 @@ uint16_t otPlatTimeGetXtalAccuracy(void) } #endif -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME diff --git a/examples/platforms/posix/sim/platform-sim.c b/examples/platforms/simulation/virtual_time/platform-sim.c similarity index 95% rename from examples/platforms/posix/sim/platform-sim.c rename to examples/platforms/simulation/virtual_time/platform-sim.c index 87936c651..8226fe6fc 100644 --- a/examples/platforms/posix/sim/platform-sim.c +++ b/examples/platforms/simulation/virtual_time/platform-sim.c @@ -32,9 +32,9 @@ * This file includes the platform-specific initializers. */ -#include "platform-posix.h" +#include "platform-simulation.h" -#if OPENTHREAD_POSIX_VIRTUAL_TIME +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME #include #include @@ -133,7 +133,7 @@ static void platformSendSleepEvent(void) otSimSendEvent(&event); } -#if OPENTHREAD_POSIX_VIRTUAL_TIME_UART +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART void platformUartRestore(void) { } @@ -170,7 +170,7 @@ otError otPlatUartFlush(void) { return OT_ERROR_NOT_IMPLEMENTED; } -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME_UART +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART static void socket_init(void) { @@ -283,7 +283,7 @@ void otSysProcessDrivers(otInstance *aInstance) FD_SET(sSockFd, &read_fds); max_fd = sSockFd; -#if OPENTHREAD_POSIX_VIRTUAL_TIME_UART == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART == 0 platformUartUpdateFdSet(&read_fds, &write_fds, &error_fds, &max_fd); #endif @@ -307,9 +307,9 @@ void otSysProcessDrivers(otInstance *aInstance) platformAlarmProcess(aInstance); platformRadioProcess(aInstance, &read_fds, &write_fds); -#if OPENTHREAD_POSIX_VIRTUAL_TIME_UART == 0 +#if OPENTHREAD_SIMULATION_VIRTUAL_TIME_UART == 0 platformUartProcess(); #endif } -#endif // OPENTHREAD_POSIX_VIRTUAL_TIME +#endif // OPENTHREAD_SIMULATION_VIRTUAL_TIME diff --git a/include/openthread/platform/debug_uart.h b/include/openthread/platform/debug_uart.h index 9a4f8643b..b0410aff5 100644 --- a/include/openthread/platform/debug_uart.h +++ b/include/openthread/platform/debug_uart.h @@ -173,7 +173,7 @@ void otPlatDebugUart_write_bytes(const uint8_t *pBytes, int nBytes); void otPlatDebugUart_puts_no_nl(const char *s); /** - * Some platforms (posix) can log to a file. + * Some platforms (simulation) can log to a file. * * @returns OT_ERROR_NONE * @returns OT_ERROR_FAILED diff --git a/script/bootstrap b/script/bootstrap index c535361c4..23a34ee02 100755 --- a/script/bootstrap +++ b/script/bootstrap @@ -81,9 +81,9 @@ install_packages_brew() brew tap ArmMbed/homebrew-formulae brew install arm-none-eabi-gcc - # check for gcc for posix examples + # check for gcc for simulation if ! which gcc; then - echo 'warning: clang/gcc needed for posix examples' + echo 'warning: clang/gcc needed for simulation' echo 'warning: please install Command Line Tools from https://developer.apple.com/download/more/' fi diff --git a/script/test b/script/test index 14b8c4641..a2f559f55 100755 --- a/script/test +++ b/script/test @@ -44,7 +44,7 @@ do_build() { OPTIONS="VIRTUAL_TIME_UART=1" fi - make -f examples/Makefile-posix ${OPTIONS} + make -f examples/Makefile-simulation ${OPTIONS} if [[ -n "${RADIO_DEVICE}" ]]; then make -f src/posix/Makefile-posix @@ -54,7 +54,7 @@ do_build() { if [ "${THREAD_VERSION}" = "1.2" ]; then ./bootstrap OPTIONS="TargetTuple=${SYSTEM_TRIPLET}-1.1 THREAD_VERSION=1.1 ${OPTIONS}" - make -f examples/Makefile-posix ${OPTIONS} + make -f examples/Makefile-simulation ${OPTIONS} if [[ -n "${RADIO_DEVICE}" ]]; then make -f src/posix/Makefile-posix @@ -116,7 +116,7 @@ do_package() { local builddir="${OT_BUILDDIR}/cmake/openthread-sim" (mkdir -p "${builddir}" \ && cd "${builddir}" \ - && cmake "${OT_SRCDIR}" -DOT_PLATFORM="posix" \ + && cmake "${OT_SRCDIR}" -DOT_PLATFORM="simulation" \ && make -j${OT_BUILD_JOBS} package \ && ls "${builddir}"/openthread-simulation-*.deb) diff --git a/src/cli/README.md b/src/cli/README.md index 98b54a463..f2e6d4cec 100644 --- a/src/cli/README.md +++ b/src/cli/README.md @@ -718,7 +718,7 @@ Done ### logfilename \ -- Note: POSIX Platform Only, ie: `OPENTHREAD_EXAMPLES_POSIX` +- Note: Simulation Only, ie: `OPENTHREAD_EXAMPLES_SIMULATION` - Requires `OPENTHREAD_CONFIG_LOG_OUTPUT == OPENTHREAD_CONFIG_LOG_OUTPUT_DEBUG_UART` Specifies filename to capture otPlatLog() messages, useful when diff --git a/src/cli/README_COAP.md b/src/cli/README_COAP.md index 425b97abc..d335ce18a 100644 --- a/src/cli/README_COAP.md +++ b/src/cli/README_COAP.md @@ -10,7 +10,7 @@ Use the `COAP=1` build switch to enable CoAP API support. ```bash > ./bootstrap -> make -f examples/Makefile-posix COAP=1 +> make -f examples/Makefile-simulation COAP=1 ``` ### Form Network diff --git a/src/cli/README_COAPS.md b/src/cli/README_COAPS.md index c28a4cc50..b0d54f385 100644 --- a/src/cli/README_COAPS.md +++ b/src/cli/README_COAPS.md @@ -10,7 +10,7 @@ Use the `COAPS=1` build switch to enable CoAPS API support. ```bash > ./bootstrap -> make -f examples/Makefile-posix COAPS=1 +> make -f examples/Makefile-simulation COAPS=1 ``` ### Form Network diff --git a/src/cli/README_COMMISSIONING.md b/src/cli/README_COMMISSIONING.md index b61d7bd79..d5c0e5b4a 100644 --- a/src/cli/README_COMMISSIONING.md +++ b/src/cli/README_COMMISSIONING.md @@ -8,7 +8,7 @@ Use the `JOINER=1` build switch to enable Joiner support. ```bash > ./bootstrap -> make -f examples/Makefile-posix JOINER=1 +> make -f examples/Makefile-simulation JOINER=1 ``` ### Build with Commissioner support @@ -17,7 +17,7 @@ Use the `COMMISSIONER=1` build switch to enable Commissioner support. ```bash > ./bootstrap -> make -f examples/Makefile-posix COMMISSIONER=1 +> make -f examples/Makefile-simulation COMMISSIONER=1 ``` ### Form Network diff --git a/src/posix/README.md b/src/posix/README.md index 7f9913bf6..6690f5019 100644 --- a/src/posix/README.md +++ b/src/posix/README.md @@ -36,7 +36,7 @@ You can also perform radio diagnostics using the command [diag](../../src/core/d ### With Simulation ```sh -make -f examples/Makefile-posix +make -f examples/Makefile-simulation ./output/posix/x86_64-unknown-linux-gnu/bin/ot-cli ./output/x86_64-unknown-linux-gnu/bin/ot-rcp 1 ``` diff --git a/tests/toranj/build.sh b/tests/toranj/build.sh index ca279d851..d0f26c817 100755 --- a/tests/toranj/build.sh +++ b/tests/toranj/build.sh @@ -36,8 +36,8 @@ display_usage() { echo "" echo "Usage: $(basename $0) [options] " echo " can be:" - echo " ncp : Build OpenThread NCP FTD mode with POSIX platform" - echo " rcp : Build OpenThread RCP (NCP in radio mode) with POSIX platform" + echo " ncp : Build OpenThread NCP FTD mode with simulation platform" + echo " rcp : Build OpenThread RCP (NCP in radio mode) with simulation platform" echo " posix-app : Build OpenThread POSIX App NCP" echo " cmake : Configure and build OpenThread using cmake/ninja (RCP and NCP) only" echo "" @@ -108,7 +108,7 @@ case ${build_config} in cd "${top_builddir}" ${top_srcdir}/configure \ CPPFLAGS="$cppflags_config" \ - --with-examples=posix \ + --with-examples=simulation \ $configure_options || die make -j 8 || die ;; @@ -124,7 +124,7 @@ case ${build_config} in --enable-coverage=${coverage} \ --enable-ncp \ --enable-radio-only \ - --with-examples=posix \ + --with-examples=simulation \ --disable-docs \ --enable-tests=$tests || die make -j 8 || die @@ -145,9 +145,9 @@ case ${build_config} in cmake) echo "====================================================================================================" - echo "Building OpenThread (NCP/CLI for FTD/MTD/RCP mode) with POSIX platform using cmake" + echo "Building OpenThread (NCP/CLI for FTD/MTD/RCP mode) with simulation platform using cmake" echo "====================================================================================================" - cmake -GNinja -DOT_PLATFORM=posix -DOT_CONFIG=../tests/toranj/openthread-core-toranj-config.h . || die + cmake -GNinja -DOT_PLATFORM=simulation -DOT_CONFIG=../tests/toranj/openthread-core-toranj-config.h . || die ninja || die ;; diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am index 8764e9710..4b076c3cd 100644 --- a/tests/unit/Makefile.am +++ b/tests/unit/Makefile.am @@ -59,7 +59,7 @@ AM_CPPFLAGS = \ -I$(top_srcdir)/src/core \ $(NULL) -if OPENTHREAD_EXAMPLES_POSIX +if OPENTHREAD_EXAMPLES_SIMULATION AM_CPPFLAGS += \ -I$(top_srcdir)/examples/platforms \ $(NULL) diff --git a/third_party/ti/ti-openthread_1.01.0_manifest.html b/third_party/ti/ti-openthread_1.01.0_manifest.html index d9508f9c8..bf3ecf2bc 100644 --- a/third_party/ti/ti-openthread_1.01.0_manifest.html +++ b/third_party/ti/ti-openthread_1.01.0_manifest.html @@ -732,7 +732,7 @@ Publicly Available Location - [as_installed]/examples/Makefile-posix + [as_installed]/examples/Makefile-simulation @@ -745,7 +745,7 @@ Publicly Available - posix platform layer + simulation platform layer 0.01.00 @@ -761,7 +761,7 @@ Publicly Available Location - [as_installed]/examples/platforms/posix + [as_installed]/examples/platforms/simulation @@ -1813,4 +1813,4 @@ Publicly Available with 100,000+ analog ICs and embedded processors, along with software, tools and the industry's largest sales/support staff.

- \ No newline at end of file +