lebai_sdk 0.3.0 → 0.3.1
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.
- package/lebai_sdk.d.ts +1 -0
- package/lebai_sdk_bg.js +32 -21
- package/lebai_sdk_bg.wasm +0 -0
- package/package.json +1 -1
package/lebai_sdk.d.ts
CHANGED
@@ -75,6 +75,7 @@ export class Robot {
|
|
75
75
|
read_serial(device: string, len: number): Promise<any>;
|
76
76
|
disconnect_modbus(device: string): Promise<void>;
|
77
77
|
set_modbus_timeout(device: string, timeout: number): Promise<void>;
|
78
|
+
set_modbus_retry(device: string, retry: number): Promise<void>;
|
78
79
|
write_single_coil(device: string, pin: string, value: boolean): Promise<void>;
|
79
80
|
write_multiple_coils(device: string, pin: string, values: any): Promise<void>;
|
80
81
|
read_coils(device: string, pin: string, count: number): Promise<any>;
|
package/lebai_sdk_bg.js
CHANGED
@@ -294,24 +294,24 @@ export function version() {
|
|
294
294
|
}
|
295
295
|
}
|
296
296
|
|
297
|
-
function __wbg_adapter_52(arg0, arg1
|
298
|
-
wasm.
|
297
|
+
function __wbg_adapter_52(arg0, arg1) {
|
298
|
+
wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hdb4683eb74f928aa(arg0, arg1);
|
299
299
|
}
|
300
300
|
|
301
|
-
function
|
302
|
-
wasm.
|
301
|
+
function __wbg_adapter_55(arg0, arg1, arg2) {
|
302
|
+
wasm.closure585_externref_shim(arg0, arg1, arg2);
|
303
303
|
}
|
304
304
|
|
305
305
|
function __wbg_adapter_62(arg0, arg1, arg2) {
|
306
|
-
wasm.
|
306
|
+
wasm.closure665_externref_shim(arg0, arg1, arg2);
|
307
307
|
}
|
308
308
|
|
309
309
|
function __wbg_adapter_65(arg0, arg1) {
|
310
|
-
wasm.
|
310
|
+
wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hc52566fad46e0f14(arg0, arg1);
|
311
311
|
}
|
312
312
|
|
313
|
-
function
|
314
|
-
wasm.
|
313
|
+
function __wbg_adapter_281(arg0, arg1, arg2, arg3) {
|
314
|
+
wasm.closure743_externref_shim(arg0, arg1, arg2, arg3);
|
315
315
|
}
|
316
316
|
|
317
317
|
const __wbindgen_enum_BinaryType = ["blob", "arraybuffer"];
|
@@ -996,6 +996,17 @@ export class Robot {
|
|
996
996
|
const ret = wasm.robot_set_modbus_timeout(this.__wbg_ptr, ptr0, len0, timeout);
|
997
997
|
return ret;
|
998
998
|
}
|
999
|
+
/**
|
1000
|
+
* @param {string} device
|
1001
|
+
* @param {number} retry
|
1002
|
+
* @returns {Promise<void>}
|
1003
|
+
*/
|
1004
|
+
set_modbus_retry(device, retry) {
|
1005
|
+
const ptr0 = passStringToWasm0(device, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
1006
|
+
const len0 = WASM_VECTOR_LEN;
|
1007
|
+
const ret = wasm.robot_set_modbus_retry(this.__wbg_ptr, ptr0, len0, retry);
|
1008
|
+
return ret;
|
1009
|
+
}
|
999
1010
|
/**
|
1000
1011
|
* @param {string} device
|
1001
1012
|
* @param {string} pin
|
@@ -1600,7 +1611,7 @@ export function __wbg_new_23a2665fac83c611(arg0, arg1) {
|
|
1600
1611
|
const a = state0.a;
|
1601
1612
|
state0.a = 0;
|
1602
1613
|
try {
|
1603
|
-
return
|
1614
|
+
return __wbg_adapter_281(a, state0.b, arg0, arg1);
|
1604
1615
|
} finally {
|
1605
1616
|
state0.a = a;
|
1606
1617
|
}
|
@@ -1812,33 +1823,33 @@ export function __wbindgen_cb_drop(arg0) {
|
|
1812
1823
|
return ret;
|
1813
1824
|
};
|
1814
1825
|
|
1815
|
-
export function
|
1816
|
-
const ret = makeMutClosure(arg0, arg1,
|
1826
|
+
export function __wbindgen_closure_wrapper1587(arg0, arg1, arg2) {
|
1827
|
+
const ret = makeMutClosure(arg0, arg1, 582, __wbg_adapter_52);
|
1817
1828
|
return ret;
|
1818
1829
|
};
|
1819
1830
|
|
1820
|
-
export function
|
1821
|
-
const ret = makeMutClosure(arg0, arg1,
|
1831
|
+
export function __wbindgen_closure_wrapper1589(arg0, arg1, arg2) {
|
1832
|
+
const ret = makeMutClosure(arg0, arg1, 582, __wbg_adapter_55);
|
1822
1833
|
return ret;
|
1823
1834
|
};
|
1824
1835
|
|
1825
|
-
export function
|
1826
|
-
const ret = makeMutClosure(arg0, arg1,
|
1836
|
+
export function __wbindgen_closure_wrapper1591(arg0, arg1, arg2) {
|
1837
|
+
const ret = makeMutClosure(arg0, arg1, 582, __wbg_adapter_55);
|
1827
1838
|
return ret;
|
1828
1839
|
};
|
1829
1840
|
|
1830
|
-
export function
|
1831
|
-
const ret = makeMutClosure(arg0, arg1,
|
1841
|
+
export function __wbindgen_closure_wrapper1593(arg0, arg1, arg2) {
|
1842
|
+
const ret = makeMutClosure(arg0, arg1, 582, __wbg_adapter_55);
|
1832
1843
|
return ret;
|
1833
1844
|
};
|
1834
1845
|
|
1835
|
-
export function
|
1836
|
-
const ret = makeMutClosure(arg0, arg1,
|
1846
|
+
export function __wbindgen_closure_wrapper2233(arg0, arg1, arg2) {
|
1847
|
+
const ret = makeMutClosure(arg0, arg1, 666, __wbg_adapter_62);
|
1837
1848
|
return ret;
|
1838
1849
|
};
|
1839
1850
|
|
1840
|
-
export function
|
1841
|
-
const ret = makeMutClosure(arg0, arg1,
|
1851
|
+
export function __wbindgen_closure_wrapper2259(arg0, arg1, arg2) {
|
1852
|
+
const ret = makeMutClosure(arg0, arg1, 678, __wbg_adapter_65);
|
1842
1853
|
return ret;
|
1843
1854
|
};
|
1844
1855
|
|
package/lebai_sdk_bg.wasm
CHANGED
Binary file
|