对不起,此内容只适用于English。
对不起,此内容只适用于English。
描述 中断与伺服端的连线。 语法 client.stop() 参数 无参数 回传 无回传值 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 删除所有接收到但还没读取的资料。 flush() 是从 Stream 继承而来。 语法 client.flush() 参数 无参数 回传 无回传值 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 读取从伺服端传送至 Client 的资料。 read() 是从 Stream 继承而来。 语法 client.read() 参数 无参数 回传 byte:从伺服器传送来的资料,如果没有资料可以读取,会回传 -1 See also - Stream.read() 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 回传目前与 Client 连线的伺服端传送过来的资料量,这些资料都是目前可以读取的。 available() 是从 Stream 继承而来。 语法 client.available() 参数 无参数 回传 int:目前可以读取的资料量,以位元组为单位 范例 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 在欲传送的资料最后加上换行字元(’\n’)并且传送到目前与 Client 连线的伺服端。当要传送的资料为数字时,每一位数会被拆开来并各自被当作字元(例:如果要送的资料为 123 ,print() 会把 123 当作 ‘1’, ‘2’, ‘3’ 三个字元)。 语法 client.println() client.println(data) client.println(data, BASE) 参数 data (非必要):要传送的资料,型态可以为 char, byte, int, long 或 string BASE (非必要):BASE 用来指定资料的格式;可用的格式有:BIN (二进位格式)、OCT (八进位格式)、DEC (十进位格式)、HEX (十六进位格式) 回传 byte:回传 println() 传送至伺服端的位元组数量 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed […]
描述 传送资料到 Client 目前连线的伺服端。当要传送的资料为数字时,每一位数会被拆开来并各自被当作字元(例:如果要送的资料为 123 ,print() 会把 123 当作 ‘1’, ‘2’, ‘3’ 三个字元)。 语法 client.print(data) client.print(data, BASE) 参数 data:要传送的资料,型态可以为 char, byte, int, long 或 string BASE (非必要):BASE 用来指定资料的格式;可用的格式有:BIN (二进位格式)、OCT (八进位格式)、DEC (十进位格式)、HEX (十六进位格式) 回传 byte:回传 print() 传送至伺服端的位元组数量 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a […]
描述 传送资料到 Client 目前连线的伺服端。 语法 client.write(data) 参数 data:要传送到伺服端的资料,型态可以为 byte 或 char 回传 byte:回传 write() 传送至伺服端的位元组数量 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in the reference are released into the public domain.
描述 连线到指定的 IP 位址与埠编号。除了使用 IP 位址与埠编号作为指定伺服器的方法,还可以使用网域名称(Domain Name)。 语法 client.connect(ip, port) client.connect(URL, port) 参数 ip:要连线的伺服器的 IP 位址(大小为 4 位元组的阵列) URL:要连线的伺服器的网域名称,型态为 string (例:”www.86duino.com”) port:要连线的伺服器的埠编号,型态为 int 回传 boolean:如果连线成功回传 true,反之回传 false 范例 函式库参考主页面 The text of the 86Duino reference is a modification of the Arduino reference, and is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Code samples in […]