This node allows to take picture from standard USB webcam connected to a Raspberry.
It uses the fswebcam package.
Install the fswebcam package on the Raspberry
From your node-red directory:
npm install node-red-contrib-rpi-imagecapture
in the Node-red, Manage palette, Install node-red-contrib-rpi-imagecapture
The fswebcam configuration needs to be defined into a file stored in the Raspberry.
The available options can be found using the fswebcam -help command.
For example :
set "Focus, Auto"=False
set "Focus (absolute)"=7
The path to the configuration file needs to be defined into the node properties.
The picture is captured when a msg arrived into the node.
The captured picture is stored in a Buffer object in msg.payload.capturedImg.