Introduction: [EASY] Remote LED Control With UPNP on Raspberry Pi

every time, i was tried IOT projects with port forwarding on my iptime.

but, that was not well. and i was find some easily way to port forwarding automatically.

the upnp(Universal Plug and Play) has a function for request port forwarding to router and i use it with node js.

I think this project will helping your IOT projects

Step 1: Install Node Js and Project Soruce Code

type this commands in your raspberry pi terminal

sudo apt-get install nodejs # installing node js
sudo apt-get install npm # installing npm (node pakage manager)

you can check node js install succesfully

node -v # version check

and we must be download project source code

github(rpi_onoff_upnp) you can also check the code in this link

cd /home/pi
git clone  https://github.com/keepworking/rpi_onoff_upnp

go to the project directroy and install projects

cd rpi_onoff_upnp
npm install # wait for install finish
npm install onoff # this package using for controling GPIO

try run this project, will print log like this picture

npm start

Step 2: Circuits

connect LED with raspberry pi GPIO 26

Step 3: Testing

you can connect from your smart phone or descktop to this external IPs

it will showing itnerface like this

Step 4: Finish

You will notice that it is much easier to remotely control than port forwarding manually.

I have commented on the feather hub as a source code, so I would like to make it easy to use it. thank you!