You can use any android phone as a webcam for your Ubuntu PC by using droidcam.
First download the droidcam app on your android device via the play store
Next install adb on your Ubuntu PC
sudo apt install adb
Follow the instructions to install the droidcam linux client:
On your android phone, enable USB debugging (you need to enable developer mode to do this).
Find the drivers for your device. This page provides links to most manufacturers websites: http://developer.android.com/tools/extras/oem-usb.html#Drivers.
You can also search Google “ADB Drivers for ___”
Plug the device back into computer over USB. If you get a dialog asking “Allow USB Debugging”, you need to tap OK.
Open DroidCam and select the USB option. On the phone you may get a dialog asking “Allow USB Debugging”, you need to tap OK.
Sometimes you need to open “USB Options” from the notification area on the device and pick “PTP” mode for that to show up.
For more information on how to set up droidcam, click here
To use your android phone as a microphone, check out WO Mic.
To install the linux client see this.
You will also need to download the WO Mic app from the playstore.
Theoretically you can use both WO Mic and Droidcam in conjunction to turn your android device into a webcam with a microphone.