I'm trying to record video tapes to digital, using this command:
ffmpeg -f v4l2 -video_size 720x480 -i /dev/video2 -channel_layout stereo -f alsa -i hw:1,0 -c:v libx264 -pix_fmt yuv420p -b:v 2M -crf 23 -c:a aac -b:a 128K -to 00:00:30 -preset fast -report tape1.mkv
I get this error:
[alsa @ 0x55ede20aa9e0] cannot open audio device hw:1,0 (Device or resource busy)
hw:1,0: Input/output error
My VCR is plugged into a USB Recording Device.
arecord -l
produces this:
**** List of CAPTURE Hardware Devices ****
card 0: NVidia [HDA NVidia], device 0: CS4206 Analog [CS4206 Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: USB20 [AV TO USB2.0], device 0: USB Audio [USB Audio]
Subdevices: 1/1
Subdevice #0: subdevice #0
I'm not committed to using alsa. I just don't know what else to use to get this to work.
fuser -fv /dev/snd/* /dev/dsp*
Produces this:
Specified filename /dev/dsp* does not exist.
USER PID ACCESS COMMAND
/dev/snd/controlC0: matt 30999 F.... pulseaudio
/dev/snd/controlC1: matt 30999 F.... pulseaudio
VLC can stream the input with audio if I pass this to it:
v4l2:// :input-slave=alsa:// :v4l2-standard=0
But I couldn't figure out how to pass that to ffmpeg.
I could possibly record these videotapes using VLC. But I would prefer to use ffmpeg to do the job.