diff --git a/boards.txt b/boards.txt index 921cb0fa..1f2edfa1 100644 --- a/boards.txt +++ b/boards.txt @@ -8,62 +8,6 @@ menu.PSRAM=PSRAM ############################################################## -ttgo-lora32-v1.name=TTGO LoRa32-OLED V1 - -ttgo-lora32-v1.upload.tool=esptool -ttgo-lora32-v1.upload.maximum_size=1310720 -ttgo-lora32-v1.upload.maximum_data_size=294912 -ttgo-lora32-v1.upload.wait_for_upload_port=true - -ttgo-lora32-v1.serial.disableDTR=true -ttgo-lora32-v1.serial.disableRTS=true - -ttgo-lora32-v1.build.mcu=esp32 -ttgo-lora32-v1.build.core=esp32 -ttgo-lora32-v1.build.variant=ttgo-lora32-v1 -ttgo-lora32-v1.build.board=TTGO_LoRa32_V1 - -ttgo-lora32-v1.build.f_cpu=240000000L -ttgo-lora32-v1.build.flash_mode=dio -ttgo-lora32-v1.build.flash_size=4MB -ttgo-lora32-v1.build.boot=dio -ttgo-lora32-v1.build.partitions=default - -ttgo-lora32-v1.menu.FlashFreq.80=80MHz -ttgo-lora32-v1.menu.FlashFreq.80.build.flash_freq=80m -ttgo-lora32-v1.menu.FlashFreq.40=40MHz -ttgo-lora32-v1.menu.FlashFreq.40.build.flash_freq=40m - -ttgo-lora32-v1.menu.UploadSpeed.921600=921600 -ttgo-lora32-v1.menu.UploadSpeed.921600.upload.speed=921600 -ttgo-lora32-v1.menu.UploadSpeed.115200=115200 -ttgo-lora32-v1.menu.UploadSpeed.115200.upload.speed=115200 -ttgo-lora32-v1.menu.UploadSpeed.256000.windows=256000 -ttgo-lora32-v1.menu.UploadSpeed.256000.upload.speed=256000 -ttgo-lora32-v1.menu.UploadSpeed.230400.windows.upload.speed=256000 -ttgo-lora32-v1.menu.UploadSpeed.230400=230400 -ttgo-lora32-v1.menu.UploadSpeed.230400.upload.speed=230400 -ttgo-lora32-v1.menu.UploadSpeed.460800.linux=460800 -ttgo-lora32-v1.menu.UploadSpeed.460800.macosx=460800 -ttgo-lora32-v1.menu.UploadSpeed.460800.upload.speed=460800 -ttgo-lora32-v1.menu.UploadSpeed.512000.windows=512000 -ttgo-lora32-v1.menu.UploadSpeed.512000.upload.speed=512000 - -ttgo-lora32-v1.menu.DebugLevel.none=None -ttgo-lora32-v1.menu.DebugLevel.none.build.code_debug=0 -ttgo-lora32-v1.menu.DebugLevel.error=Error -ttgo-lora32-v1.menu.DebugLevel.error.build.code_debug=1 -ttgo-lora32-v1.menu.DebugLevel.warn=Warn -ttgo-lora32-v1.menu.DebugLevel.warn.build.code_debug=2 -ttgo-lora32-v1.menu.DebugLevel.info=Info -ttgo-lora32-v1.menu.DebugLevel.info.build.code_debug=3 -ttgo-lora32-v1.menu.DebugLevel.debug=Debug -ttgo-lora32-v1.menu.DebugLevel.debug.build.code_debug=4 -ttgo-lora32-v1.menu.DebugLevel.verbose=Verbose -ttgo-lora32-v1.menu.DebugLevel.verbose.build.code_debug=5 - -############################################################## - esp32.name=ESP32 Dev Module esp32.upload.tool=esptool @@ -157,82 +101,6 @@ esp32.menu.DebugLevel.verbose.build.code_debug=5 ############################################################## -cw02.name=XinaBox CW02 - -cw02.upload.tool=esptool -cw02.upload.maximum_size=1310720 -cw02.upload.maximum_data_size=294912 -cw02.upload.wait_for_upload_port=true - -cw02.serial.disableDTR=true -cw02.serial.disableRTS=true - -cw02.build.mcu=esp32 -cw02.build.core=esp32 -cw02.build.variant=xinabox -cw02.build.board=ESP32_DEV - -cw02.build.f_cpu=240000000L -cw02.build.flash_size=4MB -cw02.build.flash_freq=40m -cw02.build.flash_mode=dio -cw02.build.boot=dio -cw02.build.partitions=default - -cw02.menu.FlashMode.qio=QIO -cw02.menu.FlashMode.qio.build.flash_mode=dio -cw02.menu.FlashMode.qio.build.boot=qio -cw02.menu.FlashMode.dio=DIO -cw02.menu.FlashMode.dio.build.flash_mode=dio -cw02.menu.FlashMode.dio.build.boot=dio -cw02.menu.FlashMode.qout=QOUT -cw02.menu.FlashMode.qout.build.flash_mode=dout -cw02.menu.FlashMode.qout.build.boot=qout -cw02.menu.FlashMode.dout=DOUT -cw02.menu.FlashMode.dout.build.flash_mode=dout -cw02.menu.FlashMode.dout.build.boot=dout - -cw02.menu.FlashFreq.80=80MHz -cw02.menu.FlashFreq.80.build.flash_freq=80m -cw02.menu.FlashFreq.40=40MHz -cw02.menu.FlashFreq.40.build.flash_freq=40m - -cw02.menu.FlashSize.4M=4MB (32Mb) -cw02.menu.FlashSize.4M.build.flash_size=4MB -cw02.menu.FlashSize.2M=2MB (16Mb) -cw02.menu.FlashSize.2M.build.flash_size=2MB -cw02.menu.FlashSize.2M.build.partitions=minimal - -cw02.menu.UploadSpeed.921600=921600 -cw02.menu.UploadSpeed.921600.upload.speed=921600 -cw02.menu.UploadSpeed.115200=115200 -cw02.menu.UploadSpeed.115200.upload.speed=115200 -cw02.menu.UploadSpeed.256000.windows=256000 -cw02.menu.UploadSpeed.256000.upload.speed=256000 -cw02.menu.UploadSpeed.230400.windows.upload.speed=256000 -cw02.menu.UploadSpeed.230400=230400 -cw02.menu.UploadSpeed.230400.upload.speed=230400 -cw02.menu.UploadSpeed.460800.linux=460800 -cw02.menu.UploadSpeed.460800.macosx=460800 -cw02.menu.UploadSpeed.460800.upload.speed=460800 -cw02.menu.UploadSpeed.512000.windows=512000 -cw02.menu.UploadSpeed.512000.upload.speed=512000 - -cw02.menu.DebugLevel.none=None -cw02.menu.DebugLevel.none.build.code_debug=0 -cw02.menu.DebugLevel.error=Error -cw02.menu.DebugLevel.error.build.code_debug=1 -cw02.menu.DebugLevel.warn=Warn -cw02.menu.DebugLevel.warn.build.code_debug=2 -cw02.menu.DebugLevel.info=Info -cw02.menu.DebugLevel.info.build.code_debug=3 -cw02.menu.DebugLevel.debug=Debug -cw02.menu.DebugLevel.debug.build.code_debug=4 -cw02.menu.DebugLevel.verbose=Verbose -cw02.menu.DebugLevel.verbose.build.code_debug=5 - -############################################################## - esp32wrover.name=ESP32 Wrover Module esp32wrover.upload.tool=esptool @@ -368,6 +236,138 @@ pico32.menu.DebugLevel.verbose.build.code_debug=5 ############################################################## +ttgo-lora32-v1.name=TTGO LoRa32-OLED V1 + +ttgo-lora32-v1.upload.tool=esptool +ttgo-lora32-v1.upload.maximum_size=1310720 +ttgo-lora32-v1.upload.maximum_data_size=294912 +ttgo-lora32-v1.upload.wait_for_upload_port=true + +ttgo-lora32-v1.serial.disableDTR=true +ttgo-lora32-v1.serial.disableRTS=true + +ttgo-lora32-v1.build.mcu=esp32 +ttgo-lora32-v1.build.core=esp32 +ttgo-lora32-v1.build.variant=ttgo-lora32-v1 +ttgo-lora32-v1.build.board=TTGO_LoRa32_V1 + +ttgo-lora32-v1.build.f_cpu=240000000L +ttgo-lora32-v1.build.flash_mode=dio +ttgo-lora32-v1.build.flash_size=4MB +ttgo-lora32-v1.build.boot=dio +ttgo-lora32-v1.build.partitions=default + +ttgo-lora32-v1.menu.FlashFreq.80=80MHz +ttgo-lora32-v1.menu.FlashFreq.80.build.flash_freq=80m +ttgo-lora32-v1.menu.FlashFreq.40=40MHz +ttgo-lora32-v1.menu.FlashFreq.40.build.flash_freq=40m + +ttgo-lora32-v1.menu.UploadSpeed.921600=921600 +ttgo-lora32-v1.menu.UploadSpeed.921600.upload.speed=921600 +ttgo-lora32-v1.menu.UploadSpeed.115200=115200 +ttgo-lora32-v1.menu.UploadSpeed.115200.upload.speed=115200 +ttgo-lora32-v1.menu.UploadSpeed.256000.windows=256000 +ttgo-lora32-v1.menu.UploadSpeed.256000.upload.speed=256000 +ttgo-lora32-v1.menu.UploadSpeed.230400.windows.upload.speed=256000 +ttgo-lora32-v1.menu.UploadSpeed.230400=230400 +ttgo-lora32-v1.menu.UploadSpeed.230400.upload.speed=230400 +ttgo-lora32-v1.menu.UploadSpeed.460800.linux=460800 +ttgo-lora32-v1.menu.UploadSpeed.460800.macosx=460800 +ttgo-lora32-v1.menu.UploadSpeed.460800.upload.speed=460800 +ttgo-lora32-v1.menu.UploadSpeed.512000.windows=512000 +ttgo-lora32-v1.menu.UploadSpeed.512000.upload.speed=512000 + +ttgo-lora32-v1.menu.DebugLevel.none=None +ttgo-lora32-v1.menu.DebugLevel.none.build.code_debug=0 +ttgo-lora32-v1.menu.DebugLevel.error=Error +ttgo-lora32-v1.menu.DebugLevel.error.build.code_debug=1 +ttgo-lora32-v1.menu.DebugLevel.warn=Warn +ttgo-lora32-v1.menu.DebugLevel.warn.build.code_debug=2 +ttgo-lora32-v1.menu.DebugLevel.info=Info +ttgo-lora32-v1.menu.DebugLevel.info.build.code_debug=3 +ttgo-lora32-v1.menu.DebugLevel.debug=Debug +ttgo-lora32-v1.menu.DebugLevel.debug.build.code_debug=4 +ttgo-lora32-v1.menu.DebugLevel.verbose=Verbose +ttgo-lora32-v1.menu.DebugLevel.verbose.build.code_debug=5 + +############################################################## + +cw02.name=XinaBox CW02 + +cw02.upload.tool=esptool +cw02.upload.maximum_size=1310720 +cw02.upload.maximum_data_size=294912 +cw02.upload.wait_for_upload_port=true + +cw02.serial.disableDTR=true +cw02.serial.disableRTS=true + +cw02.build.mcu=esp32 +cw02.build.core=esp32 +cw02.build.variant=xinabox +cw02.build.board=ESP32_DEV + +cw02.build.f_cpu=240000000L +cw02.build.flash_size=4MB +cw02.build.flash_freq=40m +cw02.build.flash_mode=dio +cw02.build.boot=dio +cw02.build.partitions=default + +cw02.menu.FlashMode.qio=QIO +cw02.menu.FlashMode.qio.build.flash_mode=dio +cw02.menu.FlashMode.qio.build.boot=qio +cw02.menu.FlashMode.dio=DIO +cw02.menu.FlashMode.dio.build.flash_mode=dio +cw02.menu.FlashMode.dio.build.boot=dio +cw02.menu.FlashMode.qout=QOUT +cw02.menu.FlashMode.qout.build.flash_mode=dout +cw02.menu.FlashMode.qout.build.boot=qout +cw02.menu.FlashMode.dout=DOUT +cw02.menu.FlashMode.dout.build.flash_mode=dout +cw02.menu.FlashMode.dout.build.boot=dout + +cw02.menu.FlashFreq.80=80MHz +cw02.menu.FlashFreq.80.build.flash_freq=80m +cw02.menu.FlashFreq.40=40MHz +cw02.menu.FlashFreq.40.build.flash_freq=40m + +cw02.menu.FlashSize.4M=4MB (32Mb) +cw02.menu.FlashSize.4M.build.flash_size=4MB +cw02.menu.FlashSize.2M=2MB (16Mb) +cw02.menu.FlashSize.2M.build.flash_size=2MB +cw02.menu.FlashSize.2M.build.partitions=minimal + +cw02.menu.UploadSpeed.921600=921600 +cw02.menu.UploadSpeed.921600.upload.speed=921600 +cw02.menu.UploadSpeed.115200=115200 +cw02.menu.UploadSpeed.115200.upload.speed=115200 +cw02.menu.UploadSpeed.256000.windows=256000 +cw02.menu.UploadSpeed.256000.upload.speed=256000 +cw02.menu.UploadSpeed.230400.windows.upload.speed=256000 +cw02.menu.UploadSpeed.230400=230400 +cw02.menu.UploadSpeed.230400.upload.speed=230400 +cw02.menu.UploadSpeed.460800.linux=460800 +cw02.menu.UploadSpeed.460800.macosx=460800 +cw02.menu.UploadSpeed.460800.upload.speed=460800 +cw02.menu.UploadSpeed.512000.windows=512000 +cw02.menu.UploadSpeed.512000.upload.speed=512000 + +cw02.menu.DebugLevel.none=None +cw02.menu.DebugLevel.none.build.code_debug=0 +cw02.menu.DebugLevel.error=Error +cw02.menu.DebugLevel.error.build.code_debug=1 +cw02.menu.DebugLevel.warn=Warn +cw02.menu.DebugLevel.warn.build.code_debug=2 +cw02.menu.DebugLevel.info=Info +cw02.menu.DebugLevel.info.build.code_debug=3 +cw02.menu.DebugLevel.debug=Debug +cw02.menu.DebugLevel.debug.build.code_debug=4 +cw02.menu.DebugLevel.verbose=Verbose +cw02.menu.DebugLevel.verbose.build.code_debug=5 + +############################################################## + esp32thing.name=SparkFun ESP32 Thing esp32thing.upload.tool=esptool @@ -2275,6 +2275,63 @@ wipy3.menu.DebugLevel.verbose.build.code_debug=5 ############################################################## +wesp32.name=Silicognition wESP32 + +wesp32.upload.tool=esptool +wesp32.upload.maximum_size=1310720 +wesp32.upload.maximum_data_size=327680 +wesp32.upload.wait_for_upload_port=true + +wesp32.serial.disableDTR=true +wesp32.serial.disableRTS=true + +wesp32.build.mcu=esp32 +wesp32.build.core=esp32 +wesp32.build.variant=wesp32 +wesp32.build.board=WESP32 + +wesp32.build.f_cpu=240000000L +wesp32.build.flash_mode=dio +wesp32.build.flash_size=4MB +wesp32.build.boot=dio +wesp32.build.partitions=default +wesp32.build.defines= + +wesp32.menu.FlashFreq.80=80MHz +wesp32.menu.FlashFreq.80.build.flash_freq=80m +wesp32.menu.FlashFreq.40=40MHz +wesp32.menu.FlashFreq.40.build.flash_freq=40m + +wesp32.menu.UploadSpeed.921600=921600 +wesp32.menu.UploadSpeed.921600.upload.speed=921600 +wesp32.menu.UploadSpeed.115200=115200 +wesp32.menu.UploadSpeed.115200.upload.speed=115200 +wesp32.menu.UploadSpeed.256000.windows=256000 +wesp32.menu.UploadSpeed.256000.upload.speed=256000 +wesp32.menu.UploadSpeed.230400.windows.upload.speed=256000 +wesp32.menu.UploadSpeed.230400=230400 +wesp32.menu.UploadSpeed.230400.upload.speed=230400 +wesp32.menu.UploadSpeed.460800.linux=460800 +wesp32.menu.UploadSpeed.460800.macosx=460800 +wesp32.menu.UploadSpeed.460800.upload.speed=460800 +wesp32.menu.UploadSpeed.512000.windows=512000 +wesp32.menu.UploadSpeed.512000.upload.speed=512000 + +wesp32.menu.DebugLevel.none=None +wesp32.menu.DebugLevel.none.build.code_debug=0 +wesp32.menu.DebugLevel.error=Error +wesp32.menu.DebugLevel.error.build.code_debug=1 +wesp32.menu.DebugLevel.warn=Warn +wesp32.menu.DebugLevel.warn.build.code_debug=2 +wesp32.menu.DebugLevel.info=Info +wesp32.menu.DebugLevel.info.build.code_debug=3 +wesp32.menu.DebugLevel.debug=Debug +wesp32.menu.DebugLevel.debug.build.code_debug=4 +wesp32.menu.DebugLevel.verbose=Verbose +wesp32.menu.DebugLevel.verbose.build.code_debug=5 + +############################################################## + t-beam.name=T-Beam t-beam.upload.tool=esptool @@ -2332,4 +2389,5 @@ t-beam.menu.DebugLevel.info.build.code_debug=3 t-beam.menu.DebugLevel.debug=Debug t-beam.menu.DebugLevel.debug.build.code_debug=4 t-beam.menu.DebugLevel.verbose=Verbose -t-beam.menu.DebugLevel.verbose.build.code_debug=5 \ No newline at end of file +t-beam.menu.DebugLevel.verbose.build.code_debug=5 + diff --git a/variants/wesp32/pins_arduino.h b/variants/wesp32/pins_arduino.h new file mode 100644 index 00000000..1bb2b58b --- /dev/null +++ b/variants/wesp32/pins_arduino.h @@ -0,0 +1,44 @@ +#ifndef Pins_Arduino_h +#define Pins_Arduino_h + +#include + +#define EXTERNAL_NUM_INTERRUPTS 16 +#define NUM_DIGITAL_PINS 40 +#define NUM_ANALOG_INPUTS 16 + +#define analogInputToDigitalPin(p) (((p)<20)?(esp32_adc2gpio[(p)]):-1) +#define digitalPinToInterrupt(p) (((p)<40)?(p):-1) +#define digitalPinHasPWM(p) (p < 34) + +static const uint8_t TX = 1; +static const uint8_t RX = 3; + +static const uint8_t SCL = 4; +static const uint8_t SDA = 2; + +static const uint8_t SS = 5; +static const uint8_t MOSI = 23; +static const uint8_t MISO = 32; +static const uint8_t SCK = 18; + +static const uint8_t A0 = 36; +static const uint8_t A3 = 39; +static const uint8_t A4 = 32; +static const uint8_t A5 = 33; +static const uint8_t A6 = 34; +static const uint8_t A7 = 35; + +static const uint8_t T0 = 4; +static const uint8_t T2 = 2; +static const uint8_t T8 = 33; +static const uint8_t T9 = 32; + +#define ETH_PHY_ADDR 0 +#define ETH_PHY_POWER -1 +#define ETH_PHY_MDC 16 +#define ETH_PHY_MDIO 17 +#define ETH_PHY_TYPE ETH_PHY_LAN8720 +#define ETH_CLK_MODE ETH_CLOCK_GPIO0_IN + +#endif /* Pins_Arduino_h */