PI GPIOD Node ECONNREFUSED

Hey Guys,

i tried to write a simple Programm to change the angle of my servo with the "pi gpiod" node on my Raspberry pi. In the debug window i just get the message: "Error:connect ECONNREFUSED 127.0.0.1:102". I hope there is any help for me.

Are you sure that you are using the right IP port? The default appears to be 8888?

Port 102 is a privileged port number and you would have to run gpiod as root to have that.

I use 8888 in the pi gpiod node

But you are trying to connect to port 102 which is clearly wrong. Does the node have a setting for the port? I don't use it so I don't know.

There is a possibility to give the host. Ive got there "localhost" and "8888"

You have to run the pigpiod daemon in a separate terminal session

sudo pigpiod

The node will then connect to that running daemon and it will work (went thru same process myself 4 days ago ) :slight_smile:

Hello cymplecy, where have i to write in the command? In the command window of the rasperry pi?

Yes - launch a terminal and type it in

I get "Can't lock /var/run/pigpio.pid" and "Can't initialise pigpio library"

:frowning:
Is this a standard Pi running Raspbian?

Just noticed that your getting a strange port number - got this message before I fixed mine

image

I can get that error by running the command twice

image

Can you switch off and on again and try it again please?

I restarted the pi and got the error again, after i wrote the command :frowning:

I have the Raspberry Pi 3 Model B Vi 2

restart your pi - dont run the sudo pigpiod command - run this instead and see what it gives

sudo ps aux | grep pigpiod

i think that worked. What should i do now?

Can you post the output of it please :slight_smile:

root 331 7.6 0.1 9976 1636 ? SLsl 16:01 0:39 /usr/bin/pigpiod -l
pi 3006 0.0 0.0 7360 576 pts/0 S+ 16:09 0:00 grep --color=auto pigpiod

So that shows its already running - I wonder what is starting it?

But never mind - at least its running :slight_smile:

So - if you start node-red - are you still getting the ECONNREFUSED localhost:102 error message?

unfortunately yes, i get that error message

I am out of ideas at this point :frowning:
Sorry :frowning: