UNPKG

j5e

Version:

j5e is a device first robotics an IoT framework built to levarage the ECMA-419 specification

12 lines (9 loc) 220 B
import Light from "j5e/light"; import LED from "j5e/led"; const light = await new Light(14); const led = await new LED(12, { pwm: true }); light.on("change", function(data) { led.brightness(1 - data/led.HIGH); });