Re: [pjsip] pjsua is unable to recognize video devices in Linux Raspbian-Jessie (Tzafrir Cohen)

S
SL
Mon, Jun 6, 2016 10:22 PM

Hi :), I am experiencing a problem with video devices recognition by pjsua
running in Raspbian-Jessie, on Raspberry PI 3.

I guess that this problem could be related to a different use of Device Tree
(DT) in Raspbian-Jessie to manage module loading... but I am not sure...

https://www.raspberrypi.org/documentation/configuration/device-tree.md

Can anyone suggest a workaround to this problem to make pjsua work with
raspi camera?

Sample application pjsua shows:

pjsua_vid.c  ..Initializing video subsystem..
openh264.cpp  ...OpenH264 codec initialized
sdl_dev.c !SDL_Init() error: No available video device
colorbar_dev.c !...Colorbar video src initialized with 2 device(s):
colorbar_dev.c  ... 0: Colorbar generator
colorbar_dev.c  ... 1: Colorbar-active

By issuing "vid dev list" command, only colorbar devices are listed.

I am sure that the raspi camera works fine and the same is for monitor because "raspistill -f" bash command shows the live frames captured by raspi camera on the composite input monitor connected to Raspberry.

Starting from a fresh Raspbian-Jessie light image...

sudo apt-get install build-essential automake autoconf libtool libasound2-dev libpulse-dev libssl-dev libsamplerate0-dev libcommoncpp2-dev libccrtp-dev libzrtpcpp-dev libdbus-1-dev libdbus-c++-dev libyaml-dev libpcre3-dev libgsm1-dev libspeex-dev libspeexdsp-dev libcelt-dev

sudo apt-get install libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev libsdl2-mixer-dev

I have then installed by compiling from source without any error the following:

libyuv (last version)
openh264-1.0.0
pjproject-2.5.1

Note that pjproject-2.5.1/pjlib/include/pj/config_site.h
has been added with: #define PJMEDIA_HAS_VIDEO 1

Regarding pjproject configure, being libyuv and openh264 used:

./configure --disable-ffmpeg --disable-floating-point --with-libyuv=/<libyuv_path>/libyuv

In the recent past I have tried to install pjproject on Raspbian-Jessie, using an old Raspberry PI, ffmpeg and x264, making attempts with various flavours of ffmpeg and pjproject releases, even patching pjproject to get ffmpeg2 compatibility, but I had exactely the same problem: raspi camera was never recognized

With old Rspberry PI running pjsua in the previous Raspbian-Wheezy environment (ffmpeg and x264 support enabled) raspi camera was recognized without problem by pjsua

Unfortunately the old Raspberry is too slow to compress video with H264 codec so I need the new Raspberry PI 3, but old Raspbian-Wheezy doesn't work with the new Raspberry PI 3

Thank you in advance for any suggestion to solve Raspbian-Jessie compatibility with pjsua

Let's start from the obvious question: does the camera work with any
other Linux programs? For instance: cheese.

Once it does, maybe worry about pjsip.

Thank you for your answer Tzafrir Cohen, but I suspect you've only read
the first words of my post! Have you received it by the whole? Please
check it above ;)

>> Hi :), I am experiencing a problem with video devices recognition by pjsua >> running in Raspbian-Jessie, on Raspberry PI 3. >> >> I guess that this problem could be related to a different use of Device Tree >> (DT) in Raspbian-Jessie to manage module loading... but I am not sure... >> >> https://www.raspberrypi.org/documentation/configuration/device-tree.md >> >> Can anyone suggest a workaround to this problem to make pjsua work with >> raspi camera? >> >> Sample application pjsua shows: >> >> pjsua_vid.c ..Initializing video subsystem.. >> openh264.cpp ...OpenH264 codec initialized >> sdl_dev.c !SDL_Init() error: No available video device >> colorbar_dev.c !...Colorbar video src initialized with 2 device(s): >> colorbar_dev.c ... 0: Colorbar generator >> colorbar_dev.c ... 1: Colorbar-active >> >> By issuing "vid dev list" command, only colorbar devices are listed. >> >> I am sure that the raspi camera works fine and the same is for monitor because "raspistill -f" bash command shows the live frames captured by raspi camera on the composite input monitor connected to Raspberry. >> >> Starting from a fresh Raspbian-Jessie light image... >> >> sudo apt-get install build-essential automake autoconf libtool libasound2-dev libpulse-dev libssl-dev libsamplerate0-dev libcommoncpp2-dev libccrtp-dev libzrtpcpp-dev libdbus-1-dev libdbus-c++-dev libyaml-dev libpcre3-dev libgsm1-dev libspeex-dev libspeexdsp-dev libcelt-dev >> >> sudo apt-get install libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev libsdl2-mixer-dev >> >> I have then installed by compiling from source without any error the following: >> >> libyuv (last version) >> openh264-1.0.0 >> pjproject-2.5.1 >> >> Note that pjproject-2.5.1/pjlib/include/pj/config_site.h >> has been added with: #define PJMEDIA_HAS_VIDEO 1 >> >> Regarding pjproject configure, being libyuv and openh264 used: >> >> ./configure --disable-ffmpeg --disable-floating-point --with-libyuv=/<libyuv_path>/libyuv >> >> In the recent past I have tried to install pjproject on Raspbian-Jessie, using an old Raspberry PI, ffmpeg and x264, making attempts with various flavours of ffmpeg and pjproject releases, even patching pjproject to get ffmpeg2 compatibility, but I had exactely the same problem: raspi camera was never recognized >> >> With old Rspberry PI running pjsua in the previous Raspbian-Wheezy environment (ffmpeg and x264 support enabled) raspi camera was recognized without problem by pjsua >> >> Unfortunately the old Raspberry is too slow to compress video with H264 codec so I need the new Raspberry PI 3, but old Raspbian-Wheezy doesn't work with the new Raspberry PI 3 >> >> Thank you in advance for any suggestion to solve Raspbian-Jessie compatibility with pjsua > Let's start from the obvious question: does the camera work with any > other Linux programs? For instance: cheese. > > Once it does, maybe worry about pjsip. > Thank you for your answer Tzafrir Cohen, but I suspect you've only read the first words of my post! Have you received it by the whole? Please check it above ;)
TC
Tzafrir Cohen
Mon, Jun 6, 2016 11:17 PM

On Tue, Jun 07, 2016 at 12:22:24AM +0200, SL wrote:

Thank you for your answer Tzafrir Cohen, but I suspect you've only read the
first words of my post! Have you received it by the whole? Please check it
above ;)

Yes, I have. However I only quote the relevant parts for my reply.

--
Tzafrir Cohen
icq#16849755              jabber:tzafrir.cohen@xorcom.com
+972-50-7952406          mailto:tzafrir.cohen@xorcom.com
http://www.xorcom.com

On Tue, Jun 07, 2016 at 12:22:24AM +0200, SL wrote: > Thank you for your answer Tzafrir Cohen, but I suspect you've only read the > first words of my post! Have you received it by the whole? Please check it > above ;) Yes, I have. However I only quote the relevant parts for my reply. -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen@xorcom.com +972-50-7952406 mailto:tzafrir.cohen@xorcom.com http://www.xorcom.com