This compiles, links, and starts the RTOS without crashing and burning.
Lua environment does not yet start due to the different task architecture.
Known pain points:
- task implementation needs to be rewritten for RTOS (next up on my TODO)
- secure espconn does not exist, all secure espconn stuff has been #if 0'd
- lwip now built from within the RTOS SDK, but does not appear to include
MDNS support. Investigation needed.
- there is no access to FRC1 NMI, not sure if we ever actually used that
however. Also #if 0'd out for now.
- new timing constraints introduced by the RTOS, all use of ets_delay_us()
and os_delay_us() needs to be reviewed (the tsl2561 driver in particular).
- even more confusion with ets_ vs os_ vs c_ vs non-prefixed versions.
In the long run everything should be switched to non-prefixed versions.
- system_set_os_print() not available, needs to be reimplemented
- all the RTOS rodata is loaded into RAM, as it apparently uses some
constants while the flash isn't mapped, so our exception handler can't
work its magic. This should be narrowed down to the minimum possible
at some point.
- with each task having its own stack in RTOS, we probably need change
flash-page buffers from the stack to the heap in a bunch of places.
A single, shared, page buffer *might* be possible if we limit ourselves
to running NodeMCU in a single task.
- there's a ton of junk in the sdk-overrides now; over time the core code
should be updated to not need those shims
- Stop fighting against the SDK in terms of owning/writing the init_data block.
NodeMCU included a default init_data block because originally the SDK did
not, but by now it's not needed.
- Expose a way to reconfigure the ADC mode from Lua land. With most people
using the cloud builder and not able to change the #define for byte 107
this has been a pain point.
- Less confusion about which init_data has been used. Lua code can now simply
state what mode it wants the ADC to be in, and not worry about the rest of
the init_data complexities such as the init_data changing location due to
flashing with wrong flash_size setting, or doing/not doing a chip-erase
before loading new NodeMCU firmware.
* Change upper limit for timer in `tmr_register` and `tmr_interval` to reflect new limit in SDK 1.5.3.
* Change documentation for `tmr.alarm()`, `tmr.interval()` and `tmr.register()` to match source.
* Improve error reporting to be more descriptive.
* Send a multicast response if it is a QM query
* Use the NSEC record in the style which mDNS demands
* Shuffle the code a bit and allow sending of A response...
* Made the A record work
* Now gets TTLs right and (I think) handles multiple questions
* Fix bug on first write
Pin is 'HIGH' at reset, so we need to pull it down and generate a
reset.
* Move init code to flash section, not needed to be in iram.
* Remove pin choice in API
* Remove lock in ws2812_buffer_write
* Remove naked malloc
* Drop ws2812_writergb
* Drop support of ws2812.buffers to ws2812_writegrb should use ws2812.buffers:write
* Add support for <>3 colors per leds strips (RGBW)
* Remove ICACHE_FLASH_ATTR
* Add static const on _uartData to avoid initialization penalty
* Provide an error code to SNTP error callback.
* Switch SNTP to use ephemeral port.
In case we're being hit by ISP-level thou-shall-not-run-NTP silliness.
Merging as suggested by @TerryE (and squashing at the same time. Turns out that this feature is enabled for this repo).
* Squashed commit of the following:
commit f985f10d9d2ee035f5a6ee6245c60d9904d98cc1
Author: philip <philip@gladstonefamily.net>
Date: Sun Mar 27 21:52:46 2016 -0400
Better mdns code
commit 6ee49ee106
Author: philip <philip@gladstonefamily.net>
Date: Fri Mar 25 23:25:11 2016 -0400
Update the docs
commit 7e455541c6
Author: philip <philip@gladstonefamily.net>
Date: Thu Mar 24 21:58:16 2016 -0400
Add retries and buffer checking to mdns
Get the length right
Now it seems to work
* Might work for combined mode
* Fix crash
* Simplified various bits of code. Changed the LUA interface
Added checking (to some degree) incoming quyery types
Move the defaults to the right place
Added reference to the RFC`
* Corrected CPOL/CPHA relationships
* Simplified to remove duplicated code
* Removed comments about when MISO is sampled. ESP seems to sample MISO on same clock edge as when MOSI is set.