为了账号安全,请及时绑定邮箱和手机立即绑定

请问这个错误是apache权限导致的吗?

请问这个错误是apache权限导致的吗?

dragon33 2017-12-30 18:38:53
PHP Fatal error: Uncaught exception 'RuntimeException' with message 'fopen (/sys/class/gpio/export): failed to open stream: Permission denied' in /home/pi/vendor/piphp/gpio/src/FileSystem/FileSystem.php:53\nStack trace:\n#0 /home/pi/vendor/piphp/gpio/src/FileSystem/FileSystem.php(14): PiPHP\\GPIO\\FileSystem\\FileSystem->exceptionIfFalse(false)\n#1 /home/pi/vendor/piphp/gpio/src/FileSystem/FileSystem.php(39): PiPHP\\GPIO\\FileSystem\\FileSystem->open('/sys/class/gpio...', 'w')\n#2 /home/pi/vendor/piphp/gpio/src/Pin/Pin.php(115): PiPHP\\GPIO\\FileSystem\\FileSystem->putContents('/sys/class/gpio...', 18)\n#3 /home/pi/vendor/piphp/gpio/src/Pin/Pin.php(55): PiPHP\\GPIO\\Pin\\Pin->writePinNumberToFile('/sys/class/gpio...')\n#4 /home/pi/vendor/piphp/gpio/src/Pin/Pin.php(39): PiPHP\\GPIO\\Pin\\Pin->export()\n#5 /home/pi/vendor/piphp/gpio/src/Pin/InputPin.php(19): PiPHP\\GPIO\\Pin\\Pin->__construct(Object(PiPHP\\GPIO\\FileSystem\ \FileSystem), 18)\n#6 /home/pi/vendor/piphp/gpio/src/GPIO.php(33): PiPHP\\GPIO\\Pin\\InputPin->__construct(Object(PiPHP\\GPIO\\FileSystem\\Fil in /home/pi/vendor/piphp/gpio/src/FileSystem/FileSystem.php on line 53, referer: http://192.168.2.202/
查看完整描述

1 回答

?
蛋肠加辣不要葱

TA贡献43条经验 获得超9个赞

这是php致命错误,应该是你的代码出了bug

查看完整回答
反对 回复 2017-12-30
  • 1 回答
  • 0 关注
  • 1570 浏览
慕课专栏
更多

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信