Skip to content

Commit 4568d9e

Browse files
committed
add wemos D1 & D1 mini boards
1 parent adb0dac commit 4568d9e

File tree

3 files changed

+278
-0
lines changed

3 files changed

+278
-0
lines changed

boards.txt

+109
Original file line numberDiff line numberDiff line change
@@ -542,3 +542,112 @@ esp210.menu.FlashSize.4M1M.build.spiffs_pagesize=256
542542
#
543543
# wifio.upload.tool=esptool
544544
#
545+
546+
##############################################################
547+
d1.name=WeMos D1
548+
549+
d1.upload.tool=esptool
550+
d1.upload.speed=460800
551+
d1.upload.resetmethod=ck
552+
d1.upload.maximum_size=1044464
553+
d1.upload.maximum_data_size=81920
554+
d1.upload.wait_for_upload_port=true
555+
d1.serial.disableDTR=true
556+
d1.serial.disableRTS=true
557+
558+
d1.build.mcu=esp8266
559+
d1.build.f_cpu=80000000L
560+
d1.build.board=ESP8266_ESP12
561+
d1.build.core=esp8266
562+
d1.build.variant=d1
563+
d1.build.flash_mode=dio
564+
d1.build.flash_size=4M
565+
d1.build.flash_freq=40
566+
d1.build.flash_ld=eagle.flash.4m.ld
567+
d1.build.spiffs_start=0x100000
568+
d1.build.spiffs_end=0x3FB000
569+
d1.build.spiffs_pagesize=256
570+
d1.build.spiffs_blocksize=8192
571+
572+
d1.menu.UploadTool.esptool=Serial
573+
d1.menu.UploadTool.esptool.upload.tool=esptool
574+
d1.menu.UploadTool.espota=OTA
575+
d1.menu.UploadTool.espota.upload.tool=espota
576+
577+
d1.menu.CpuFrequency.80=80 MHz
578+
d1.menu.CpuFrequency.80.build.f_cpu=80000000L
579+
d1.menu.CpuFrequency.160=160 MHz
580+
d1.menu.CpuFrequency.160.build.f_cpu=160000000L
581+
582+
d1.menu.UploadSpeed.460800=460800
583+
d1.menu.UploadSpeed.460800.upload.speed=460800
584+
d1.menu.UploadSpeed.115200=115200
585+
d1.menu.UploadSpeed.115200.upload.speed=115200
586+
d1.menu.UploadSpeed.9600=9600
587+
d1.menu.UploadSpeed.9600.upload.speed=9600
588+
d1.menu.UploadSpeed.57600=57600
589+
d1.menu.UploadSpeed.57600.upload.speed=57600
590+
d1.menu.UploadSpeed.256000.windows=256000
591+
d1.menu.UploadSpeed.256000.upload.speed=256000
592+
d1.menu.UploadSpeed.230400.linux=230400
593+
d1.menu.UploadSpeed.230400.macosx=230400
594+
d1.menu.UploadSpeed.230400.macosx=230400
595+
d1.menu.UploadSpeed.230400.upload.speed=230400
596+
d1.menu.UploadSpeed.512000.windows=512000
597+
d1.menu.UploadSpeed.512000.upload.speed=512000
598+
d1.menu.UploadSpeed.921600=921600
599+
d1.menu.UploadSpeed.921600.upload.speed=921600
600+
##############################################################
601+
d1mini.name=WeMos D1 mini
602+
603+
d1mini.upload.tool=esptool
604+
d1mini.upload.speed=460800
605+
d1mini.upload.resetmethod=ck
606+
d1mini.upload.maximum_size=1044464
607+
d1mini.upload.maximum_data_size=81920
608+
d1mini.upload.wait_for_upload_port=true
609+
d1mini.serial.disableDTR=true
610+
d1mini.serial.disableRTS=true
611+
612+
d1mini.build.mcu=esp8266
613+
d1mini.build.f_cpu=80000000L
614+
d1mini.build.board=ESP8266_ESP12
615+
d1mini.build.core=esp8266
616+
d1mini.build.variant=d1_mini
617+
d1mini.build.flash_mode=dio
618+
d1mini.build.flash_size=4M
619+
d1mini.build.flash_freq=40
620+
d1mini.build.flash_ld=eagle.flash.4m.ld
621+
d1mini.build.spiffs_start=0x100000
622+
d1mini.build.spiffs_end=0x3FB000
623+
d1mini.build.spiffs_pagesize=256
624+
d1mini.build.spiffs_blocksize=8192
625+
626+
d1mini.menu.UploadTool.esptool=Serial
627+
d1mini.menu.UploadTool.esptool.upload.tool=esptool
628+
d1mini.menu.UploadTool.espota=OTA
629+
d1mini.menu.UploadTool.espota.upload.tool=espota
630+
631+
d1mini.menu.CpuFrequency.80=80 MHz
632+
d1mini.menu.CpuFrequency.80.build.f_cpu=80000000L
633+
d1mini.menu.CpuFrequency.160=160 MHz
634+
d1mini.menu.CpuFrequency.160.build.f_cpu=160000000L
635+
636+
d1mini.menu.UploadSpeed.460800=460800
637+
d1mini.menu.UploadSpeed.460800.upload.speed=460800
638+
d1mini.menu.UploadSpeed.115200=115200
639+
d1mini.menu.UploadSpeed.115200.upload.speed=115200
640+
d1mini.menu.UploadSpeed.9600=9600
641+
d1mini.menu.UploadSpeed.9600.upload.speed=9600
642+
d1mini.menu.UploadSpeed.57600=57600
643+
d1mini.menu.UploadSpeed.57600.upload.speed=57600
644+
d1mini.menu.UploadSpeed.256000.windows=256000
645+
d1mini.menu.UploadSpeed.256000.upload.speed=256000
646+
d1mini.menu.UploadSpeed.230400.linux=230400
647+
d1mini.menu.UploadSpeed.230400.macosx=230400
648+
d1mini.menu.UploadSpeed.230400.macosx=230400
649+
d1mini.menu.UploadSpeed.230400.upload.speed=230400
650+
d1mini.menu.UploadSpeed.512000.windows=512000
651+
d1mini.menu.UploadSpeed.512000.upload.speed=512000
652+
d1mini.menu.UploadSpeed.921600=921600
653+
d1mini.menu.UploadSpeed.921600.upload.speed=921600

variants/d1/pins_arduino.h

+86
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
/*
2+
pins_arduino.h - Pin definition functions for Arduino
3+
Part of Arduino - http://www.arduino.cc/
4+
5+
Copyright (c) 2007 David A. Mellis
6+
Modified for ESP8266 platform by Ivan Grokhotkov, 2014-2015.
7+
8+
This library is free software; you can redistribute it and/or
9+
modify it under the terms of the GNU Lesser General Public
10+
License as published by the Free Software Foundation; either
11+
version 2.1 of the License, or (at your option) any later version.
12+
13+
This library is distributed in the hope that it will be useful,
14+
but WITHOUT ANY WARRANTY; without even the implied warranty of
15+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16+
Lesser General Public License for more details.
17+
18+
You should have received a copy of the GNU Lesser General
19+
Public License along with this library; if not, write to the
20+
Free Software Foundation, Inc., 59 Temple Place, Suite 330,
21+
Boston, MA 02111-1307 USA
22+
23+
$Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
24+
*/
25+
26+
#ifndef Pins_Arduino_h
27+
#define Pins_Arduino_h
28+
29+
#define EXTERNAL_NUM_INTERRUPTS 16
30+
#define NUM_DIGITAL_PINS 17
31+
#define NUM_ANALOG_INPUTS 1
32+
33+
#define analogInputToDigitalPin(p) ((p > 0)?NOT_A_PIN:0)
34+
#define digitalPinToInterrupt(p) (((p) < EXTERNAL_NUM_INTERRUPTS)?p:NOT_A_PIN)
35+
#define digitalPinHasPWM(p) (((p) < NUM_DIGITAL_PINS)?p:NOT_A_PIN)
36+
37+
static const uint8_t SDA = 4;
38+
static const uint8_t SCL = 5;
39+
40+
static const uint8_t SS = 15;
41+
static const uint8_t MOSI = 13;
42+
static const uint8_t MISO = 12;
43+
static const uint8_t SCK = 14;
44+
45+
static const uint8_t BUILTIN_LED = 2;//new ESP-12E GPIO2
46+
47+
static const uint8_t A0 = 17;
48+
49+
static const uint8_t D0 = 3;
50+
static const uint8_t D1 = 1;
51+
static const uint8_t D2 = 16;
52+
static const uint8_t D3 = 5;
53+
static const uint8_t D4 = 4;
54+
static const uint8_t D5 = 14;
55+
static const uint8_t D6 = 12;
56+
static const uint8_t D7 = 13;
57+
static const uint8_t D8 = 0;
58+
static const uint8_t D9 = 2;
59+
static const uint8_t D10 = 15;
60+
static const uint8_t D11 = 13;
61+
static const uint8_t D12 = 12;
62+
static const uint8_t D13 = 14;
63+
static const uint8_t D14 = 4;
64+
static const uint8_t D15 = 5;
65+
66+
// These serial port names are intended to allow libraries and architecture-neutral
67+
// sketches to automatically default to the correct port name for a particular type
68+
// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN,
69+
// the first hardware serial port whose RX/TX pins are not dedicated to another use.
70+
//
71+
// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor
72+
//
73+
// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial
74+
//
75+
// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library
76+
//
77+
// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins.
78+
//
79+
// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX
80+
// pins are NOT connected to anything by default.
81+
#define SERIAL_PORT_MONITOR Serial
82+
#define SERIAL_PORT_USBVIRTUAL Serial
83+
#define SERIAL_PORT_HARDWARE Serial
84+
#define SERIAL_PORT_HARDWARE_OPEN Serial
85+
86+
#endif /* Pins_Arduino_h */

variants/d1_mini/pins_arduino.h

+83
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
/*
2+
pins_arduino.h - Pin definition functions for Arduino
3+
Part of Arduino - http://www.arduino.cc/
4+
5+
Copyright (c) 2007 David A. Mellis
6+
Modified for ESP8266 platform by Ivan Grokhotkov, 2014-2015.
7+
8+
This library is free software; you can redistribute it and/or
9+
modify it under the terms of the GNU Lesser General Public
10+
License as published by the Free Software Foundation; either
11+
version 2.1 of the License, or (at your option) any later version.
12+
13+
This library is distributed in the hope that it will be useful,
14+
but WITHOUT ANY WARRANTY; without even the implied warranty of
15+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16+
Lesser General Public License for more details.
17+
18+
You should have received a copy of the GNU Lesser General
19+
Public License along with this library; if not, write to the
20+
Free Software Foundation, Inc., 59 Temple Place, Suite 330,
21+
Boston, MA 02111-1307 USA
22+
23+
$Id: wiring.h 249 2007-02-03 16:52:51Z mellis $
24+
*/
25+
26+
#ifndef Pins_Arduino_h
27+
#define Pins_Arduino_h
28+
29+
#define EXTERNAL_NUM_INTERRUPTS 16
30+
#define NUM_DIGITAL_PINS 17
31+
#define NUM_ANALOG_INPUTS 1
32+
33+
#define analogInputToDigitalPin(p) ((p > 0)?NOT_A_PIN:0)
34+
#define digitalPinToInterrupt(p) (((p) < EXTERNAL_NUM_INTERRUPTS)?p:NOT_A_PIN)
35+
#define digitalPinHasPWM(p) (((p) < NUM_DIGITAL_PINS)?p:NOT_A_PIN)
36+
37+
static const uint8_t SDA = 4;
38+
static const uint8_t SCL = 5;
39+
40+
static const uint8_t SS = 15;
41+
static const uint8_t MOSI = 13;
42+
static const uint8_t MISO = 12;
43+
static const uint8_t SCK = 14;
44+
45+
static const uint8_t BUILTIN_LED = 2;
46+
47+
static const uint8_t A0 = 17;
48+
49+
static const uint8_t D0 = 16;
50+
static const uint8_t D1 = 5;
51+
static const uint8_t D2 = 4;
52+
static const uint8_t D3 = 0;
53+
static const uint8_t D4 = 2;
54+
static const uint8_t D5 = 14;
55+
static const uint8_t D6 = 12;
56+
static const uint8_t D7 = 13;
57+
static const uint8_t D8 = 15;
58+
static const uint8_t D9 = 3;
59+
static const uint8_t D10 = 1;
60+
61+
static const uint8_t D13 = 2;
62+
63+
// These serial port names are intended to allow libraries and architecture-neutral
64+
// sketches to automatically default to the correct port name for a particular type
65+
// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN,
66+
// the first hardware serial port whose RX/TX pins are not dedicated to another use.
67+
//
68+
// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor
69+
//
70+
// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial
71+
//
72+
// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library
73+
//
74+
// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins.
75+
//
76+
// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX
77+
// pins are NOT connected to anything by default.
78+
#define SERIAL_PORT_MONITOR Serial
79+
#define SERIAL_PORT_USBVIRTUAL Serial
80+
#define SERIAL_PORT_HARDWARE Serial
81+
#define SERIAL_PORT_HARDWARE_OPEN Serial
82+
83+
#endif /* Pins_Arduino_h */

0 commit comments

Comments
 (0)