Moddable SDK 4.4
This release contains improvements to the Moddable SDK made between January 3, 2024 and February 1, 2024.
Highlights of this release include:
- Moddable Display. Our latest hardware is also our most beautiful. Fully supported in this release.
- Web Streams. Help explore the feasibility and potential of this powerful web standard on embedded devices.
- OpenAI text-to-speech provides another high quality option that's easy to add to projects.
- Bosch BME68x Visualizers for round displays (works in the simulator too). Learn how to use outline graphics to creatively visualize sensor data.
- Many low-level improvements for nRF52 ports. The port that powers our ultra-low energy Moddable Four is more capable than ever.
New Hardware: Moddable recently launched the Moddable Display product line. Moddable Display is the beautiful way to bring your latest embedded JavaScript project from the workbench to the real world.
Documentation: All of the Moddable SDK documentation is available to read on moddable.com. We recently moved the site to a new hosting provider so browsing the documentation is fast.
Reminder: ESP-IDF v5.1.2 is now recommended for ESP32 development. Please see the January 2024 Release Notes for details on how to update.
Release Details
- Moddable Display
- Build build targets to support all Moddable Display products
- Documentation
- New Bosch BME68x Visualizers for sensor (temperature, humidity, pressure) on round display
- Check out the video demo
- Core host with four different visualizers implemented as mods
- Great example of using outline rendering to build an advanced UI
- See readme for details and build instructions
- Experimental web streams implementation for embedded (!!)
- Effort to study feasibility of standard web streams on embedded
- Modified version of WHATWG reference implementation
- Includes examples using
fetch()
, ECMA-419 Digital IO, and ECMA-419 touch sensor - Conformance verified at better than 99% using Web Platform Tests.
- See the readme for more information
- Modules
- OpenAI text-to-speech support using streaming MP3 audio. (Contributed by @stc1988)
- New
AW3641
flash-light driver (with example). Works with M5Stack Core-S3. (contributed by @NW-Lab) ls013b4dn04
display driver support for 180 degree rotation- Works with Moddable Four and Moddable Display 4
- Jog dial adjusts direction based on screen rotation
- Accelerometer adjusts direction based on screen rotation
- Works with Moddable Four and Moddable Display 4
structuredClone()
fix for TypedArray under XS 14.3- Implement
TextDecoder
special case for invalid UTF-8 data on flush (for compatibility with Web Streams tests) - Streaming JSON parser
- Major documentation update with cookbook and reference sections
- Eliminated timezone dependency in unit tests
- MQTT client
- Keep-alive improvements to eliminate mistaken disconnects
- Uses elapsed-time rather than time-of-date for keep-alive timeouts
- Support TLS device certificates for Node-RED MCU Edition
- ECMA-419
- TCP socket on macOS no longer tries to look-up IP addresses using DNS. Fixes connection failures.
- TLS socket now uses normative module specifier
embedded:io/socket/tcp/tls
- HTTP server (listener) example fix for missing request body (reported by @stc1988) #1298
- MQTT client
- Now accepts buffer for
read()
(in addition to number, as before) - Keep-alive improvements to eliminate mistaken disconnects
- Uses elapsed-time rather than time-of-date for keep-alive timeouts
- Now accepts buffer for
- XS
xst
(XS test tool)- Uses
fdlibm
for certain functions of theMath
object to guarantee exact results across all platforms test (details).fdlibm
is recommended, but not required, by ECMA-262. - Supports Fuzzilli on Linux builds (for cloud fuzzing!) (contributed by @raphdev)
- On macOS and Windows now supports Memory and Undefined Behavior sanitizers (contributed by @raphdev)
- Uses
- Bug fixes for issues detected by fuzzing
- Fix infinite loop in Regular Expression's with nested greedy quantifiers
- Fix crash calling
super()
from within an arrow function - If
SharedArrayBuffer
allocation fails, there was a potential to crash on the next garbage collection. Fixed. - Consistent out-of-memory handling via
fxAbort()
- JavaScript parser previously threw exception
dtoa
library previously ignored allocation failures
- xsbug
- Crash on surrogate pairs split across buffers fixed
- REPL now ignores debugger statements, as it does other breaks
- Devices
- ESP32
- nRF52
- Support for Serial 7E1 and 7O1 modes
- Optional pull-up on receive pin for serial
- Supports multiple devices on the same I²C bus
- Report address of mods flash partition from
mcconfig
using-t modLocation
- Free SPI buffers on
close()
- Instrumented builds working again
- Fix date to conversion for New Year's Day on ESP8266, nRF52, Raspberry Pi Pico, and QCA4020 (off by one error in
modGmTime
).
- Tools
- New mchex tool to convert any file to the Intel Hexadecimal Object File Format (.hex)
mcconfig
for simulator now supports-t xsbug
to debug without re-building
- Documentation
- Timer
- Added details of
this
in callbacks - Detailed description of initial and repeat intervals
- Added details of
- Timer
- Examples
- Timer example updated with schedule and unschedule
- Moddable Four first-run app doesn't try to sleep in debug builds (deep sleep is unavailable in debug builds)
- TypeScript
Contact Us
If you have questions or suggestions about anything here, please reach out:
- Start a new Discussion on our GitHub repository
- Drop by our Gitter to chat
- Contact us on Twitter at @moddabletech