While not exactly an answer I have figured out the issue. After doing a lot more research i found that the twilio blueprint example i was following was using the OpenCV 2 as the basis for the functions. The only way now to proceed would be to rebuild the script with OpenCV 4 functionality.
Actually, I was think that problem is related to Raspberry Pi but it wasn't.
Somehow, OpenCV doesn't recognize GStreamer library when building OpenCV with cmake and make. Also when I use OpenCV in C++ code stack, OpenCV didn't throw exception when it couldn't find gstreamer support.
I added -D WITH_GSTREAMER=ON flag when I'm using cmake command. You can ...
I have installed OpenCV and and access it with Python 2. However, I'm unable to use OpenCV with Python 3.
With python (Python 2) you have installed python-opencv from the repository which is the Python 2 version. If you try to use it with python3 this cannot work. You have to install OpenCV for the Python 3 version. Just do it with:
rpi ~$ sudo apt install ...
What is a line follower robot?
Line follower or Line detector is an autonomous robot that follows either black line in white are or white line in the black area. The robot must be able to detect a particular line and keep following it. You can implement it by camera or IR.
As you specify, you want to do it by camera. In this case, you have a lot of options....
I've managed to do it!!!
This is really needed:
pi@raspberrypi:~ $ sudo rmmod uvcvideo
pi@raspberrypi:~ $ sudo modprobe uvcvideo nodrop=1 timeout=5000 quirks=0x80
But also, I had to set my webcam FPS prop to a low value.
0. CV_CAP_PROP_POS_MSEC Current position of the video file in milliseconds.
1. CV_CAP_PROP_POS_FRAMES 0-based index of the frame to be ...
Looks like it may have been a USB bandwidth problem. Streaming two webcams at the same time may be beyond the RPi 2's capability, and it would explain why it worked on a laptop. That would also explain why dropping the resolution would allow it to work.