.net-core - Groovie Gorilla and GPIO
问题描述
I want to use RaspberryIO library with dotnet core version 3.1 on Ubuntu 20.10. When it comes to use
Pi.Init<BootstrapWiringPi>();
I got error:
Unhandled exception. System.DllNotFoundException: Unable to load shared library 'libwiringPi.so.2.52' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: liblibwiringPi.so.2.52: cannot open shared object file: No such file or directory
The same code works perfectly on Raspbian.
I use: Raspberry Pi 4
解决方案
就我而言(Rpi3 + Ubuntu 20.04 x64 + dotnet core 3.1):
- 克隆https://github.com/WiringPi/WiringPi
- 建造
- 将 libwiringPi.so.2.60 和 gpio 复制到 app 文件夹
- 将 libwiringPi.so.2.60 重命名为 libwiringPi.so.2.52
和 Pi.Init < BootstrapWiringPi >( ); 与 TestLedBlinking() 是工作。
推荐阅读
- reactjs - 开玩笑时,应用程序不会在 history.push 上重新渲染
- sql - PostgreSQL - 在结束分隔符之前提取字符串
- c# - 为 .NET Core 类库项目选择框架版本 - Visual Studio 2019
- android - 无法获取要在 android kotlin 中加载的列表
- r - 在R中将月度数据转换为季度
- r - 相当于使用 sparklyr 的 spark 表的“str()”(描述数据帧)
- reactjs - 无法在 ubuntu 上的 reactotron 中订阅 react-redux 状态
- server - minecraft:如何在选择中获取块的坐标
- amazon-web-services - AssumeRoleSaml 会话有效期多久?
- python - 将变量从一个文件导入另一个文件时遇到问题