Commit Graph

2091 Commits

Author SHA1 Message Date
Martijn van Buul 45a7187a6c luaOTA updated to include object form timers (#2752) 2019-05-17 13:13:49 +01:00
Terry Ellison f1b5dfc34e
SDK-3.0 tranche updates (#2757)
includes some dRAM -> iRAM optimisations
2019-05-17 13:04:19 +01:00
Terry Ellison 1990f95740
Updated ROTables 1st tranch (#2742)
Updated ROTables
2019-05-08 14:08:20 +03:00
Terry Ellison e0f3dbed41
Fix 2749 + restore correct user_modules.h (#2750) 2019-05-07 18:49:16 +03:00
Terry Ellison bc61528db7
1st Tranch of SDK 3.0 follow up changes (#2732)
1st Tranche of SDK 3.0 follow up changes
2019-05-01 18:29:11 +01:00
devsaurus b7a99358cc u8g2: fix return value 2019-04-28 21:32:31 +02:00
Arnim Läuger 530c353ff8
Update u8g2 to v2.25.10 (#2735)
* Upgrade u8g2 and add updateDisplayArea bindings

* u8g2 2.25.10

* add displays for 2.24.3 and 2.25.10

* remove workaround for hal pointer and make use of u8x8's user_ptr

* fix doc

* add binding for `updateDisplay()`
2019-04-28 15:45:04 +02:00
Marcel Stör 37f8f6a04a Small overhaul
Fixes #2724
2019-04-19 16:04:10 +02:00
Marcel Stör c50d007f9e Add README
Fixes #2725
2019-04-19 15:51:32 +02:00
Terry Ellison c3e24436f2
Lua string optimisation in file.c + get/put contents methods (#2717)
* Lua string optimisation in file.c + get/put contents methods

* Doc fix: move putcontents() into correct alphabetic order slot in list of static methods
2019-04-11 22:17:00 +01:00
ziggurat29 5a6992c26a added spiffsimg host tools project to msvc build configuration. (#2686) 2019-04-09 14:38:49 +01:00
Gregor Hartmann 9842a8ef83 Add building luac.cross to travis ci builds (#2682)
Add building luac.cross to travis ci builds
2019-04-09 14:37:47 +01:00
Terry Ellison 52b192c603
fix EM:0 error, and other memory leaks, plus minor typos in doc (#2712) 2019-04-08 14:00:30 +01:00
Terry Ellison fc94439b74 crypto.c: Clarify comments on use of userdata for header + context + key opad blocks 2019-04-08 13:57:46 +01:00
Terry Ellison 528973548c fix EM:0 error, and other memory leaks, plus minor typos in doc 2019-04-05 18:23:13 +01:00
Terry Ellison 9a47107920
SDK 3.0 release (#2692)
* Rebaseline firmware to non-OS SDK version 3.0
* Note that SDK version 3.0 introduces the concept of a Flash Partition Table(PT).  This is located at Flash offset 0x10000 in our firmware build.
* The firmware is now PT aware with both LFS and SPIFFS taking their partition size and location from the PT
* A new tool `tools/nodemcu-partition.py` is now used to initialise these data and can also download LFS and SPIFFS images to these partitions.
2019-04-05 16:01:45 +01:00
Nathaniel Wesley Filardo b6cd2c3edd Remove moribund C ds18b20 module (#2492)
Just use Lua speaking OW (via C) instead.
2019-04-05 15:55:07 +01:00
Nathaniel Wesley Filardo f0565ea576 mbedtls bump to 2.7.9 (#2655)
No major fixes, but was looking anyway.

Specifically, to
https://github.com/ARMmbed/mbedtls.git 079e813949251be1e7a9d395abd20b2c63422787
2019-04-05 06:57:02 +02:00
Natalia ab61e9c03a I2C sw driver with support of multiple buses, Slow, Fast, FastPlus, and user-defined speed selection (#2465)
* I2C driver speed-up, i2c.SLOW, i2c.FAST and user-defined speed selection

* - Multiple buses (up to 10) with different speeds on each bus
- Standard(Slow, 100kHz), Fast(400kHz) and FastPlus(1MHz) modes or an 
arbitrary clock speed
- Sharing SDA line over multiple I²C buses to save available pins
- GPIO16 pin can be used as SCL pin, but it does not support clock 
stretching and selected bus will be limited to FAST speed.

* Dynamic memory allocation, error checks, simplification, timing tweaks.

* Separated the code of old driver for better compatibility and simplicity

* Change of driver interface

* Add bus status check in setup(); simplify getDC(); remove unnesessary lines in ACK read/write

* Fix for moved doc file and trailing whitespaces
2019-04-05 06:56:11 +02:00
Terry Ellison 3f5ae99e42
Fix unaligned load/store exception in luaR_findentry (#2702) 2019-03-24 22:47:29 +00:00
Philip Gladstone a90de79c26 Minor fix to allow building of luac.cross.int (#2697)
* Minor fix to allow building of luac.cross.int
* Reapply some changes lost due to merge damage
2019-03-21 09:56:30 +01:00
Javier Peletier 5563b8a8f2 hotfix: fix Makefile BAUDRATE default value for non-Windows OS (#2693) 2019-03-15 08:33:16 +01:00
Marcel Stör 38262e995a
Fix WiFi example 2019-03-09 13:46:30 +01:00
Arnim Läuger ebd147b34f DHT11 read sometimes failed with checksum error (#2679)
* DHT11 read sometimes failed with checksum error.

The code assumed DHT11 devices only ever return zero in the temperature and humidity decimal fraction bytes. The datasheet doesn't guarantee this is the case, and by observation I have noticed that indeed the DHT11 may sometimes return another number, usually close to zero. This means that the code would fail with a checksum error, as the fraction bytes were not included when the checksum was calculated. These bytes are now taken into account and also returned as part of the measurement.

This also means that the related dht.read() function is non-functional. If you have a DHT11 device that returns a non-zero decimal part, dht.read() will interpret it as a DHT22 result and return the wrong measurement. For this reason dht.read() should be retired. This patch does not address this issue.
2019-02-23 22:03:21 +01:00
ziggurat29 f801bf126d fixes #2677 minor syntax issues with some dummy variables that bracket the rodata section (#2678) 2019-02-23 20:49:30 +01:00
ziggurat29 62789da0bb added MSVC project configuration for host-side tools (#2665)
Added MSVC project configuration (@ziggurat29) and support of MinGW (@TerryE) for host-side`luac.cross` tool
2019-02-23 14:09:29 +00:00
Nathaniel Wesley Filardo 30ff0a1620 Raise MQTT_CONNECT_TIMEOUT (#2674)
Should fix https://github.com/nodemcu/nodemcu-firmware/issues/2576
2019-02-19 22:33:25 +01:00
Javier Peletier 6b570e8d57 makefile: add baud rate flash parameter and ESP8285 preset (#2641) 2019-02-18 14:18:47 +01:00
Marcel Stör 5032483a17 Dummy modification to test webhook 2019-02-18 10:48:55 +01:00
Marcel Stör 3119b64d26 Remove self-managed PyFlasher screen shot 2019-02-17 20:40:54 +01:00
Nathaniel Wesley Filardo 1070466feb Revise fifo{,sock} (#2671)
Fixes to #2650:

- Convert fifosock to returning tables containing ctors
- Improve docs
- Add a missed :on("sent", nil) in the http server
2019-02-17 18:32:16 +00:00
sergio d77666c0e8 trailing spaces cleanup (#2659) 2019-02-17 18:26:29 +00:00
Philip Gladstone d75830407e Initial version of code to support multiple hardware timers (#2497)
* Initial version of code to support multiple hardware timers
* MAde the time sinca last tick work again
* Add some documentation to the code
2019-02-16 13:57:59 +01:00
Nathaniel Wesley Filardo dcc1ea2a49 A generic fifo and fifosock wrapper, under telnet and http server (#2650)
* lua_modules/fifo: a generic queue & socket wrapper

One occasionally wants a generic fifo, so here's a plausible
implementation that's reasonably flexible in its usage.

One possible consumer of this is a variant of TerryE's two-level fifo
trick currently in the telnetd example.  Factor that out to fifosock for
more general use.

* lua_examples/telnet: use factored out fifosock

* lua_modules/http: improve implementation

Switch to fifosock for in-order sending and waiting for everything to be
sent before closing.

Fix header callback by moving the invocation of the handler higher

* fifosock: optimistically cork and delay tx

If we just pushed a little bit of data into a fifosock that had idled,
wait a tick (1 ms) before transmitting.  Hopefully, this means that
we let the rest of the system push more data in before we send the first
packet.  But in a high-throughput situation, where we are streaming data
without idling the fifo, there won't be any additional delay and we'll
coalesce during operation as usual.

The fifosocktest mocks up enough of tmr for this to run, but assumes
an arbitrarily slow processor. ;)
2019-02-16 13:51:40 +01:00
Arnim Läuger d7da14d69e MQTT: print deprecation message regardless of autoreconnect value (#2668) 2019-02-14 23:32:16 +01:00
Lukáš Voborský 27e9e6c085 Fix to telnet Lua example and ftpserver Lua module in consequence of PR #2603 (#2654) 2019-02-13 06:49:45 +01:00
ziggurat29 0c7758a555 Fix occasional luac.cross crash (#2661)
A block of memory is accessed after having been freed. This was obscured by the fact that 'oBuf' is a pointer into the middle of the block 'dynamicTables', so when dynamicTables is freed, oBuf is pointing to freed memory. Occasionally, luac.cross would crash because of this.
2019-02-12 22:30:54 +01:00
Marcel Stör f0a240aa46 Only process relative links on RTD 2019-02-11 22:52:26 +01:00
prog1407 30744afd24 Fix typo in example (parameters were mixed) (#2658) 2019-02-11 09:47:14 +01:00
Marcel Stör 5514475ab0 Adjust docs path 2019-02-05 21:07:21 +01:00
Mark Schlögel 83cb35da52 Patch 1 (#2646)
Increase http timeout 10s -> 60s
2019-02-05 20:59:35 +01:00
Nathaniel Wesley Filardo 06367cb71c Tell the truth about DNS in TLS module (#2643)
Purge the never-functional :dns() method, but document the DNS callback
in :on().

Fixes #2640
2019-02-02 22:08:21 +01:00
Nathaniel Wesley Filardo e87aef8328 Wrap CC invocations in uzlib (#2642) 2019-02-01 21:32:22 +00:00
Arnim Läuger 09533fdf23 set default value for summary var to unbreak standalone builds (#2618) 2019-01-24 21:29:32 +01:00
Nathaniel Wesley Filardo 0e89fb24ba Expunge integer timers (#2603) 2019-01-22 22:59:41 +01:00
devsaurus 6f3f1126d6 fix example 2019-01-20 12:46:53 +01:00
Javier Peletier 386867e2fd ESP8266: fix memory leak in encoder.fromHex and avoid use luaM_free (#2617) 2019-01-20 12:45:30 +01:00
galjonsfigur 5d2bb87ceb Updated FatFS from 0.12a to 0.13c (#2608)
Files changed only by the author of FatFS (only updated to new version):

- 00history.txt
- 00readme.txt
- ff.c
- ff.h
- ffunicode.c
- diskio.h
- integer.h
- files in `option` folder except `syscall.c`

Changes:
- removed option folder (now everything is in ffunicode.c)
- modified Makefile to support new version of FatFS
- removed syscall.c and modified ffsystem.c from FatFS author instead
- modified files: diskio.c, ffconf.h to mimic changes from new version
- modified files: fatfs_config.h, myfatfs.c
because of changes of configuration keywords in 0.13 version
- removed empty lines from beginning of files:
fatfs_prefix_lib.h, myfatfs.c, sdcard.c
- changed version number in documentation
2019-01-16 22:30:42 +01:00
Nathaniel Wesley Filardo 6e95d74fbd Update TLS protocol support (#2587)
* Update TLS protocol support

TLS1.0 is past PCI's EOL; BEAST is no more
Enable elliptic curve key exchanges
	Do not enable the smallest ECs for security
	Do not enable the largest ECs for computational time
	Do not enable 25519 (sad) because it doesn't go across the wire
Drop non-PFS key exchanges
Drop ARC4, Blowfish, DES, genprime, XTEA code
Drop renegotiation support completely
	It takes so much heap that it's not likely to work out well

Tidy handling of SSL_BUFFER_SIZE

Update docs
Drop mention of startcom, since they are no more, for letsencrypt

* Update mbedtls to 2.7.7

Preserve our vsnprintf and platform hacks

* Introduce TLS maximum fragment size knob

Reduce buffer size to 4Ki by default and advertize that.  That's the
largest we can advertize with the TLS MFL extension, so there's no
point in making them larger.  The truly adventurous can re-raise
SSL_BUFFER_SIZE and undefine the SSL_MAX_FRAGMENT_LENGTH_CODE and get
back to the earlier behavior.

* Default to mbedTLS debug with DEVELOP_VERSION
2019-01-15 17:02:32 +01:00
Javier Peletier c6653b5921 fix number2integer conversion in ESP8266 for floating-point builds (#2609) 2019-01-15 13:00:37 +00:00