How to stream real time webcam image to node-red at regular interval?

Hello every one, i want to know how to click image one by one from laptop webcam in regular interval so as to feed that image to ibm visual recognition model in node-red? Is there any other node through which we can do this apart from exec node like function node? Please help, I need this for a project that i need to submit within this month.

Where are you running Node-RED? It makes a big difference to how you might get this done.
Check out flows.nodered.org for some tips.
Also did you do a search of these forums, there seems to be quite a few posts asking a very similar question that might have some ideas for you to try.

2 Likes

Iam running node red through a ibm cloud lite account. Iam new to node-red & node.js ,so its getting a bit difficult for me to grasp . If u could suggest please suggest me something.

I suggest you get a Raspberry Pi and camera.
Run Node-RED on the Pi and send the images to your IBM account via MQTT. Do the visual recognition in the IBM cloud by all means, but sending the images there will be a lot simpler from the Pi.
Use this Node here; https://flows.nodered.org/node/node-red-contrib-camerapi

ok, thanks for ur help Sir

Hello Sir, as per the requirement of our project we need to run node-red from ibm cloud and use the laptop/pc webcam to send live photos at regular interval.
Or can u suggest any way by which i can upload images files to node-red at regular interval ?
Any possible method, if available....

Perhaps you could use USB webcam software to save images to your local laptop hard drive.
https://www.yawcam.com/
Then run Node-RED on the laptop to send the images to IBM Cloud at regular interval.

Fine Sir, i will try it. Thanks.. for giving some time for my doubts. :smiley:

@thebaldgeek
I think you initially suggested to use NR locally with PiCam and to send images via mqtt to the IBM cloud. I think this is still a good suggestion, you just do mqtt-to-mqtt. Like

Laptop w PiCam, NR w mqtt client node -----> IBM Cloud w mqtt broker ---> NR w mqtt client node

And then do the stuff in the cloud, like recognition etc etc