Use your Android phone as webcam
Read in this website the complete article:
http://www.dev47apps.com/droidcam/linuxx/
in short:
cd /tmp/
wget https://www.dev47apps.com/files/linux/droidcam_latest.zip
echo "7775e36b5325dc1f32d485eb3cc72fd1 droidcam_latest.zip" | md5sum -c --
unzip droidcam_latest.zip -d droidcam && cd droidcam
sudo ./install
If all goes well, you can ensure the device is installed via
lsmod | grep v4l2loopback_dc
You should see v4l2loopback_dc in the output.
Open up a V4L2 compatible program (VLC player, Skype, Cheese, etc) and you should see DroidCam listed as a video device (or it might be listed as /dev/video).
Start the droidcam
client via the Terminal, or create a launcher if you’re using gnome. There is also a simpler cli client: droidcam-cli
which you can use.
You can change the webcam output resolution as follows:
1. Close any programs using the droidcam webcam. Unload the device driver:
sudo rmmod v4l2loopback_dc
2. Re-load it with new options (WIDTH and HEIGHT are numbers). :
sudo insmod /lib/modules/`uname -r`/kernel/drivers/media/video/v4l2loopback-dc.ko width=WIDTH height=HEIGHT
Standard sizes (Width x Height): 640×480, 960×720, 1280×720 (720p), 1920×1080 (1080p).
3. Restart the droidcam client to reload the settings, and test it out. You can keep changing the resolution.
4. Edit the text file /etc/modprobe.d/droidcam.conf with the new options to make the change stick.
On the phone install the app Droidcam (free) of DroidcamX (paid)
and read here how to connect: