Skip to content

Commit 1c14e9e

Browse files
authored
Merge branch 'master' into reducei2ciram
2 parents 51e1e34 + 8998932 commit 1c14e9e

File tree

82 files changed

+1687
-733
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+1687
-733
lines changed

.travis.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,6 @@ git:
66
depth: 1
77
submodules: false
88

9-
addons:
10-
apt:
11-
sources:
12-
- ubuntu-toolchain-r-test
13-
packages:
14-
- g++-7
15-
- gcc-7
16-
179
before_install:
1810
- git submodule update --init # no recursive update
1911

@@ -87,7 +79,11 @@ jobs:
8779
- name: "Host tests"
8880
stage: build
8981
script: $TRAVIS_BUILD_DIR/tests/ci/host_test.sh
90-
install: sudo apt-get install valgrind lcov
82+
install:
83+
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
84+
- sudo apt-get update -q
85+
- sudo apt-get install -y --allow-unauthenticated g++-7 gcc-7
86+
- sudo apt-get install valgrind lcov
9187
env: CC=gcc-7 CXX=g++-7
9288

9389
- name: "Docs"
@@ -105,6 +101,10 @@ jobs:
105101
- name: "Mock trivial test"
106102
stage: build
107103
script: $TRAVIS_BUILD_DIR/tests/buildm.sh
104+
install:
105+
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
106+
- sudo apt-get update -q
107+
- sudo apt-get install -y --allow-unauthenticated g++-7 gcc-7
108108
env: CC=gcc-7 CXX=g++-7
109109

110110
- name: "Mac OSX can build sketches"

boards.txt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,10 @@ generic.menu.FlashFreq.40=40MHz
7676
generic.menu.FlashFreq.40.build.flash_freq=40
7777
generic.menu.FlashFreq.80=80MHz
7878
generic.menu.FlashFreq.80.build.flash_freq=80
79+
generic.menu.FlashFreq.20=20MHz
80+
generic.menu.FlashFreq.20.build.flash_freq=20
81+
generic.menu.FlashFreq.26=26MHz
82+
generic.menu.FlashFreq.26.build.flash_freq=26
7983
generic.menu.FlashMode.dout=DOUT (compatible)
8084
generic.menu.FlashMode.dout.build.flash_mode=dout
8185
generic.menu.FlashMode.dout.build.flash_flags=-DFLASHMODE_DOUT
@@ -4758,6 +4762,10 @@ wifinfo.menu.FlashFreq.40=40MHz
47584762
wifinfo.menu.FlashFreq.40.build.flash_freq=40
47594763
wifinfo.menu.FlashFreq.80=80MHz
47604764
wifinfo.menu.FlashFreq.80.build.flash_freq=80
4765+
wifinfo.menu.FlashFreq.20=20MHz
4766+
wifinfo.menu.FlashFreq.20.build.flash_freq=20
4767+
wifinfo.menu.FlashFreq.26=26MHz
4768+
wifinfo.menu.FlashFreq.26.build.flash_freq=26
47614769
wifinfo.menu.eesz.1M64=1MB (FS:64KB OTA:~470KB)
47624770
wifinfo.menu.eesz.1M64.build.flash_size=1M
47634771
wifinfo.menu.eesz.1M64.build.flash_size_bytes=0x100000
@@ -5778,6 +5786,10 @@ wifi_slot.menu.FlashFreq.40=40MHz
57785786
wifi_slot.menu.FlashFreq.40.build.flash_freq=40
57795787
wifi_slot.menu.FlashFreq.80=80MHz
57805788
wifi_slot.menu.FlashFreq.80.build.flash_freq=80
5789+
wifi_slot.menu.FlashFreq.20=20MHz
5790+
wifi_slot.menu.FlashFreq.20.build.flash_freq=20
5791+
wifi_slot.menu.FlashFreq.26=26MHz
5792+
wifi_slot.menu.FlashFreq.26.build.flash_freq=26
57815793
wifi_slot.menu.FlashMode.dout=DOUT (compatible)
57825794
wifi_slot.menu.FlashMode.dout.build.flash_mode=dout
57835795
wifi_slot.menu.FlashMode.dout.build.flash_flags=-DFLASHMODE_DOUT

cores/esp8266/Arduino.h

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -275,10 +275,13 @@ long secureRandom(long);
275275
long secureRandom(long, long);
276276
long map(long, long, long, long, long);
277277

278-
extern "C" void configTime(long timezone, int daylightOffset_sec,
279-
const char* server1, const char* server2 = nullptr, const char* server3 = nullptr);
278+
void configTime(int timezone, int daylightOffset_sec, const char* server1,
279+
const char* server2 = nullptr, const char* server3 = nullptr);
280280

281-
#endif
281+
void configTime(const char* tz, const char* server1,
282+
const char* server2 = nullptr, const char* server3 = nullptr);
283+
284+
#endif // __cplusplus
282285

283286
#include "pins_arduino.h"
284287

cores/esp8266/HardwareSerial.cpp

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,15 @@ void HardwareSerial::end()
6060
_uart = NULL;
6161
}
6262

63+
void HardwareSerial::updateBaudRate(unsigned long baud)
64+
{
65+
if(!_uart) {
66+
return;
67+
}
68+
69+
uart_set_baudrate(_uart, baud);
70+
}
71+
6372
size_t HardwareSerial::setRxBufferSize(size_t size){
6473
if(_uart) {
6574
_rx_size = uart_resize_rx_buffer(_uart, size);
@@ -133,8 +142,8 @@ unsigned long HardwareSerial::detectBaudrate(time_t timeoutMillis)
133142
return detectedBaudrate;
134143
}
135144

136-
size_t HardwareSerial::readBytes(char* buffer, size_t size)
137-
{
145+
size_t HardwareSerial::readBytes(char* buffer, size_t size)
146+
{
138147
size_t got = 0;
139148

140149
while (got < size)
@@ -147,7 +156,7 @@ size_t HardwareSerial::readBytes(char* buffer, size_t size)
147156
got += read(buffer + got, std::min(size - got, avail));
148157
}
149158
return got;
150-
}
159+
}
151160

152161
#if !defined(NO_GLOBAL_INSTANCES) && !defined(NO_GLOBAL_SERIAL)
153162
HardwareSerial Serial(UART0);

cores/esp8266/HardwareSerial.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ class HardwareSerial: public Stream
8888

8989
void end();
9090

91+
void updateBaudRate(unsigned long baud);
92+
9193
size_t setRxBufferSize(size_t size);
9294
size_t getRxBufferSize()
9395
{

0 commit comments

Comments
 (0)