@tulip/edge-driver-sdk
v0.1.0-dev.3
Published
This is the user-facing @tulip/edge-driver-sdk package. Note that only the function declarations are included - bundled drivers will only contain references to these provided sdk functions, and the implementation will be injected at runtime.
Downloads
11
Readme
Edge Driver SDK
This is the user-facing @tulip/edge-driver-sdk package. Note that only the function declarations are included - bundled drivers will only contain references to these provided sdk functions, and the implementation will be injected at runtime.
To write your driver, add the @tulip/edge-driver-sdk to your .tsconfig .types array and
reference the SDK functions under the global edgeDriverSdk.
Available functions:
The SDK currently provides functions to
- communicate with Tulip apps (
fireEventandregisterDriverFunction) - handle plug and unplug events, as specified by the manifest (
onPlugEventandonUnplugEvent) - communicate with hardware - we currently support
- serial:
SerialPort - hid:
HidDevice - modbus (rtu):
ModbusRtuClient
- serial:
The SDK also provides several globals that are not otherwise implemented by extism. We currently support:
- timers:
setInterval,clearInterval,setTimeout,clearTimeout
