Results 1 to 6 of 6

Thread: Segvault on ARM Linux Raspberry Pi Zero (ARMv6 v6l) in libndi.so.3.8.0

  1. #1
    Registered User
    Join Date
    Mar 2019
    Location
    Germany
    Posts
    4

    Segvault on ARM Linux Raspberry Pi Zero (ARMv6 v6l) in libndi.so.3.8.0

    Hello,

    i'am try to use the linux SDK 3.8.0 for arm-newtek-linux-gnueabihf with ffmpeg.
    if i start the ffmpeg, i got an segvault.
    If i try the same executables on Raspberry Pi Modell 3 (ARMv7), ffmpeg works without any problems.
    I think there's some incompatible code for the Pi Zero (ARMv6) platform in the library libndi.so.3.8.0.

    Is this a known problem? Should older versions of the linux NDI SDK run properly on armv6 v6l?
    Would it be possible to provide a compatible version of the NDI SDK for ARMv6? Usable on Raspberry PI Zero W (BCM2835)?

    Thx


    Spec of known, not working configuration (Pi Zero W):
    # uname -a
    Linux raspberrypi 4.14.98+ #1200 Tue Feb 12 20:11:02 GMT 2019 armv6l GNU/Linux

    # cat /proc/cpuinfo
    processor : 0
    model name : ARMv6-compatible processor rev 7 (v6l)
    BogoMIPS : 997.08
    Features : half thumb fastmult vfp edsp java tls
    CPU implementer : 0x41
    CPU architecture: 7
    CPU variant : 0x0
    CPU part : 0xb76
    CPU revision : 7

    Hardware : BCM2835
    Revision : 9000c1

  2. #2
    Registered User
    Join Date
    Aug 2015
    Location
    london
    Posts
    233
    Certainly as of march 2019, there are discrete libndi library builds for ARM, for v6, v7, v8
    Perhaps you are using a v7 lib on the v6 pi.

    Quote Originally Posted by plandsberg View Post
    Hello,

    i'am try to use the linux SDK 3.8.0 for arm-newtek-linux-gnueabihf with ffmpeg.
    if i start the ffmpeg, i got an segvault.
    If i try the same executables on Raspberry Pi Modell 3 (ARMv7), ffmpeg works without any problems.
    I think there's some incompatible code for the Pi Zero (ARMv6) platform in the library libndi.so.3.8.0.

    Is this a known problem? Should older versions of the linux NDI SDK run properly on armv6 v6l?
    Would it be possible to provide a compatible version of the NDI SDK for ARMv6? Usable on Raspberry PI Zero W (BCM2835)?

    Thx


    Spec of known, not working configuration (Pi Zero W):
    # uname -a
    Linux raspberrypi 4.14.98+ #1200 Tue Feb 12 20:11:02 GMT 2019 armv6l GNU/Linux

    # cat /proc/cpuinfo
    processor : 0
    model name : ARMv6-compatible processor rev 7 (v6l)
    BogoMIPS : 997.08
    Features : half thumb fastmult vfp edsp java tls
    CPU implementer : 0x41
    CPU architecture: 7
    CPU variant : 0x0
    CPU part : 0xb76
    CPU revision : 7

    Hardware : BCM2835
    Revision : 9000c1

  3. #3
    Registered User
    Join Date
    Mar 2019
    Location
    Germany
    Posts
    4
    The last Linux Embedded SDK v3.8 contains only two NDI libraries:
    * 1.) aarch64-newtek-linux-gnu / libndi.so.3.8.0
    * 2.) arm-newtek-linux-gnueabihf / libndi.so.3.8.0
    A distinction within the Platfrom arm-gnueabihf does not exist here.

    Ok, I downloaded the correct Linux SDK (not Embedded) and they contain all the needed libraries.

    Thx

  4. #4
    Registered User
    Join Date
    Mar 2019
    Location
    Germany
    Posts
    4
    i've tried the armv6-rpi-linux-gnueabi/ibndi.so.3.8.0 from linux SDK (not embedded), but always get an segfault on execute ffmpeg on the Pi Zero W platform.

    /usr/lib/arm-linux-gnueabihf/libndi.so.3.8.0: ELF 32-bit LSB pie executable, ARM, EABI5 version 1 (GNU/Linux), dynamically linked, BuildID[sha1]=7a202bc7f9b6a7b168199eb47d1c9c6e9e54a1c0, stripped


    (gdb) r "-framerate 30 -video_size 1280x1024 -i /dev/video0 -f libndi_newtek -pix_fmt uyvy422 FrontCamera"
    Starting program: /usr/bin/ffmpeg "-framerate 30 -video_size 1280x1024 -i /dev/video0 -f libndi_newtek -pix_fmt uyvy422 FrontCamera"
    [Thread debugging using libthread_db enabled]
    Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".

    Program received signal SIGSEGV, Segmentation fault.
    0xb51eded8 in ?? () from /usr/local/lib/arm-linux-gnueabihf/libndi.so.3
    (gdb)


    i also tried the other ones, but always get the same segfault:
    ./armv8-rpi3-linux-gnueabihf/libndi.so.3.8.0: ELF 32-bit LSB pie executable, ARM, EABI5 version 1 (GNU/Linux), dynamically linked, stripped
    ./armv7-rpi2-linux-gnueabihf/libndi.so.3.8.0: ELF 32-bit LSB pie executable, ARM, EABI5 version 1 (GNU/Linux), dynamically linked, stripped


    # uname -a
    Linux raspberrypi 4.14.98+ #1200 Tue Feb 12 20:11:02 GMT 2019 armv6l GNU/Linux

    # cat /proc/cpuinfo
    processor : 0
    model name : ARMv6-compatible processor rev 7 (v6l)
    BogoMIPS : 997.08
    Features : half thumb fastmult vfp edsp java tls
    CPU implementer : 0x41
    CPU architecture: 7
    CPU variant : 0x0
    CPU part : 0xb76
    CPU revision : 7

    Hardware : BCM2835
    Revision : 9000c1


    # lscpu
    Architecture: armv6l
    Byte Order: Little Endian
    CPU(s): 1
    On-line CPU(s) list: 0
    Thread(s) per core: 1
    Core(s) per socket: 1
    Socket(s): 1
    Vendor ID: ARM
    Model: 7
    Model name: ARM1176
    Stepping: r0p7
    CPU max MHz: 1000.0000
    CPU min MHz: 700.0000
    BogoMIPS: 697.95
    Flags: half thumb fastmult vfp edsp java tls
    Last edited by plandsberg; 03-25-2019 at 05:55 PM.

  5. #5
    Registered User
    Join Date
    Mar 2019
    Location
    Germany
    Posts
    4
    Platform for this test is Raspbian stretch upgraded to Debian/Buster (Testing) armhf

  6. #6
    Registered User
    Join Date
    Jul 2019
    Location
    USA
    Posts
    1
    It 'works' for me. I compiled it with the following options:
    Code:
    --prefix=/home/pi/ffmpeg_build --pkg-config-flags=--static --extra-cflags='-I/home/pi/ffmpeg_build/include -I/home/pi/ffmpeg_sources/ndi/include' --extra-ldflags='-L/home/pi/ffmpeg_build/lib -L/home/pi/ffmpeg_sources/ndi/lib/arm-rpi1-linux-gnueabihf' --extra-libs='-lpthread -lm' --bindir=/home/pi/bin --enable-gpl --enable-libass --enable-libfreetype --enable-libx264 --enable-libndi_newtek --enable-mmal --enable-omx-rpi --enable-omx --enable-nonfree
    I have a script that automates it, but you have to download a copy of ffmpeg 4.1. Versions after have NDI support removed because NewTek allegedly violated the GPL in their eyes.

    All that said, performance is extremely limited. The best resolution I've been able to consistently get is 200x150 at 30fps, which is not ideal...

    Here's the command I use to run the binary:
    Code:
    ffmpeg -f v4l2 -framerate 30 -video_size 200x150 -pixel_format yuv420p -i /dev/video0 -f libndi_newtek -pix_fmt uyvy422 ZeroCamera

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •