How to trigger Python script on Raspberry Pi from Node-Red

0 votes
I'm using Node-Red, hosted on a Raspberry Pi for an IoT project.

How do I trigger a Python script that is on the raspi from Node-Red? I want to run a script that updates the text on an Adafruit LCD shield which is sitting on the Pi

Should I be looking to expose the Python script as a web service somehow?

I'm using a Raspberry Pi B+
Sep 14, 2018 in IoT (Internet of Things) by Annie97
• 2,160 points
3,287 views

1 answer to this question.

0 votes
Node-RED supplies an exec node as part of its core set, which can be used to call external commands, this could call your python script.

More details of how to use it can be found in the info sidebar when a copy is dragged onto the canvas.

Or you could wrap the script as a web service or just a simple TCP socket, both of which have nodes that can be used to drive them.
answered Sep 14, 2018 by Upasana
• 8,620 points

Related Questions In IoT (Internet of Things)

0 votes
1 answer

How to connect Raspberry Pi and lighting the LED?

You might want to try instead to ...READ MORE

answered Jul 23, 2018 in IoT (Internet of Things) by anonymous2
• 4,240 points
684 views
0 votes
1 answer

Display random images from USB on Raspberry Pi

Hey, it's a cool idea! And, since ...READ MORE

answered Nov 28, 2018 in IoT (Internet of Things) by nirvana
• 3,130 points
1,289 views
0 votes
1 answer

Issue with connection on Watson IoT Out node on Raspberry Pi

The frequent disconnects could be due to ...READ MORE

answered Dec 20, 2018 in IoT (Internet of Things) by Shubham
• 13,490 points
1,040 views
0 votes
1 answer
0 votes
1 answer

Display time in a Windows Core IoT app with a clock!

It is possible, but you should understand ...READ MORE

answered Jul 10, 2018 in IoT (Internet of Things) by nirvana
• 3,130 points
1,569 views
0 votes
1 answer

Building Python Server for Secure communication with Raspberry Pi

There could be several ways to add ...READ MORE

answered Jan 11, 2019 in IoT (Internet of Things) by DataKing99
• 8,250 points
2,130 views
0 votes
1 answer

raspberry pi details

I think It's only possible if the ...READ MORE

answered Jan 23, 2019 in IoT (Internet of Things) by Shubham
• 13,490 points
764 views
0 votes
1 answer
0 votes
1 answer
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP