mirror of
https://github.com/chirimen-oh/node-web-gpio.git
synced 2025-01-18 16:08:00 +00:00
docs: use await
This commit is contained in:
parent
aab3397bf9
commit
5842775133
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,7 @@ async function main() {
|
|||
await port.export("out");
|
||||
|
||||
for (;;) {
|
||||
port.write(value);
|
||||
await port.write(value);
|
||||
await new Promise(resolve => setTimeout(resolve, 1e3));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue