1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-12 01:53:07 +03:00
Commit Graph

4289 Commits

Author SHA1 Message Date
2b7846da5a Fix typo in elf2bin for QOUT binary generation (#6116)
Fixes #6115 as found by @micjoc
2019-05-19 10:45:25 -07:00
b5560759ec Re-add original SD FAT info access methods (#6092)
Fixes #6081

The SD rewrite blanked out some of the internal FAT info.. Restore the
function calls and return proper values.

Because size() is used in many printf()s, we can't just change its
return type to uint64.  Instead, when size is > size-max warn.

Add SD.size64 which can be used by new apps who care about >4GB cards.
Prints a warning if debugging enabled
2019-05-19 08:43:23 -07:00
82adc95d64 Add explicit Print::write(char) (#6101)
W/o this change, file::write('a'); tries to use the template and fails
since char is a basic type.

The reason it is needed is due to pre 2.5.x behavior, File::write(char)
silently was cast to File::write(uint8_t).  With the template write,
though, this is not performed.

* Add Print::write tests and add'l overrides

Ensure that print::write does something sane and doesn't cause a compile
time error about templates when used for Files.

Test using SPIFFS file since Print is an abstract type.
2019-05-18 14:07:13 -07:00
48fc8aff20 Support PIO Wl-T and Arduino -T linking properly (#6095)
The interrupt vectors in IRAM are omitted when there is a PROVIDE
statement in the linker control files when using the PIO method of
-Wl,-T<linkfile>.

Drop the PROVIDES (they're in RAM anyway and not ROM related), and
add the required "-u"s to the PIO build script.

Should have no impact on the Arduino side.

Fixes #6087
2019-05-18 12:51:27 -07:00
968d6fcb0a Make FILE_WRITE append in SD.h wrapper (#6106)
* Make FILE_WRITE append in SD.h wrapper

Fixes #6105

* Update host tests
2019-05-16 17:12:09 -07:00
25c95ac185 Bugfix for stuck in write method of WiFiClient and WiFiClientSecure until the remote peer closed connection (#6104)
* Bugfix - write method of WiFiClient and WiFiClientSecure can stuck forever

* Adjustment of uint8_t to bool to have it clear flag
2019-05-17 00:00:12 +02:00
2dff28abc7 Allow *.cc files to be linked into flash by default (#6100)
Fixes #6096
2019-05-15 11:30:57 -07:00
75f01dc35a Drop X509 after connection, avoid hang on TLS broken (#6065)
* Drop X509 context after successful server verification to save heap space

After completing handshake in BSSL, server is already verified and X509 context is no longer needed. Depending on verification method it save more or less heap space.

* Bugfix: Report not connected if there is no ready data and TLS connection is broken

Added the change for reporting not connected if TLS session is broken and there is no more buffered decrypted data. TLS can be broken if message authentication (MAC) cannot be verified. BearSSL enters BR_SSL_CLOSED state when processing invalid encrypted application data fragment. In such situation the current implementation get stuck forever unless user has own timeout mechanism build on top of WiFiClientSecureBearSSL. This change introduce fail fast via connected() returning false. Further it imply return -1 from read methods indicating broken channel upon which user should perform reconnect if needed.

Fixes #6005
2019-05-15 09:55:06 -07:00
501022404f Minor README fix (#6098)
Fix Linux location typos (lowercase "arduino" and missing "/").

Fixes #6093
2019-05-15 08:38:53 -07:00
818a55f575 device tests: updates for esptool.py (#6084)
Makefile new rule: 'make distclean' removes virtualenv
attempt to use python3 (python2 is still default)
2019-05-14 08:59:46 -07:00
2df33de1e7 Use custom "ElfToBin" builder for PIO (#6091) 2019-05-14 07:42:10 -07:00
eea9999dc5 Revert "Allman now (#6080)" (#6090)
This reverts commit 98125f8860.
2019-05-14 00:09:54 +02:00
98125f8860 Allman now (#6080)
* switch restyle script for CI

* remove confirmation

* restyle with allman
2019-05-13 16:41:34 +02:00
625c3a62c4 Fail if generated JSON file cannot be read (#6076)
To avoid issues as seen in 2.5.1 release where an invalid JSON was
published for a few hours, fail the board script if JQ can't parse the
generated output file.
2019-05-12 08:15:50 -07:00
9b8d4cca52 Moved 'Dropping' print from stdout to stderr in drop_versions.py (#6071)
Printing 'Dropping' debug strings to stdout leads to write in package json.
This moved that to stderr stream.
2019-05-12 06:54:11 -07:00
d65de4aa95 back to 2.6.0-dev (#6072)
* back to dev

* emergency procedure

* per review

* 2.6.0-dev per review
2019-05-11 20:28:09 -04:00
ac02aff575 hide dropping message in json package file (#6070) 2.5.1 2019-05-11 13:29:23 +02:00
024b1c15ca attempt to include submodules in deploy stage (#6067) 2019-05-11 12:08:53 +02:00
479741e2fc Fixing minor grammar typos (#6060) 2019-05-11 09:46:26 +02:00
67b59beff4 Release 2.5.1 (#6059) 2019-05-10 13:26:50 -04:00
5b5e56ad43 ci: deploy package index to esp8266.github.io (#6062)
* ci: deploy package index to esp8266.github.io

* Update deploy_package_index.sh

Fix path for git add
2019-05-10 10:11:33 -04:00
0ab76fcb37 Fix naming of obsolete version removal tool (#6058) 2019-05-07 13:33:50 -07:00
e67cc90b7a Honor timeout in HTTPClient (#6056)
* check for timeout in ESP8266HTTPClient::writeToStreamDataBlock
2019-05-06 21:26:17 +02:00
ac53c2998e Clarify analog output doc for pwm limits (#6051)
* Update reference.rst

Clarify analogWrite and PWM limitations.

* Update reference.rst
2019-05-05 11:22:01 -07:00
95fd7b55e4 Fix default git_ver (#6044) 2019-05-04 11:55:41 +02:00
e071033c3c minor fix for host emulation (#6046) 2019-05-04 10:32:12 +02:00
66c84ec514 fix lwip2 submodule pointer to match actual libraries (#6045) 2019-05-04 02:03:42 +02:00
3dbac1cab4 Update time.cpp (#5835)
* Update time.cpp

Migrate configTime() to use sntp_set_timezone_in_seconds() to correctly allow timezone spec in seconds without rounding

* Add sntp-lwip2.h for timezone function
2019-05-03 22:56:49 +02:00
a67aa569da Test for StreamString SSO bug (#6035) (#6041) 2019-05-03 07:09:32 -07:00
a3c556e490 git clean honors .gitignore, leaving the build tools downloaded by tools/get.py in place - (#6036)
tools/python is missing from .gitignore.
2019-05-02 11:13:57 -07:00
a994b75d75 StreamString SSO bug (#6035)
With SSO implementation in String, StreamString::write generates wrong strings under some circumstances.
Reason is that String::len() returns strlen(sso_buf) if SSO=true but with newly written data (in StreamString::write) the null-termination missing at the time len() is called.
Furthermore, len() is called twice which is inefficient if SSO=true.

* Git ignore

* - StreamString fix

* Remove changes to gitignore

* Fix missing space for 0-terminator lost in conversion
2019-05-02 09:55:43 -07:00
106d6f33a0 MDNS Callback setting needs std::bind parameter by reference instead of by value (#6037) 2019-05-02 07:54:43 -04:00
1750022601 fix switching to static address with lwip2 (#6026)
fix switching to static address with lwip2

For some reason, ip address is not propagated in a visible way for lwip2
when switching to static address (wifi.config()) *after* wifi.begin().

This patch calls lwip-v1.4's netif_set_addr() with the new ip address to set
all things up, just like it is done and right when wifi.begin() is called
after wifi.config().

Also tested when IPv6 is enabled.

fix documentation: It is more natural to set an IP address before starting WiFi
(.. and not after dhcp has started)
fixes #5839
fixes #6024
2019-05-01 12:35:03 +02:00
93ef9e7005 Upgrade to https: serving for JSON, links in docs (#5992)
* Upgrade to https: serving for JSON, links in docs

Fixes #5480

* Update boards.rst documentation

* Update more documentation http: refs to https:

* Remove obsolete staging info

* Drop obsolete versions from JSON programatically

After the final merge is done on the JSON, strip out any named versions
from the final product.

Removing 1.6.5-* and 2.5.0-beta(1,2,3) for now.

* Remove 2.4.0-rc(0/1) from JSON, too
2019-04-30 23:55:03 -07:00
0da6906499 Update DigestAuthorization.ino (#6029)
Fix WiFiClient vs. HttpClient declaration order
2019-05-01 00:47:20 -04:00
33a4c6a5a7 Update StreamHttpClient.ino (#6030)
Fix WiFiClient vs. HttpClient declaration order
Fixes #6028
2019-04-30 18:15:58 -07:00
13589b1ce9 Fix spi slave timing (library SPISlave) (#6022)
* Fix timing of MISO signal

* Fix comment
2019-04-30 17:09:20 -04:00
feb3988b93 Use original ESP8266-specific speeds for SPI speeds (#6023)
Replace the default SPI_FULL/HALF/QUARTER_SPEEDs with ESP8266
appropriate ones taken from the original SD library that @igrr modified.

Fixes #6019
2019-04-29 12:39:26 -07:00
cdb549572d restore proper arduino Client:: & Wire:: API (#5969) 2019-04-26 22:05:46 +02:00
5dd780c571 udp: restore correct address/port when parsing packet (#6011)
do interleave informations on addresses within reception pbuf chain:
before: (data-pbuf) -> (data-pbuf) -> (data-pbuf) -> ... in the receiving order
now: (address+port-info-pbuf -> data-pbuf) -> (address_port-info-pbuf -> data-pbuf) -> ...

address/port informations are updated along with data exposed to user
2019-04-26 20:09:23 +02:00
f6dd826437 Fix MFLN probe and allow returning whether MFLN succeeded or not after a connection. (#6000)
Fixes #5996

* Add extensions to probe message for EC, others

probeMFLN was failing on some connection attempts to servers which only
supported EC based ciphers because it did not include the proper TLS
handshake extensions to list what kinds of ECs it supported.

Add those to the probeMFLN ClientHello message to make probes pass.

* Add client.getMFLNStatus method, returns MFLN state

After a connection it is useful to check whether MFLN negotiation
succeeded.  getMFLNStatus returns a bool (valid only after
client.connect() succeeds, of course) indicating whether the requested
buffer sizes were negotiated successfully.
2019-04-25 12:40:26 -07:00
d9b0480f09 New menu option to minimize BSSL ROM with only RSA (#6006)
* New menu option to minimize BSSL ROM with only RSA

Adds a menu option and define to limit BearSSL to older RSA connection
options.  This saves ~45K program memory and can speed up connections
since EC, while more secure, is significantly slower on the chip.
The supported ciphers are identical to the ones that axTLS supported.

Fixes #6005

* Add default SSLFLAGS(blank) to platform.txt

* Fix unused variable warning

* Add clarifying comment to menu items
2019-04-25 11:13:26 -07:00
72c21feff6 Make chars unsigned by default, matching ESP8266 (#6013)
Force GCC to run with -funsigned-char during host tests  to make
the PC match the default behaviour used by the xtensa GCC port.

As noted in #6010.  Thanks @MichaelBrunn3r
2019-04-24 08:44:36 -07:00
c5efb922ca PlatformIO: generate core_version.h when using feature/stage (#5917)
* platformio: generate core_version.h when using feature/stage

* quote command line

* Modify CPPFLAGS conditionally
2019-04-23 23:36:42 +03:00
4e0e4e4340 Added notice to update submodules to test README (#6008)
Some users didn't know they had to update the submodules before running tests on host (see esp8266/Arduino/issues/5910). Added a notice to prevent wasting time of users new to git
2019-04-23 15:04:26 +02:00
0dd6549c36 ISR code must be in ICACHE_RAM - the check was commited in ab125162bf (#6002) 2019-04-20 15:35:56 +02:00
ab125162bf ISR: check for address in IRAM (#5995) 2019-04-19 06:40:18 -07:00
2c36cfe04d mock on host: compile without rtti (no dynamic_cast<>(), like on native) (#5994)
* mock on host: compile without rtti (no dynamic_cast<>(), like on native)
2019-04-17 18:27:30 +02:00
b4e8b2f6e0 Submodule SoftwareSerial: small footprint reduction. (#5993) 2019-04-17 07:39:59 -07:00
6156a54145 polledTimeout: ensures timeType is unsigned (#5991) 2019-04-16 14:29:50 -04:00