From 4572ecbe11901b0f2c9353aa4a38796380f62f07 Mon Sep 17 00:00:00 2001 From: Siwat Sirichai Date: Sat, 27 Jan 2024 21:59:36 +0700 Subject: [PATCH] btnlt kit --- ESPMegaPRO-DevKit-BTNLT/.gitignore | 5 + .../.vscode/extensions.json | 10 + ESPMegaPRO-DevKit-BTNLT/.vscode/settings.json | 288 ++++++++++++++++++ ESPMegaPRO-DevKit-BTNLT/include/README | 39 +++ ESPMegaPRO-DevKit-BTNLT/lib/README | 46 +++ ESPMegaPRO-DevKit-BTNLT/platformio.ini | 16 + ESPMegaPRO-DevKit-BTNLT/src/main.cpp | 23 ++ ESPMegaPRO-DevKit-BTNLT/test/README | 11 + .../lib/ESPMegaPRO/ESPMegaProOS.cpp | 2 +- 9 files changed, 439 insertions(+), 1 deletion(-) create mode 100644 ESPMegaPRO-DevKit-BTNLT/.gitignore create mode 100644 ESPMegaPRO-DevKit-BTNLT/.vscode/extensions.json create mode 100644 ESPMegaPRO-DevKit-BTNLT/.vscode/settings.json create mode 100644 ESPMegaPRO-DevKit-BTNLT/include/README create mode 100644 ESPMegaPRO-DevKit-BTNLT/lib/README create mode 100644 ESPMegaPRO-DevKit-BTNLT/platformio.ini create mode 100644 ESPMegaPRO-DevKit-BTNLT/src/main.cpp create mode 100644 ESPMegaPRO-DevKit-BTNLT/test/README diff --git a/ESPMegaPRO-DevKit-BTNLT/.gitignore b/ESPMegaPRO-DevKit-BTNLT/.gitignore new file mode 100644 index 0000000..89cc49c --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/.gitignore @@ -0,0 +1,5 @@ +.pio +.vscode/.browse.c_cpp.db* +.vscode/c_cpp_properties.json +.vscode/launch.json +.vscode/ipch diff --git a/ESPMegaPRO-DevKit-BTNLT/.vscode/extensions.json b/ESPMegaPRO-DevKit-BTNLT/.vscode/extensions.json new file mode 100644 index 0000000..080e70d --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/.vscode/extensions.json @@ -0,0 +1,10 @@ +{ + // See http://go.microsoft.com/fwlink/?LinkId=827846 + // for the documentation about the extensions.json format + "recommendations": [ + "platformio.platformio-ide" + ], + "unwantedRecommendations": [ + "ms-vscode.cpptools-extension-pack" + ] +} diff --git a/ESPMegaPRO-DevKit-BTNLT/.vscode/settings.json b/ESPMegaPRO-DevKit-BTNLT/.vscode/settings.json new file mode 100644 index 0000000..cf88254 --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/.vscode/settings.json @@ -0,0 +1,288 @@ +{ + "C_Cpp_Runner.cCompilerPath": "C:/Users/siwat/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/xtensa-esp32-elf-gcc.exe", + "C_Cpp_Runner.cppCompilerPath": "C:/Users/siwat/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/xtensa-esp32-elf-g++.exe", + "C_Cpp_Runner.debuggerPath": "C:/Users/siwat/.platformio/packages/toolchain-xtensa-esp32@8.4.0+2021r2-patch5/bin/xtensa-esp32-elf-gdb.exe", + "C_Cpp_Runner.cStandard": "gnu99", + "C_Cpp_Runner.cppStandard": "gnu++11", + "C_Cpp_Runner.msvcBatchPath": "", + "C_Cpp_Runner.useMsvc": false, + "C_Cpp_Runner.warnings": [ + "-Wall", + "-Wextra", + "-Wpedantic", + "-Wshadow", + "-Wformat=2", + "-Wcast-align", + "-Wconversion", + "-Wsign-conversion", + "-Wnull-dereference" + ], + "C_Cpp_Runner.msvcWarnings": [ + "/W4", + "/permissive-", + "/w14242", + "/w14287", + "/w14296", + "/w14311", + "/w14826", + "/w44062", + "/w44242", + "/w14905", + "/w14906", + "/w14263", + "/w44265", + "/w14928" + ], + "C_Cpp_Runner.enableWarnings": true, + "C_Cpp_Runner.warningsAsError": false, + "C_Cpp_Runner.compilerArgs": [], + "C_Cpp_Runner.linkerArgs": [], + "C_Cpp_Runner.includePaths": [ + "D:/Git/ESPMegaPRO-v3-SDK/ESPMegaPRO-DevKit-BTNLT/include", + "D:/Git/ESPMegaPRO-v3-SDK/ESPMegaPRO-DevKit-BTNLT/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/newlib/platform_include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/freertos/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/freertos/include/esp_additions/freertos", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/freertos/port/xtensa/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/freertos/include/esp_additions", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_hw_support/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_hw_support/include/soc", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_hw_support/include/soc/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_hw_support/port/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_hw_support/port/esp32/private_include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/heap/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/log/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/lwip/include/apps", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/lwip/include/apps/sntp", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/lwip/lwip/src/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/lwip/port/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/lwip/port/esp32/include/arch", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/soc/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/soc/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/soc/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/hal/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/hal/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/hal/platform_port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_rom/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_rom/include/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_rom/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_common/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_system/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_system/port/soc", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_system/port/public_compat", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/xtensa/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/xtensa/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/driver/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/driver/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_pm/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_ringbuf/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/efuse/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/efuse/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/vfs/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_wifi/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_event/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_netif/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_eth/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/tcpip_adapter/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_phy/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_phy/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_ipc/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/app_trace/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_timer/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/mbedtls/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/mbedtls/mbedtls/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/mbedtls/esp_crt_bundle/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/app_update/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/spi_flash/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bootloader_support/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/nvs_flash/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/pthread/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_gdbstub/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_gdbstub/xtensa", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_gdbstub/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espcoredump/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espcoredump/include/port/xtensa", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/wpa_supplicant/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/wpa_supplicant/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/wpa_supplicant/esp_supplicant/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/ieee802154/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/console", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/asio/asio/asio/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/asio/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/common/osi/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/include/esp32/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/common/api/include/api", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/common/btc/profile/esp/blufi/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/common/btc/profile/esp/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/host/bluedroid/api/include/api", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_common/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_common/tinycrypt/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_core", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_core/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_core/storage", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/btc/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_models/common/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_models/client/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/mesh_models/server/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/api/core/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/api/models/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/bt/esp_ble_mesh/api", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/cbor/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/unity/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/unity/unity/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/cmock/CMock/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/coap/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/coap/libcoap/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/nghttp/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/nghttp/nghttp2/lib/includes", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-tls", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-tls/esp-tls-crypto", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_adc_cal/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_hid/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/tcp_transport/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_http_client/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_http_server/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_https_ota/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_https_server/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_lcd/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_lcd/interface", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/protobuf-c/protobuf-c", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/protocomm/include/common", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/protocomm/include/security", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/protocomm/include/transports", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/mdns/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_local_ctrl/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/sdmmc/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_serial_slave_link/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_websocket_client/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/expat/expat/expat/lib", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/expat/port/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/wear_levelling/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/fatfs/diskio", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/fatfs/vfs", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/fatfs/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/freemodbus/freemodbus/common/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/idf_test/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/idf_test/include/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/jsmn/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/json/cJSON", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/libsodium/libsodium/src/libsodium/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/libsodium/port_include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/mqtt/esp-mqtt/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/openssl/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/perfmon/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/spiffs/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/ulp/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/wifi_provisioning/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/rmaker_common/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_diagnostics/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/rtc_store/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_insights/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/json_parser/upstream/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/json_parser/upstream", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/json_generator/upstream", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_schedule/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp_secure_cert_mgr/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_rainmaker/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/gpio_button/button/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/qrcode/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/ws2812_led", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp_littlefs/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/tool", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/typedef", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/image", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/math", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/nn", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/layer", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/detect", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-dl/include/model_zoo", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-sr/src/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-sr/esp-tts/esp_tts_chinese/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp-sr/include/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp32-camera/driver/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/esp32-camera/conversions/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/dotprod/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/support/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/hann/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/blackman/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/blackman_harris/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/blackman_nuttall/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/nuttall/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/windows/flat_top/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/iir/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/fir/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/add/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/sub/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/mul/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/addc/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/mulc/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/math/sqrt/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/matrix/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/fft/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/dct/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/conv/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/common/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/kalman/ekf/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/espressif__esp-dsp/modules/kalman/ekf_imu13states/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/fb_gfx/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/qio_qspi/include", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/cores/esp32", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/variants/wt32-eth01", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/ArduinoOTA/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/AsyncUDP/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/BLE/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/BluetoothSerial/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/DNSServer/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/EEPROM/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/ESP32/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/ESPmDNS/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/Ethernet/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/FFat/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/FS/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/HTTPClient/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/HTTPUpdate/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/HTTPUpdateServer/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/I2S/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/Insights/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/LittleFS/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/NetBIOS/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/Preferences/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/RainMaker/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/SD/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/SD_MMC/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/SPI/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/SPIFFS/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/SimpleBLE/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/Ticker/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/USB/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/Update/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/WebServer/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/WiFi/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/WiFiClientSecure/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/WiFiProv/src", + "C:/Users/siwat/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src", + "" + ], + "C_Cpp_Runner.includeSearch": [ + "*", + "**/*" + ], + "C_Cpp_Runner.excludeSearch": [ + "**/build", + "**/build/**", + "**/.*", + "**/.*/**", + "**/.vscode", + "**/.vscode/**" + ], + "C_Cpp_Runner.useAddressSanitizer": false, + "C_Cpp_Runner.useUndefinedSanitizer": false, + "C_Cpp_Runner.useLeakSanitizer": false, + "C_Cpp_Runner.showCompilationTime": false, + "C_Cpp_Runner.useLinkTimeOptimization": false, + "C_Cpp_Runner.msvcSecureNoWarnings": false +} \ No newline at end of file diff --git a/ESPMegaPRO-DevKit-BTNLT/include/README b/ESPMegaPRO-DevKit-BTNLT/include/README new file mode 100644 index 0000000..194dcd4 --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/include/README @@ -0,0 +1,39 @@ + +This directory is intended for project header files. + +A header file is a file containing C declarations and macro definitions +to be shared between several project source files. You request the use of a +header file in your project source file (C, C++, etc) located in `src` folder +by including it, with the C preprocessing directive `#include'. + +```src/main.c + +#include "header.h" + +int main (void) +{ + ... +} +``` + +Including a header file produces the same results as copying the header file +into each source file that needs it. Such copying would be time-consuming +and error-prone. With a header file, the related declarations appear +in only one place. If they need to be changed, they can be changed in one +place, and programs that include the header file will automatically use the +new version when next recompiled. The header file eliminates the labor of +finding and changing all the copies as well as the risk that a failure to +find one copy will result in inconsistencies within a program. + +In C, the usual convention is to give header files names that end with `.h'. +It is most portable to use only letters, digits, dashes, and underscores in +header file names, and at most one dot. + +Read more about using header files in official GCC documentation: + +* Include Syntax +* Include Operation +* Once-Only Headers +* Computed Includes + +https://gcc.gnu.org/onlinedocs/cpp/Header-Files.html diff --git a/ESPMegaPRO-DevKit-BTNLT/lib/README b/ESPMegaPRO-DevKit-BTNLT/lib/README new file mode 100644 index 0000000..6debab1 --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/lib/README @@ -0,0 +1,46 @@ + +This directory is intended for project specific (private) libraries. +PlatformIO will compile them to static libraries and link into executable file. + +The source code of each library should be placed in a an own separate directory +("lib/your_library_name/[here are source files]"). + +For example, see a structure of the following two libraries `Foo` and `Bar`: + +|--lib +| | +| |--Bar +| | |--docs +| | |--examples +| | |--src +| | |- Bar.c +| | |- Bar.h +| | |- library.json (optional, custom build options, etc) https://docs.platformio.org/page/librarymanager/config.html +| | +| |--Foo +| | |- Foo.c +| | |- Foo.h +| | +| |- README --> THIS FILE +| +|- platformio.ini +|--src + |- main.c + +and a contents of `src/main.c`: +``` +#include +#include + +int main (void) +{ + ... +} + +``` + +PlatformIO Library Dependency Finder will find automatically dependent +libraries scanning project source files. + +More information about PlatformIO Library Dependency Finder +- https://docs.platformio.org/page/librarymanager/ldf.html diff --git a/ESPMegaPRO-DevKit-BTNLT/platformio.ini b/ESPMegaPRO-DevKit-BTNLT/platformio.ini new file mode 100644 index 0000000..256624f --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/platformio.ini @@ -0,0 +1,16 @@ +; PlatformIO Project Configuration File +; +; Build options: build flags, source filter +; Upload options: custom upload port, speed and extra flags +; Library options: dependencies, extra library storages +; Advanced options: extra scripting +; +; Please visit documentation for the other options and examples +; https://docs.platformio.org/page/projectconf.html + +[env:wt32-eth01] +platform = espressif32 +board = wt32-eth01 +framework = arduino +lib_deps = siwats/ESPMegaPROR3@^2.0.7 +monitor_speed = 115200 \ No newline at end of file diff --git a/ESPMegaPRO-DevKit-BTNLT/src/main.cpp b/ESPMegaPRO-DevKit-BTNLT/src/main.cpp new file mode 100644 index 0000000..acfee36 --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/src/main.cpp @@ -0,0 +1,23 @@ +#include + +// Function Prototypes +void setup(); +void loop(); +void inputCallback(uint8_t pin, uint8_t state); + +ESPMegaPRO espmega = ESPMegaPRO(); + +void setup() { + espmega.begin(); + espmega.inputs.registerCallback(inputCallback); +} + +void loop() { + espmega.loop(); +} + +void inputCallback(uint8_t pin, uint8_t state) { + // Match PWM Channel with the same number as the input pin + espmega.outputs.digitalWrite(pin, state); + Serial.printf("Input %d changed to %d\n", pin, state); +} \ No newline at end of file diff --git a/ESPMegaPRO-DevKit-BTNLT/test/README b/ESPMegaPRO-DevKit-BTNLT/test/README new file mode 100644 index 0000000..9b1e87b --- /dev/null +++ b/ESPMegaPRO-DevKit-BTNLT/test/README @@ -0,0 +1,11 @@ + +This directory is intended for PlatformIO Test Runner and project tests. + +Unit Testing is a software testing method by which individual units of +source code, sets of one or more MCU program modules together with associated +control data, usage procedures, and operating procedures, are tested to +determine whether they are fit for use. Unit testing finds problems early +in the development cycle. + +More information about PlatformIO Unit Testing: +- https://docs.platformio.org/en/latest/advanced/unit-testing/index.html diff --git a/ESPMegaPRO-OS-SDK/lib/ESPMegaPRO/ESPMegaProOS.cpp b/ESPMegaPRO-OS-SDK/lib/ESPMegaPRO/ESPMegaProOS.cpp index 4b37875..514cc04 100644 --- a/ESPMegaPRO-OS-SDK/lib/ESPMegaPRO/ESPMegaProOS.cpp +++ b/ESPMegaPRO-OS-SDK/lib/ESPMegaPRO/ESPMegaProOS.cpp @@ -36,7 +36,7 @@ bool ESPMegaPRO::begin() ESP_LOGE("ESPMegaPRO", "Is this an ESPMegaPRO device?"); return false; } - uint8_t inputPinMap[16] = {0, 1, 2, 3, 4, 5, 6, 7, 15, 14, 13, 12, 11, 10, 9, 8}; + uint8_t inputPinMap[16] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 15, 14, 13, 12}; inputs.loadPinMap(inputPinMap); uint8_t outputPinMap[16] = {8, 9, 10, 11, 12, 13, 14, 15, 0, 1, 2, 3, 4, 5, 6, 7}; outputs.loadPinMap(outputPinMap);