Skip to content

Commit 0f7ec91

Browse files
committed
Match script to new asynClientOctet
1 parent e927c3e commit 0f7ec91

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

iocBoot/iocLuaAsyn/scripts/asyn.lua

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,15 @@
44

55
asyn = require("asyn")
66

7-
-- These values get used when the port object is created
8-
WriteTimeout = 4.0
9-
OutTerminator = "\n\n"
10-
InTerminator = "\n"
11-
127
function get_html(port)
138

149
-- Creates a client object linking to the
1510
-- asyn port with the given name. In and
1611
-- Out terminators, as well as timeouts,
1712
-- are copied from the global scope.
18-
p = asyn.client(port)
13+
p = asynOctetClient.find(port, 0, "")
14+
p.InTerminator = "\n"
15+
p.OutTerminator = "\n\n"
1916

2017
-- Write a string across the port
2118
p:write("GET / HTTP/1.0")

0 commit comments

Comments
 (0)