From 7bf47a50e58c50106d2af65409e38726050327ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Xose=20P=C3=A9rez?= Date: Fri, 25 Aug 2017 13:38:43 +0200 Subject: [PATCH] Added generic OTA environments to platformio.ini file --- code/espurna/espurna.ino | 4 ++-- code/platformio.ini | 40 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 42 insertions(+), 2 deletions(-) diff --git a/code/espurna/espurna.ino b/code/espurna/espurna.ino index 333a6f66..a6f1b6d1 100644 --- a/code/espurna/espurna.ino +++ b/code/espurna/espurna.ino @@ -172,8 +172,8 @@ void welcome() { DEBUG_MSG_P(PSTR("Flash mode: %s\n"), mode == FM_QIO ? "QIO" : mode == FM_QOUT ? "QOUT" : mode == FM_DIO ? "DIO" : mode == FM_DOUT ? "DOUT" : "UNKNOWN"); DEBUG_MSG_P(PSTR("\n")); DEBUG_MSG_P(PSTR("Flash sector size: %8u bytes\n"), SPI_FLASH_SEC_SIZE); - DEBUG_MSG_P(PSTR("Flash size (SDK): %8u bytes\n"), ESP.getFlashChipSize()); - DEBUG_MSG_P(PSTR("Flash size (CHIP): %8u bytes / %4d sectors\n"), ESP.getFlashChipRealSize(), sectors(ESP.getFlashChipRealSize())); + DEBUG_MSG_P(PSTR("Flash size (CHIP): %8u bytes\n"), ESP.getFlashChipRealSize()); + DEBUG_MSG_P(PSTR("Flash size (SDK): %8u bytes / %4d sectors\n"), ESP.getFlashChipSize(), sectors(ESP.getFlashChipSize())); DEBUG_MSG_P(PSTR("Firmware size: %8u bytes / %4d sectors\n"), ESP.getSketchSize(), sectors(ESP.getSketchSize())); DEBUG_MSG_P(PSTR("OTA size: %8u bytes / %4d sectors\n"), ESP.getFreeSketchSpace(), sectors(ESP.getFreeSketchSpace())); #if SPIFFS_SUPPORT diff --git a/code/platformio.ini b/code/platformio.ini index fc29fa7f..487f3114 100644 --- a/code/platformio.ini +++ b/code/platformio.ini @@ -758,3 +758,43 @@ upload_speed = 115200 upload_port = "192.168.4.1" upload_flags = --auth=fibonacci --port 8266 monitor_baud = 115200 + +# ------------------------------------------------------------------------------ +# GENERIC OTA ENVIRONMENTS +# ------------------------------------------------------------------------------ + +[env:esp8285-1m-ota] +platform = espressif8266 +framework = arduino +board = esp8285 +board_flash_mode = dout +lib_deps = ${common.lib_deps} +lib_ignore = ${common.lib_ignore} +build_flags = ${common.build_flags_1m} -D${env.BOARD} +upload_speed = 115200 +upload_port = "${env.IP}" +upload_flags = --auth=${env.AUTH} --port 8266 + +[env:esp8266-1m-ota] +platform = espressif8266 +framework = arduino +board = esp01_1m +board_flash_mode = dout +lib_deps = ${common.lib_deps} +lib_ignore = ${common.lib_ignore} +build_flags = ${common.build_flags_1m} -D${env.BOARD} +upload_speed = 115200 +upload_port = "${env.IP}" +upload_flags = --auth=${env.AUTH} --port 8266 + +[env:esp8266-4m-ota] +platform = espressif8266 +framework = arduino +board = esp12e +board_flash_mode = dout +lib_deps = ${common.lib_deps} +lib_ignore = ${common.lib_ignore} +build_flags = ${common.build_flags} -D${env.BOARD} +upload_speed = 115200 +upload_port = "${env.IP}" +upload_flags = --auth=${env.AUTH} --port 8266