代码拉取完成,页面将自动刷新
Looking for TCP? See mbed-tcp-ping-pong.
Tested on ODIN-W2 EVK, but should work on every Mbed OS 5 device that implements the Network Sockets API.
Get both devices on the same WiFi network, or host the server on a publicly available hostname.
Install a recent version of node.js.
Open a terminal.
Navigate to the server-in-node
directory.
Run:
$ node server.js
Note down the IP address of the WiFi interface.
mbed_app.json
and set your connectivity method and WiFi credentials.main.cpp
and set the IP (or hostname) of the server.The Mbed device will set up a UDP socket to the server, and will send 'ping' the server. The server will respond with 'pong'.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。