Hi,
The pigpio-GPIO official code below fails at
System.DebugLog “pigpio initialisation failed. Did you start the pigpio daemon? E.g. sudo pigpiod”
Please help.
RPi 4B.
pigpio is of 24 june 2020
‘Everything else’ is also of latest version.
Yes, i ran sudo pigpiod.
Tried the Debugger as well as directly with the following result:
(twice, once per gpioInitialise() )
2020-08-15 11:26:55 initCheckPermitted:
±--------------------------------------------------------+
|Sorry, you don’t have permission to run this program. |
|Try running as root, e.g. precede the command with sudo. |
±--------------------------------------------------------+
Permissions set liberal.
A minimal Desktop project with the code:
Window1.Open:
pi = New pigpio
Call pi.gpioInitialise()
and pigpio gpioInitialise is as downloaded:
#If TargetARM And TargetLinux Then
soft Declare Function gpioInitialise Lib “pigpio.so” () as Integer
Var RetVal as Integer
Var s as shell
s = New Shell
s.Execute(“sudo killall pigpiod”)
RetVal = gpioInitialise()
If (RetVal = PI_INIT_FAILED) Then
// pigpio initialisation failed.
//Kill all pigpiod and try to reinitialize
s = New Shell
s.Execute(“sudo killall pigpiod”)
RetVal = gpioInitialise()
If (RetVal < 0) Then
System.DebugLog “pigpio initialisation failed. Did you start the pigpio daemon? E.g. sudo pigpiod”
Else
System.DebugLog “pigpio initialised okay”
End If
Else
// pigpio initialised okay.
System.DebugLog "pigpio initialised okay. Version: " + RetVal.ToString
End If
Return RetVal
#Endif