获取信息abuot arduino以太网卡

发布于 2025-01-21 17:43:30 字数 102 浏览 2 评论 0原文

我正在使用通过以太网屏蔽连接到本地网络的Arduino-uno,我正在尝试获取其以太网卡的配置信息(例如:IP地址,子网掩码,网关,DNS)。是否可以使我获取这些数据并将其保存在某些变量中?

I am using an Arduino-uno connected to a local network via an Ethernet Shield and I am trying to get the configuration information of its ethernet card (for example: IP address, subnet mask, gateway, DNS). Is there a function that allows me to get this data and save it in some variables?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

不再让梦枯萎 2025-01-28 17:43:30

您可以使用以太网类设置和查询信息,例如IP地址,子网掩码和类似的信息。

例如,Ethernet.localip()将返回本地IP地址。

更多信息在这里

You can use the Ethernet class to set and query information like IP address, subnet mask and alike.

For example, Ethernet.localIP() will return, well the local IP address.

More information here.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文