繁体   English   中英

从一台Linux机器到另一台Linux机器传达GPIO状态的最佳方法是什么

[英]What is best way to communicate GPIO state from one linux machine to another

我正在运行一个beaglebone和一个树莓派。 我可以在路径/ sys / class / gpio上轻松阅读gpio。 我可以轻松地使用Web服务器从一台计算机读取gpio状态,但是我想知道是否有更好的底层方法可以在网络上映射gpio文件夹。 我尝试了NFS,但在运行debian wheezy图像的树莓派上得到了这个警告:

pi@raspberrypi ~ $ sudo service nfs-kernel-server restart
[ ok ] Stopping NFS kernel daemon: mountd nfsd.
[ ok ] Unexporting directories for NFS kernel daemon....
[....] Exporting directories for NFS kernel daemon...exportfs: /etc/exports [1]:     Neither 'subtree_check' or 'no_subtree_check' specified for export     "192.168.1.178:/sys/class/gpio".
  Assuming default behaviour ('no_subtree_check').
  NOTE: this default has changed since nfs-utils version 1.0.x

exportfs: /sys/class/gpio does not support NFS export
. ok
[....] Starting NFS kernel daemon: nfsd
[warn] Not starting: portmapper is not running ... (warning).

因此,看起来gpio不支持通过NFS进行映射。 有人知道另一种方式吗?

谢谢! 贾斯汀

我从未尝试过使用NFS,但是我可以使用sshfs进行操作。 参阅我的文章远程设置GPIO

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM