WiringPi c# visual studio 2017
Posted: Fri Mar 08, 2019 8:36 am
Hi there,
I have got this error if I am debugging my c# application: System.DllNotFoundException: can not load DLL libwiringPi.so n: (HRESULT: 0x8007007E)'
What I want is to set outputs on my raspberry Pi high and low with a button, and maybe expand it after that.
What I did is, I added a refrence library of WiringPi.
All commands are recognized in my code, but when I debug I get the error.
It seems like the library is not added well..?
Code:
Hope someone can help me out, I will apprreciate that.
Thanks in advance.
Best regards,
Marc
I have got this error if I am debugging my c# application: System.DllNotFoundException: can not load DLL libwiringPi.so n: (HRESULT: 0x8007007E)'
What I want is to set outputs on my raspberry Pi high and low with a button, and maybe expand it after that.
What I did is, I added a refrence library of WiringPi.
All commands are recognized in my code, but when I debug I get the error.
It seems like the library is not added well..?
Code:
Code: Select all
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using WiringPi;
namespace Relais1._2
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
const int redLedPin = 11;
}
private void button1_Click(object sender, EventArgs e)
{
const int redLedPin = 11;
// GPIO.pinMode(redLedPin, (int)GPIO.GPIOpinmode.Output);
GPIO.digitalWrite(11, (int)GPIO.GPIOpinvalue.High);
}
private void button2_Click(object sender, EventArgs e)
{
const int redLedPin = 11;
//GPIO.pinMode(redLedPin, (int)GPIO.GPIOpinmode.Output);
GPIO.digitalWrite(11, (int)GPIO.GPIOpinvalue.Low);
}
}
}
Thanks in advance.
Best regards,
Marc