Open mapconcierge opened 1 year ago
最初に試したソースコード
#define LGFX_AUTODETECT // 自動認識
#include <M5Core2.h>
#include <LovyanGFX.hpp>
#include <WiFi.h>
#include <FS.h>
#include <SPIFFS.h>
#include <AsyncTCP.h>
#include <ESPAsyncWebServer.h>
#include <AsyncJson.h>
#include <ArduinoJson.h>
#include "base64.hpp"
const char *wifi_ssid = "dronebird";
const char *wifi_password = "dronebird";
#define HTTP_PORT 80
#define FORMAT_SPIFFS_IF_FAILED true
#define BUFFER_SIZE 30 * 1024
unsigned char buffer[BUFFER_SIZE];
AsyncWebServer server(HTTP_PORT);
static LGFX lcd;
void wifi_connect(const char *ssid, const char *password);
void notFound(AsyncWebServerRequest *request){
if (request->method() == HTTP_OPTIONS){
request->send(200);
}else{
request->send(404);
}
}
void setup() {
Serial.begin(9600);
SPIFFS.begin(FORMAT_SPIFFS_IF_FAILED);
wifi_connect(wifi_ssid, wifi_password);
lcd.init();
server.on("/get", HTTP_GET, [](AsyncWebServerRequest *request) {
AsyncWebParameter *p = request->getParam("download");
if( p != NULL )
Serial.println(p->value());
request->send(200, "text/plain", "Hello, world");
});
AsyncCallbackJsonWebHandler *handler = new AsyncCallbackJsonWebHandler("/post", [](AsyncWebServerRequest *request, JsonVariant &json) {
JsonObject jsonObj = json.as<JsonObject>();
int p1 = jsonObj["p1"] | -1;
const char *p_param = jsonObj["param"];
if( p_param != NULL ){
if (decode_base64_length((unsigned char *)p_param) <= sizeof(buffer) ){
int length = decode_base64((unsigned char *)p_param, buffer);
lcd.drawJpg(buffer, length);
}
}
// request->send(200, "application/json", "{}");
AsyncJsonResponse *response = new AsyncJsonResponse();
JsonObject root = response->getRoot();
root["p1"] = p1;
root["message"] = "Hello World";
response->setLength();
request->send(response);
});
server.addHandler(handler);
server.on("/image", HTTP_GET, [](AsyncWebServerRequest *request) {
request->send(SPIFFS, "/www/img/test.jpg", "image/jpeg");
});
server.serveStatic("/", SPIFFS, "/www/").setDefaultFile("index.html");
server.onNotFound(notFound);
DefaultHeaders::Instance().addHeader("Access-Control-Allow-Origin", "*");
DefaultHeaders::Instance().addHeader("Access-Control-Allow-Headers", "*");
server.begin();
}
void loop() {
// put your main code here, to run repeatedly:
}
void wifi_connect(const char *ssid, const char *password){
Serial.println("");
Serial.print("WiFi Connenting");
WiFi.begin(ssid, password);
while (WiFi.status() != WL_CONNECTED)
{
Serial.print(".");
delay(1000);
}
Serial.println("");
Serial.print("Connected : ");
Serial.println(WiFi.localIP());
}
Processing m5stack-core2 (platform: espressif32; board: m5stack-core2; framework: arduino)
--------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/m5stack-core2.html
PLATFORM: Espressif 32 (6.2.0) > M5Stack Core2
HARDWARE: ESP32 240MHz, 4.31MB RAM, 16MB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 @ 3.20008.0 (2.0.8)
- tool-esptoolpy @ 1.40501.0 (4.5.1)
- toolchain-xtensa-esp32 @ 8.4.0+2021r2-patch5
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 34 compatible libraries
Scanning dependencies...
Dependency Graph
|-- M5Core2 @ 0.1.5
| |-- HTTPClient @ 2.0.0
| | |-- WiFi @ 2.0.0
| | |-- WiFiClientSecure @ 2.0.0
| | | |-- WiFi @ 2.0.0
| |-- FS @ 2.0.0
| |-- SD @ 2.0.0
| | |-- FS @ 2.0.0
| | |-- SPI @ 2.0.0
| |-- SPI @ 2.0.0
| |-- Wire @ 2.0.0
| |-- SPIFFS @ 2.0.0
| | |-- FS @ 2.0.0
Building in debug mode
Compiling .pio/build/m5stack-core2/src/main.cpp.o
Building .pio/build/m5stack-core2/bootloader.bin
Generating partitions .pio/build/m5stack-core2/partitions.bin
esptool.py v4.5.1
Creating esp32 image...
Merged 1 ELF section
Successfully created esp32 image.
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFi.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiAP.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiClient.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiGeneric.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiMulti.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiSTA.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiScan.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiServer.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiUdp.cpp.o
Compiling .pio/build/m5stack-core2/lib7d6/WiFiClientSecure/WiFiClientSecure.cpp.o
Compiling .pio/build/m5stack-core2/lib7d6/WiFiClientSecure/esp_crt_bundle.c.o
Compiling .pio/build/m5stack-core2/lib7d6/WiFiClientSecure/ssl_client.cpp.o
Compiling .pio/build/m5stack-core2/lib0e9/HTTPClient/HTTPClient.cpp.o
Archiving .pio/build/m5stack-core2/lib8ba/libWiFi.a
Indexing .pio/build/m5stack-core2/lib8ba/libWiFi.a
Compiling .pio/build/m5stack-core2/lib4e2/FS/FS.cpp.o
Compiling .pio/build/m5stack-core2/lib4e2/FS/vfs_api.cpp.o
Compiling .pio/build/m5stack-core2/lib263/SPI/SPI.cpp.o
Compiling .pio/build/m5stack-core2/libb93/SD/SD.cpp.o
Archiving .pio/build/m5stack-core2/lib263/libSPI.a
Archiving .pio/build/m5stack-core2/lib7d6/libWiFiClientSecure.a
xtensa-esp32-elf-ar: .pio/build/m5stack-core2/lib263/SPI/SPI.cpp.o: No such file or directory
Indexing .pio/build/m5stack-core2/lib7d6/libWiFiClientSecure.a
*** [.pio/build/m5stack-core2/lib263/libSPI.a] Error 1
Compiling .pio/build/m5stack-core2/libb93/SD/sd_diskio.cpp.o
Compiling .pio/build/m5stack-core2/libb93/SD/sd_diskio_crc.c.o
====================================== [FAILED] Took 7.83 seconds ======================================
[x] M5Core2 今回採用したESP32のためのライブラリです。採用しているESP32に合わせて適するライブラリを選択してください。
[x] LovyanGFX Webサーバとしては必須ではありませんが、今回作成するデモで、ESP32についているLCDに画像を表示するために使っています。
[x] ArduinoJson POST/JSONでの呼び出しにおいて、JSONを扱うためのライブラリです。GET呼び出しであっても、レスポンスをJSONで返している場合にも使います。
[x] ESP Async WebServer これがWebサーバの本体です。
[x] base64 Base64をデコードするために使っています。エンコードだけであれば、ESP32に付属のライブラリで足りていたのですが、今回作成するデモで画像データを受信する際に、Base64で受信します。
フォルダー Esp32_WebServer で実行するタスク: platformio run
Processing m5stack-core2 (platform: espressif32; board: m5stack-core2; framework: arduino)
--------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/m5stack-core2.html
PLATFORM: Espressif 32 (6.2.0) > M5Stack Core2
HARDWARE: ESP32 240MHz, 4.31MB RAM, 16MB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 @ 3.20008.0 (2.0.8)
- tool-esptoolpy @ 1.40501.0 (4.5.1)
- toolchain-xtensa-esp32 @ 8.4.0+2021r2-patch5
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 40 compatible libraries
Scanning dependencies...
Dependency Graph
|-- base64 @ 1.4.0
|-- M5Core2 @ 0.1.5
| |-- HTTPClient @ 2.0.0
| | |-- WiFi @ 2.0.0
| | |-- WiFiClientSecure @ 2.0.0
| | | |-- WiFi @ 2.0.0
| |-- FS @ 2.0.0
| |-- SD @ 2.0.0
| | |-- FS @ 2.0.0
| | |-- SPI @ 2.0.0
| |-- SPI @ 2.0.0
| |-- Wire @ 2.0.0
| |-- SPIFFS @ 2.0.0
| | |-- FS @ 2.0.0
|-- LovyanGFX @ 1.1.6
| |-- SPI @ 2.0.0
| |-- Wire @ 2.0.0
|-- ArduinoJson @ 6.21.2
|-- ESP Async WebServer @ 1.2.3
| |-- AsyncTCP @ 1.1.1
| |-- ArduinoJson @ 6.21.2
| |-- FS @ 2.0.0
| |-- WiFi @ 2.0.0
|-- Base64 @ 1.0.0
|-- AsyncTCP @ 1.1.1
|-- FS @ 2.0.0
|-- SPIFFS @ 2.0.0
| |-- FS @ 2.0.0
|-- WiFi @ 2.0.0
Building in release mode
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/Fonts/IPA/lgfx_font_japan.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/Fonts/efont/lgfx_efont_cn.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/Fonts/efont/lgfx_efont_ja.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/Fonts/efont/lgfx_efont_kr.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/Fonts/efont/lgfx_efont_tw.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/utility/lgfx_pngle.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/utility/lgfx_qoi.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/utility/lgfx_qrcode.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/utility/lgfx_tjpgd.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/utility/miniz.c.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/LGFXBase.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/lgfx_fonts.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/panel/Panel_GDEW0154M09.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/panel/Panel_IT8951.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/platforms/esp32_common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/platforms/samd51_common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/touch/Touch_FT5x06.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/touch/Touch_GT911.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/touch/Touch_STMPE610.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v0/touch/Touch_XPT2046.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/LGFXBase.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/LGFX_Button.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/LGFX_Sprite.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/lgfx_fonts.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/misc/DividedFrameBuffer.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/misc/SpriteBuffer.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/misc/common_function.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/misc/pixelcopy.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_Device.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_FlexibleFrameBuffer.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_FrameBufferBase.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_GDEW0154M09.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_HUB75.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_HasBuffer.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_ILI9225.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_IT8951.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_LCD.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_M5HDMI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_M5UnitGLASS.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_M5UnitLCD.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_NT35510.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_RA8875.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_RM68120.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_SSD1306.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_SSD1327.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_SSD1331.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_SSD1351.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/panel/Panel_SSD1963.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/arduino_default/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/arduino_default/Bus_Stream.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/arduino_default/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/Bus_HUB75.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/Bus_I2C.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/Bus_Parallel8.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/Light_PWM.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/Panel_CVBS.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32c3/Bus_Parallel8.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32s2/Bus_Parallel16.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32s2/Bus_Parallel8.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32s3/Bus_Parallel16.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32s3/Bus_Parallel8.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32s3/Bus_RGB.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp32s3/Panel_RGB.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp8266/Bus_I2C.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp8266/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/esp8266/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/framebuffer/Panel_fb.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/framebuffer/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/opencv/Panel_OpenCV.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/opencv/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/rp2040/Bus_I2C.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/rp2040/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/rp2040/Light_PWM.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/rp2040/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/samd21/Bus_I2C.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/samd21/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/samd21/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/samd51/Bus_I2C.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/samd51/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/samd51/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/sdl/Panel_sdl.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/sdl/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/spresense/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/spresense/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/stm32/Bus_SPI.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/platforms/stm32/common.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_FT5x06.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_GSLx680.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_GT911.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_NS2009.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_STMPE610.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_TT21xxx.cpp.o
Compiling .pio/build/m5stack-core2/lib96b/LovyanGFX/lgfx/v1/touch/Touch_XPT2046.cpp.o
Compiling .pio/build/m5stack-core2/src/main.cpp.o
Building .pio/build/m5stack-core2/bootloader.bin
Generating partitions .pio/build/m5stack-core2/partitions.bin
esptool.py v4.5.1
Creating esp32 image...
Merged 1 ELF section
Successfully created esp32 image.
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFi.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiAP.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiClient.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiGeneric.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiMulti.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiSTA.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiScan.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiServer.cpp.o
Compiling .pio/build/m5stack-core2/lib8ba/WiFi/WiFiUdp.cpp.o
Compiling .pio/build/m5stack-core2/lib7d6/WiFiClientSecure/WiFiClientSecure.cpp.o
Compiling .pio/build/m5stack-core2/lib7d6/WiFiClientSecure/esp_crt_bundle.c.o
Compiling .pio/build/m5stack-core2/lib7d6/WiFiClientSecure/ssl_client.cpp.o
Compiling .pio/build/m5stack-core2/lib0e9/HTTPClient/HTTPClient.cpp.o
Compiling .pio/build/m5stack-core2/lib4e2/FS/FS.cpp.o
Archiving .pio/build/m5stack-core2/lib8ba/libWiFi.a
Compiling .pio/build/m5stack-core2/lib4e2/FS/vfs_api.cpp.o
Indexing .pio/build/m5stack-core2/lib8ba/libWiFi.a
Compiling .pio/build/m5stack-core2/lib263/SPI/SPI.cpp.o
Compiling .pio/build/m5stack-core2/libb93/SD/SD.cpp.o
Compiling .pio/build/m5stack-core2/libb93/SD/sd_diskio.cpp.o
Archiving .pio/build/m5stack-core2/lib7d6/libWiFiClientSecure.a
Archiving .pio/build/m5stack-core2/lib263/libSPI.a
Indexing .pio/build/m5stack-core2/lib7d6/libWiFiClientSecure.a
Indexing .pio/build/m5stack-core2/lib263/libSPI.a
Compiling .pio/build/m5stack-core2/libb93/SD/sd_diskio_crc.c.o
Compiling .pio/build/m5stack-core2/libdda/Wire/Wire.cpp.o
Compiling .pio/build/m5stack-core2/libb85/SPIFFS/SPIFFS.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/AXP192.cpp.o
Archiving .pio/build/m5stack-core2/lib4e2/libFS.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Fonts/Font16.c.o
Indexing .pio/build/m5stack-core2/lib4e2/libFS.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Fonts/Font32rle.c.o
Archiving .pio/build/m5stack-core2/libb93/libSD.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Fonts/Font64rle.c.o
Indexing .pio/build/m5stack-core2/libb93/libSD.a
Archiving .pio/build/m5stack-core2/lib0e9/libHTTPClient.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Fonts/Font72rle.c.o
Indexing .pio/build/m5stack-core2/lib0e9/libHTTPClient.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Fonts/Font7srle.c.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Fonts/glcdfont.c.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/M5Core2.cpp.o
Archiving .pio/build/m5stack-core2/libdda/libWire.a
Indexing .pio/build/m5stack-core2/libdda/libWire.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/M5Display.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/M5Touch.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/RTC.cpp.o
Archiving .pio/build/m5stack-core2/libb85/libSPIFFS.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/Speaker.cpp.o
Indexing .pio/build/m5stack-core2/libb85/libSPIFFS.a
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/CommUtil.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/In_eSPI.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/M5Button.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/M5Timer.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/MPU6886.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/MahonyAHRS.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/PointAndZone.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/Sprite.cpp.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/ding.c.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/pngle.c.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/qrcode.c.o
Compiling .pio/build/m5stack-core2/lib900/M5Core2/utility/quaternionFilters.cpp.o
Compiling .pio/build/m5stack-core2/lib10c/AsyncTCP/AsyncTCP.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/AsyncEventSource.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/AsyncWebSocket.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/SPIFFSEditor.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/WebAuthentication.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/WebHandlers.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/WebRequest.cpp.o
Archiving .pio/build/m5stack-core2/lib10c/libAsyncTCP.a
Indexing .pio/build/m5stack-core2/lib10c/libAsyncTCP.a
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/WebResponses.cpp.o
Compiling .pio/build/m5stack-core2/liba88/ESP Async WebServer/WebServer.cpp.o
Archiving .pio/build/m5stack-core2/lib900/libM5Core2.a
Indexing .pio/build/m5stack-core2/lib900/libM5Core2.a
Compiling .pio/build/m5stack-core2/liba08/Base64@1.0.0/Base64.cpp.o
Archiving .pio/build/m5stack-core2/liba08/libBase64@1.0.0.a
Indexing .pio/build/m5stack-core2/liba08/libBase64@1.0.0.a
Compiling .pio/build/m5stack-core2/FrameworkArduino/Esp.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/FirmwareMSC.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/FunctionalInterrupt.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/HWCDC.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/HardwareSerial.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/IPAddress.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/IPv6Address.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/MD5Builder.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/Print.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/Stream.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/StreamString.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/Tone.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/USB.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/USBCDC.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/USBMSC.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/WMath.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/WString.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/base64.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/cbuf.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-adc.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-bt.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-cpu.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-dac.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-gpio.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-i2c-slave.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-i2c.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-ledc.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-matrix.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-misc.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-psram.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-rgb-led.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-rmt.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-sigmadelta.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-spi.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-time.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-timer.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-tinyusb.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-touch.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/esp32-hal-uart.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/firmware_msc_fat.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/libb64/cdecode.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/libb64/cencode.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/main.cpp.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/stdlib_noniso.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/wiring_pulse.c.o
Compiling .pio/build/m5stack-core2/FrameworkArduino/wiring_shift.c.o
Archiving .pio/build/m5stack-core2/libFrameworkArduino.a
Indexing .pio/build/m5stack-core2/libFrameworkArduino.a
Archiving .pio/build/m5stack-core2/liba88/libESP Async WebServer.a
Indexing .pio/build/m5stack-core2/liba88/libESP Async WebServer.a
Linking .pio/build/m5stack-core2/firmware.elf
/Users/taichi/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld: .pio/build/m5stack-core2/liba88/libESP Async WebServer.a(WebAuthentication.cpp.o):(.literal._ZL6getMD5PhtPc+0x4): undefined reference to `mbedtls_md5_starts'
/Users/taichi/.platformio/packages/toolchain-xtensa-esp32/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld: .pio/build/m5stack-core2/liba88/libESP Async WebServer.a(WebAuthentication.cpp.o): in function `getMD5(unsigned char*, unsigned short, char*)':
/Users/taichi/Documents/PlatformIO/Projects/Esp32_WebServer/.pio/libdeps/m5stack-core2/ESP Async WebServer/src/WebAuthentication.cpp:73: undefined reference to `mbedtls_md5_starts'
collect2: error: ld returned 1 exit status
*** [.pio/build/m5stack-core2/firmware.elf] Error 1
===================================== [FAILED] Took 21.37 seconds =====================================
* ターミナル プロセス "platformio 'run'" が終了コード 1 で終了しました。
* ターミナルはタスクで再利用されます、閉じるには任意のキーを押してください。
機材
参考資料