@moddable/typings 9.5.0 → 10.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (164) hide show
  1. package/DS18X20.d.ts +40 -0
  2. package/{embedded_io/system.d.ts → ResourceIterator.d.ts} +4 -9
  3. package/ble/bleclient.d.ts +1 -0
  4. package/ble/bleserver.d.ts +1 -0
  5. package/ble/btutils.d.ts +3 -0
  6. package/ble/connection.d.ts +1 -0
  7. package/ble/gap.d.ts +2 -0
  8. package/ble/gatt.d.ts +4 -0
  9. package/ble/hidclient.d.ts +5 -0
  10. package/ble/sm.d.ts +3 -0
  11. package/captiveportal.d.ts +5 -5
  12. package/commodetto/Poco.d.ts +10 -2
  13. package/commodetto/ReadGIF.d.ts +1 -1
  14. package/commodetto/outline.d.ts +4 -1
  15. package/commodetto/parseRLE.d.ts +1 -1
  16. package/commodetto/readJPEG.d.ts +1 -1
  17. package/config/analog.d.ts +31 -0
  18. package/config/digital.d.ts +32 -0
  19. package/config/dns.d.ts +33 -0
  20. package/config/dnssd.d.ts +31 -0
  21. package/config/files.d.ts +27 -0
  22. package/config/flash.d.ts +27 -0
  23. package/config/httpclient.d.ts +34 -0
  24. package/config/httpsclient.d.ts +34 -0
  25. package/config/httpserver.d.ts +33 -0
  26. package/config/i2c.d.ts +33 -0
  27. package/config/mqtt.d.ts +27 -0
  28. package/config/mqttclient.d.ts +31 -0
  29. package/config/mqttsclient.d.ts +32 -0
  30. package/config/ntp.d.ts +34 -0
  31. package/config/pulsecount.d.ts +30 -0
  32. package/config/pwm.d.ts +30 -0
  33. package/config/serial.d.ts +31 -0
  34. package/config/socket.d.ts +34 -0
  35. package/config/spi.d.ts +31 -0
  36. package/config/storage.d.ts +27 -0
  37. package/config/system.d.ts +27 -0
  38. package/config/tls.d.ts +30 -0
  39. package/config/update.d.ts +27 -0
  40. package/config/wsclient.d.ts +31 -0
  41. package/config/wssclient.d.ts +32 -0
  42. package/crc.d.ts +1 -1
  43. package/dns/server.d.ts +1 -0
  44. package/embedded/RTC/zephyr-builtin.d.ts +48 -0
  45. package/embedded/RTC.d.ts +18 -7
  46. package/embedded/display.d.ts +8 -3
  47. package/embedded/storage/files.d.ts +10 -7
  48. package/embedded/storage/flash.d.ts +2 -2
  49. package/embedded/storage/key-value.d.ts +27 -6
  50. package/embedded/system.d.ts +49 -0
  51. package/embedded_io/_common.d.ts +42 -3
  52. package/embedded_io/analog.d.ts +7 -7
  53. package/embedded_io/audio/in.d.ts +3 -2
  54. package/embedded_io/audio/out.d.ts +12 -4
  55. package/embedded_io/ble/central.d.ts +5 -4
  56. package/embedded_io/ble/peripheral.d.ts +6 -5
  57. package/embedded_io/crypt/digest.d.ts +2 -2
  58. package/embedded_io/digital.d.ts +4 -3
  59. package/embedded_io/digitalbank.d.ts +9 -5
  60. package/embedded_io/i2c.d.ts +9 -6
  61. package/embedded_io/image/in/camera.d.ts +82 -0
  62. package/embedded_io/pulsecount.d.ts +7 -5
  63. package/embedded_io/pwm.d.ts +11 -5
  64. package/embedded_io/serial.d.ts +33 -16
  65. package/embedded_io/socket/listener.d.ts +3 -2
  66. package/embedded_io/socket/tcp/tls.d.ts +41 -12
  67. package/embedded_io/socket/tcp.d.ts +26 -12
  68. package/embedded_io/socket/udp.d.ts +17 -12
  69. package/embedded_io/spi.d.ts +8 -6
  70. package/embedded_network/dns/resolver/udp.d.ts +13 -6
  71. package/embedded_network/dns/server/udp.d.ts +39 -0
  72. package/embedded_network/dnssd.d.ts +9 -7
  73. package/embedded_network/http/client.d.ts +21 -7
  74. package/embedded_network/http/server/route/serversentevents.d.ts +48 -0
  75. package/embedded_network/http/server/route/static.d.ts +41 -0
  76. package/embedded_network/http/server/route/webdav.d.ts +42 -0
  77. package/embedded_network/http/server/route/ws/handshake.d.ts +28 -0
  78. package/embedded_network/http/server.d.ts +27 -6
  79. package/embedded_network/interface/ethernet.d.ts +3 -3
  80. package/embedded_network/interface/wifi/accesspoint.d.ts +2 -2
  81. package/embedded_network/interface/wifi.d.ts +21 -12
  82. package/embedded_network/mdns.d.ts +2 -2
  83. package/embedded_network/mqtt/client.d.ts +55 -16
  84. package/embedded_network/ntp/client.d.ts +16 -8
  85. package/embedded_network/websocket/client.d.ts +47 -28
  86. package/embedded_provider/builtin.d.ts +40 -34
  87. package/file.d.ts +4 -0
  88. package/flash.d.ts +1 -0
  89. package/global.d.ts +0 -3
  90. package/host/default.d.ts +31 -0
  91. package/host/esp32/moddable_six.d.ts +50 -0
  92. package/host/esp32/moddable_two.d.ts +55 -0
  93. package/host/generic.d.ts +47 -0
  94. package/host/index.d.ts +24 -0
  95. package/host/lin.d.ts +30 -0
  96. package/host/mac.d.ts +30 -0
  97. package/host/pebble.d.ts +70 -0
  98. package/host/win.d.ts +30 -0
  99. package/http.d.ts +2 -0
  100. package/mcpack.d.ts +20 -0
  101. package/mdns.d.ts +1 -0
  102. package/modules.d.ts +1 -1
  103. package/mqtt/js.d.ts +22 -4
  104. package/neopixel.d.ts +2 -2
  105. package/onewire.d.ts +31 -0
  106. package/package.json +14 -4
  107. package/pebble/accelerometer.d.ts +5 -5
  108. package/pebble/battery.d.ts +3 -3
  109. package/pebble/button.d.ts +2 -2
  110. package/pebble/compass.d.ts +3 -3
  111. package/pebble/dictation.d.ts +2 -2
  112. package/pebble/global.d.ts +37 -3
  113. package/pebble/health.d.ts +2 -2
  114. package/pebble/location.d.ts +2 -2
  115. package/pebble/message.d.ts +5 -5
  116. package/pebble/piu.d.ts +2 -57
  117. package/pebble/poco.d.ts +2 -2
  118. package/pebble/texture.d.ts +33 -0
  119. package/pebble/touch.d.ts +47 -0
  120. package/ping.d.ts +1 -0
  121. package/pins/analog.d.ts +1 -0
  122. package/pins/audioin.d.ts +1 -0
  123. package/pins/digital.d.ts +1 -0
  124. package/pins/i2c.d.ts +1 -0
  125. package/pins/pwm.d.ts +1 -0
  126. package/pins/rmt.d.ts +1 -0
  127. package/pins/servo.d.ts +1 -0
  128. package/pins/smbus.d.ts +1 -0
  129. package/piu/MC-types.d.ts +231 -97
  130. package/piu/MC.d.ts +2 -1
  131. package/piu/QRCode.d.ts +5 -0
  132. package/piu/RoundRect.d.ts +53 -0
  133. package/piu/SVGImage.d.ts +62 -0
  134. package/piu/Timeline.d.ts +17 -21
  135. package/pococolorcell.d.ts +25 -0
  136. package/pocoqrcode.d.ts +25 -0
  137. package/pocostatic.d.ts +25 -0
  138. package/preference.d.ts +1 -0
  139. package/securesocket.d.ts +1 -0
  140. package/sntp.d.ts +1 -0
  141. package/socket.d.ts +6 -0
  142. package/ssl/session.d.ts +60 -0
  143. package/time.d.ts +1 -1
  144. package/tsconfig.es2024.json +0 -1
  145. package/tsconfig.es2025.json +1 -1
  146. package/web/bluetooth.d.ts +112 -0
  147. package/web/decompressionstream.d.ts +1 -1
  148. package/web/eventsource.d.ts +12 -7
  149. package/web/fetch-streams.d.ts +57 -0
  150. package/web/fetch.d.ts +1 -1
  151. package/web/serial.d.ts +58 -0
  152. package/web/websocket.d.ts +18 -13
  153. package/web/webstorage.d.ts +3 -0
  154. package/web/worker.d.ts +2 -0
  155. package/websocket.d.ts +2 -0
  156. package/wifi.d.ts +1 -0
  157. package/xs.d.ts +52 -5
  158. package/data/location/nmea.d.ts +0 -103
  159. package/data/location/ubx.d.ts +0 -78
  160. package/display.d.ts +0 -68
  161. package/embedded/sensor/Barometer-Humidity-Temperature/BME280.d.ts +0 -102
  162. package/embedded/sensor/Location/GPS.d.ts +0 -96
  163. package/embedded/sensor/Location/IP.d.ts +0 -67
  164. package/pebble/device.d.ts +0 -51
@@ -0,0 +1,27 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type { MQTTClientProvider } from "embedded:network/mqtt/client";
23
+
24
+ interface DeviceNetwork {
25
+ mqtt: MQTTClientProvider;
26
+ }
27
+ }
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ // the manifest of this configuration includes the manifests of these configurations
22
+ /// <reference path="./dns.d.ts" />
23
+ /// <reference path="./socket.d.ts" />
24
+
25
+ declare module "embedded:provider/builtin" {
26
+ import type { MQTTClientProvider } from "embedded:network/mqtt/client";
27
+
28
+ interface DeviceNetwork {
29
+ mqtt: MQTTClientProvider;
30
+ }
31
+ }
@@ -0,0 +1,32 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ // the manifest of this configuration includes the manifests of these configurations
22
+ /// <reference path="./tls.d.ts" />
23
+ /// <reference path="./mqttclient.d.ts" />
24
+ /// <reference path="./dns.d.ts" />
25
+
26
+ declare module "embedded:provider/builtin" {
27
+ import type { MQTTClientProvider } from "embedded:network/mqtt/client";
28
+
29
+ interface DeviceNetwork {
30
+ mqtts: MQTTClientProvider;
31
+ }
32
+ }
@@ -0,0 +1,34 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ // the manifest of this configuration includes the manifests of these configurations
22
+ /// <reference path="./dns.d.ts" />
23
+ /// <reference path="./socket.d.ts" />
24
+
25
+ declare module "embedded:provider/builtin" {
26
+ import type { NTPClientProvider } from "embedded:network/ntp/client";
27
+
28
+ interface DeviceNetwork {
29
+ ntp: DeviceNetworkNTP;
30
+ }
31
+ interface DeviceNetworkNTP {
32
+ client: NTPClientProvider;
33
+ }
34
+ }
@@ -0,0 +1,30 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type PulseCount from "embedded:io/pulsecount";
23
+
24
+ interface Device {
25
+ io: DeviceIO;
26
+ }
27
+ interface DeviceIO {
28
+ PulseCount: typeof PulseCount;
29
+ }
30
+ }
@@ -0,0 +1,30 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type PWM from "embedded:io/pwm";
23
+
24
+ interface Device {
25
+ io: DeviceIO;
26
+ }
27
+ interface DeviceIO {
28
+ PWM: typeof PWM;
29
+ }
30
+ }
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type Serial from "embedded:io/serial";
23
+
24
+ interface Device {
25
+ io: DeviceIO;
26
+ serial: DeviceSerial;
27
+ }
28
+ interface DeviceIO {
29
+ Serial: typeof Serial;
30
+ }
31
+ }
@@ -0,0 +1,34 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type TCP from "embedded:io/socket/tcp";
23
+ import type UDP from "embedded:io/socket/udp";
24
+ import type Listener from "embedded:io/socket/listener";
25
+
26
+ interface Device {
27
+ io: DeviceIO;
28
+ }
29
+ interface DeviceIO {
30
+ TCP: typeof TCP;
31
+ UDP: typeof UDP;
32
+ Listener: typeof Listener;
33
+ }
34
+ }
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type SPI from "embedded:io/spi";
23
+
24
+ interface Device {
25
+ io: DeviceIO;
26
+ spi: DeviceSPI;
27
+ }
28
+ interface DeviceIO {
29
+ SPI: typeof SPI;
30
+ }
31
+ }
@@ -0,0 +1,27 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type keyValue from "embedded:storage/key-value";
23
+
24
+ interface Device {
25
+ keyValue: typeof keyValue;
26
+ }
27
+ }
@@ -0,0 +1,27 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type System from "embedded:system";
23
+
24
+ interface Device {
25
+ system: typeof System;
26
+ }
27
+ }
@@ -0,0 +1,30 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type TLS from "embedded:io/socket/tcp/tls";
23
+
24
+ interface Device {
25
+ io: DeviceIO;
26
+ }
27
+ interface DeviceIO {
28
+ TLS: typeof TLS;
29
+ }
30
+ }
@@ -0,0 +1,27 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:provider/builtin" {
22
+ import type update from "embedded:update";
23
+
24
+ interface Device {
25
+ update: typeof update;
26
+ }
27
+ }
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ // the manifest of this configuration includes the manifests of these configurations
22
+ /// <reference path="./dns.d.ts" />
23
+ /// <reference path="./socket.d.ts" />
24
+
25
+ declare module "embedded:provider/builtin" {
26
+ import type { WebSocketClientProvider } from "embedded:network/websocket/client";
27
+
28
+ interface DeviceNetwork {
29
+ ws: WebSocketClientProvider;
30
+ }
31
+ }
@@ -0,0 +1,32 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ // the manifest of this configuration includes the manifests of these configurations
22
+ /// <reference path="./wsclient.d.ts" />
23
+ /// <reference path="./tls.d.ts" />
24
+ /// <reference path="./dns.d.ts" />
25
+
26
+ declare module "embedded:provider/builtin" {
27
+ import type { WebSocketClientProvider } from "embedded:network/websocket/client";
28
+
29
+ interface DeviceNetwork {
30
+ wss: WebSocketClientProvider;
31
+ }
32
+ }
package/crc.d.ts CHANGED
@@ -29,7 +29,7 @@ declare module "crc" {
29
29
  constructor(polynomial: number, initial_value?: number, reflectInput?: boolean, reflectOutput?: boolean, xorOutput?: number)
30
30
  close(): void
31
31
  checksum(bytes: ByteBuffer): number
32
- reset(): this
32
+ reset(): void
33
33
  }
34
34
  export {CRC8 as default, CRC8, CRC16};
35
35
  }
package/dns/server.d.ts CHANGED
@@ -19,6 +19,7 @@
19
19
  */
20
20
 
21
21
  declare module "dns/server" {
22
+ /** @deprecated Use the ECMA-419 DNS server, embedded:network/dns/server */
22
23
  class Server {
23
24
  constructor(callback: (message: number, value?: string) => string);
24
25
  close(): void;
@@ -0,0 +1,48 @@
1
+ /*
2
+ * Copyright (c) 2026 Moddable Tech, Inc.
3
+ *
4
+ * This file is part of the Moddable SDK Tools.
5
+ *
6
+ * The Moddable SDK Tools is free software: you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation, either version 3 of the License, or
9
+ * (at your option) any later version.
10
+ *
11
+ * The Moddable SDK Tools is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ * GNU General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU General Public License
17
+ * along with the Moddable SDK Tools. If not, see <http://www.gnu.org/licenses/>.
18
+ *
19
+ */
20
+
21
+ declare module "embedded:RTC/zephyr-builtin" {
22
+ import type { PortSpecifier } from "embedded:io/_common";
23
+ import type { RTCConfigureOptions } from "embedded:RTC";
24
+
25
+ // Zephyr's built-in real-time clock is selected by port, its devicetree label, rather than connected to a bus.
26
+ // It does not provide the configuration property.
27
+ export interface ZephyrRTCOptions {
28
+ port: PortSpecifier;
29
+ onAlarm?: (this: ZephyrRTC) => void;
30
+ target?: any;
31
+ }
32
+
33
+ export interface ZephyrRTC extends Disposable {
34
+ target?: any;
35
+ close(): void;
36
+ /** undefined when the time is unavailable, for example because it has not been set */
37
+ get time(): number | undefined;
38
+ set time(value: number);
39
+ configure(options: RTCConfigureOptions): void;
40
+ }
41
+
42
+ const ZephyrRTC: {
43
+ new (options: ZephyrRTCOptions): ZephyrRTC;
44
+ readonly prototype: ZephyrRTC;
45
+ };
46
+
47
+ export default ZephyrRTC;
48
+ }
package/embedded/RTC.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2025 Moddable Tech, Inc.
2
+ * Copyright (c) 2025-2026 Moddable Tech, Inc.
3
3
  *
4
4
  * This file is part of the Moddable SDK Tools.
5
5
  *
@@ -19,25 +19,36 @@
19
19
  */
20
20
 
21
21
  declare module "embedded:RTC" {
22
- import type {PortSpecifier} from "embedded:io/_common";
22
+ export interface RTCConnection {
23
+ io: abstract new (options: any) => object;
24
+ [option: string]: unknown;
25
+ }
23
26
 
24
27
  export interface RTCOptions {
28
+ clock: RTCConnection;
29
+ interrupt?: RTCConnection;
30
+ onAlarm?: (this: RTC) => void;
25
31
  target?: any;
26
- port?: PortSpecifier;
27
- onAlarm?: () => void;
28
32
  }
29
33
 
30
34
  export interface RTCConfigureOptions {
31
35
  alarm?: number;
32
36
  }
33
37
 
34
- export class RTC {
38
+ export interface RTCConfiguration {
39
+ alarm?: number;
40
+ }
41
+
42
+ export class RTC implements Disposable {
43
+ target?: any;
35
44
  constructor(options: RTCOptions);
36
45
  close(): void;
37
- time: number;
46
+ get time(): number | undefined;
47
+ set time(value: number);
38
48
  configure(options: RTCConfigureOptions): void;
49
+ readonly configuration: RTCConfiguration;
50
+ [Symbol.dispose](): void;
39
51
  }
40
- export interface RTC extends Disposable {}
41
52
 
42
53
  export default RTC;
43
54
  }
@@ -30,6 +30,7 @@ declare module "embedded:display" {
30
30
  brightness?: number; // 0-1 range
31
31
  rotation?: 0 | 90 | 180 | 270;
32
32
  format?: typeof Bitmap.RGB565LE | typeof Bitmap.RGB24 | typeof Bitmap.Gray256;
33
+ flip?: "" | "h" | "v" | "hv";
33
34
  }
34
35
 
35
36
  export interface DisplayConfiguration {
@@ -43,9 +44,10 @@ declare module "embedded:display" {
43
44
  y: number;
44
45
  width: number;
45
46
  height: number;
47
+ continue?: boolean; // true to continue updating the same frame buffer
46
48
  }
47
49
 
48
- class Display {
50
+ class Display implements Disposable {
49
51
  constructor(options: DisplayConstructorOptions);
50
52
  close(): void;
51
53
 
@@ -58,12 +60,15 @@ declare module "embedded:display" {
58
60
  send(buffer: ByteBuffer, offset: number, length: number): void;
59
61
  end(): void;
60
62
 
61
- adapInvalid(rectangle: Rectangle): void;
63
+ adaptInvalid(rectangle: Rectangle): void;
62
64
 
63
65
  get width(): number;
64
66
  get height(): number;
67
+
68
+ corner?: number; // circular & roundrect displays
69
+
70
+ [Symbol.dispose](): void;
65
71
  }
66
- interface Display extends Disposable {}
67
72
 
68
73
  export default Display;
69
74
  }
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Copyright (c) 2024-2025 Moddable Tech, Inc.
2
+ * Copyright (c) 2024-2026 Moddable Tech, Inc.
3
3
  *
4
4
  * This file is part of the Moddable SDK Runtime.
5
5
  *
@@ -27,7 +27,7 @@ declare module "embedded:storage/files" {
27
27
  isSymbolicLink(): boolean;
28
28
  }
29
29
 
30
- export class File {
30
+ export class File implements Disposable {
31
31
  // Use Directory.openFile() to create File instances
32
32
  close(): void;
33
33
 
@@ -38,8 +38,8 @@ declare module "embedded:storage/files" {
38
38
  status(): Status;
39
39
  setSize(length: number): void;
40
40
  flush(): void;
41
+ [Symbol.dispose](): void;
41
42
  }
42
- export interface File extends Disposable {}
43
43
 
44
44
  export interface DirectoryOpenFileOptions {
45
45
  path: string;
@@ -54,7 +54,7 @@ declare module "embedded:storage/files" {
54
54
  resolveTarget?: boolean;
55
55
  }
56
56
 
57
- export class Directory {
57
+ export class Directory implements Disposable {
58
58
  // use device.files to access file system root
59
59
  close(): void;
60
60
 
@@ -70,8 +70,11 @@ declare module "embedded:storage/files" {
70
70
  createLink?(path: string, target: string): void;
71
71
  readLink?(path: string): string;
72
72
 
73
- scan(path?: string): IterableIterator<string>;
74
- [Symbol.iterator](): IterableIterator<string>;
73
+ scan(path?: string): IteratorObject<string, undefined, unknown>;
74
+ [Symbol.iterator](): IteratorObject<string, undefined, unknown>;
75
+ [Symbol.dispose](): void;
75
76
  }
76
- export interface Directory extends Disposable {}
77
+
78
+ const root: Directory;
79
+ export default root;
77
80
  }