I.MX6-Sabre-Lite questions

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

I.MX6-Sabre-Lite questions

5,438 Views
TomMorrison
Contributor III

Hi,

I am sorry to ask such simple questions, but I am very confused about exactly what I should do next.

I apologize ahead of time, if this is the wrong forum to post these questions, please send me to

the right forum (if any) where I can get my questions asked.

The imx6 on paper looks like an ideal choice (the processing power as well as the video

encoding) for an application that I want to do (Video/Image Encoding (to MP4/JPEG or

whatever format is appropriate).

Anyways, I need to be able to prove that the imx6 is the right tool for the task. So I bought

a Sabre-lite that and camera (but NO LCD) that was delivered today. I only have a console

to it - and a 'demo' of sometype is running...but I can't see anything..

I am currently used to TI toolchain (and in the past - I"ve used a custom LTIB from Freescale (85xx uP),

So where do I get the equivalent (and hopefully a demo program that is already built for what I need

to test).

Thanks in advance (and apologies if this post is inappropriate).

Tom Morrison

Labels (2)
0 Kudos
23 Replies

1,615 Views
daiane_angolini
NXP Employee
NXP Employee

I looked for the command line you are using and I was not able to find it. Could you, please, share it again?

What´s the output for

gst-launch -v --gst-debug=2 mfw_v4lsrc ! mfw_v4lsink

??

0 Kudos

1,615 Views
TomMorrison
Contributor III

original:

   gst-launch mfw_v4lsrc capture-width=1280 capture-height=720 capture-mode=4 ! vpuenc codec=6 bitrate=11111111 \

        ! filesink location=a.264

That does NOT work, but it DOES work when you take oiut the capture-height/width/mode. But, the video is MUCH less

desirable (frame rate is low (very jerky) and the image quality isn't the best.

So, it is functional - but NOT very good quality!

tom

0 Kudos

1,615 Views
daiane_angolini
NXP Employee
NXP Employee

Understand. The problem is not that your camera does not work.

But, that your camera does not work for 1280x720!

So, you CAN access your camera.

The debug process is different :smileywink:

As I known, this feature was included in latest bsp, so, some old BSP did not included it.

UPDATED: Sorry, this feature was included for imx53 (and I tested it over here) But for imx6 I (personally) haven´t tested yet...

What´s your kernel version? And your gstreamer plugin version?

0 Kudos

1,615 Views
TomMorrison
Contributor III

I want to be clear:

I am using the lightly modified freescale release of 8/12 - that can be downloaded  from http://boundarydevices.com/er-6-2012-08-beta-for-i-mx6/:

  • kernel version is Linux freescale 3.0.35 - built 9/5/2012.
  • gsteamer - .10

The default Timesys version (came uSD card that came with board and works but not perfect)t

  • kernel version is Linux nitrogen6x 3.0.15 - built 8/15/12
  • gsteamer - .10

I just used Timesys Linuxlink free web interface and that works just the same as uSD version:

  • kernel version is Linux i.MX6QSABRELite 3.0.15 - built 10/8/12
  • gsteamer - .10

Have any of you had any experience with vpuenc and mp4mux?

tom


0 Kudos

1,612 Views
johnw
Contributor III

On this end, I don’t have a camera to plug into a Sabrelite, but I have been able to record from a webcam on an Ubuntu 12.04 Linux host using the following gst-launch command:

# gst-launch v4l2src num-buffers=50 ! queue ! x264enc ! mp4mux ! filesink location=video.mp4

I can then play the video.mp4 file using mplayer with no problems.

# mplayer video.mp4

This seems to validate the mp4mux element function.

It looks like the issue might be with the camera capture part of the pipeline – have you been able to look into other resolutions on the sensor?

I checked out gst-inspect on the mfw_v4lsrc element and I saw where it indicates that it is important to specify the capture-width and capture-height, but I think the mode is a bit redundant (i.e. capture-mode=4 defines a width and height for the sensor).  Have you tried leaving the width and height out and just specifying capture-mode?

1,612 Views
TomMorrison
Contributor III

Hi John,

It sounds like you proved that mp4mux works on a Ubuntu system.

But, that doesn't help when I am trying to run this directly on the

ER6-1208-Beta Release (Freescale Release via Boundary devices).

There are several different things that go wrong.

   a) the mfw_v4lsrc does NOT have the capture-width/height/mode in its Element properties

        (do a gst-inspect mfw_v4lsrc --> you will see that this capture device does NOT have this)

   b) the capture-mode is NOT just height/width. Its also mode (720P60 (60 FPS progressive...etc)

       You can 'cut out any portion of that image by modifying width/height as well as a starting row/column

        for your capture based upon that...

   c) With the factory Timesys uSD card - it has ALL of those elements.


   d) In ER6-1208-Beta, there is NO x264enc library to put into pipeline

   e) in Both the factory Timesys uSD and ER6-120, using the vpuenc, the mp4mux seems

       to hang (nothing goes to the filesink, in the following line:

      gst-launch mfw_v4lsrc ! vpuenc codec=6 ! mp4mux ! filesink location=a.mp4

      -->a.mp4 is an empty file!

So, I see two issues:

   1) The gstreamer mfw_v4lsrc plugin was NOT built correctly and thus does NOT have capture elements required.

   2) The gstreamer mp4mux plugin seemingly does NOT work with the vpuenc plugin

BTW, I"m the same guy that you wrote to Mark (one of your FAE's in Boston)....I've tried all of what you suggested

still NO JOY!

tom

0 Kudos

1,612 Views
johnw
Contributor III

Hi Tom –

I did put 2 and 2 together and rather than emailing you directly I figured I would try for the community approach. Let me know if you would rather take this off-line.

I’m working on an early access SabreLite with the factory card installed. I have ordered a camera for it and I expect it by COB tomorrow. I’m hoping to replicate your problems and help you through this. It does sound like we are working with early access software on early access hardware.

John

0 Kudos

1,612 Views
TomMorrison
Contributor III

Hi John,

I am OK with community approach.

Just as a recap

  • The factory (Timesys) board.
    • Relatively good two stage process
      • gst-launch mfw_v4lsrc (with height/width/mode) ! vpuenc ! write (raw 264 file)
      • ffmpeg -h 264 -i (raw 264 file) -vcodec copy (mp4 file)
    • I try one stage (I get an EMPTY mp4 file)
      • gst-launch mfw_v4lsrc (h/w/m) ! encode/mp4mux ! filesink (mp4 file)
    • The factory Timesys does NOT have h264parse (to put in between encoding and mp4mux)

0 Kudos

1,615 Views
daiane_angolini
NXP Employee
NXP Employee

Please, review the parameters (mainly resolution) because I´m not sure the exact command can work for your hardware.


VPU lookback (as I remember, it takes picture from camera)

/unit_tests/mxc_vpu_test.out -L "-f 0 -w 640 -h 480"



Preview unit test:

/unit_tests/mxc_v4l2_overlay.out –iw 1280 –ih 720 –ow 640 –oh 480 –m 4 –fr 30 –fg

Capture unit test:

/unit_tests/mxc_v4l2_capture.out –iw 1280 –ih 720 –ow 1280 –oh 720 –m 4 –fr 30 –i 1 ./test.yuv

0 Kudos

1,615 Views
TomMorrison
Contributor III

The camera unit tests seemed to work for the most part. But, it looks like the gst-plugins do NOT

have the associated support (and yes, the modules are loaded).

0 Kudos

1,615 Views
JorgeRama_rezRi
NXP Employee
NXP Employee

Hi Tom,

Certainly this is the right place. The term SABRE has become kind of ambiguous since we have many boards called that. I’m guessing you have the one designed by Boundary Devices, right? If so, I’m not sure if the SD that comes with it (if there’s an SD in the box) is already flashed, so you may need to flash your operating system on it to get it to work. Some of our BSP images support that board, you can download one from here:

http://compass.freescale.net/livelink/livelink?func=ll&objId=226290650&objAction=browse&viewType=1

The documentation is in that link too, you can look at the users guide for info on how to flash it. If you don’t have access to the link, you can use Boundary Devices image, which can be found in their web page. I guess it includes a users guide too.

If you have one of the boards designed by us (our boards have a 700-xxxxx number, is this the case?), all of them come with an SD card already flashed and ready to use, you just have to insert it, connect the USB/UART port of the board to your CPU, configure the serial communication console to a baud rate of 115200 with no flow control and turn on the board. You should see communication with the board as soon as you turn it on.

Please let me know the legend on your board and I’ll guide you on how to proceed.

Best regards.

Jorge.

1,615 Views
TomMorrison
Contributor III

Hi Jorge,

Yes, the Sabre-Lite is the one I am interested in working with. It has an SD (timesys one),

Linux does Boot, but then nothing happens(probably because I have no LCD screen).

I would love to have a freescale boards - perhaps sooner rather than later too...

FYI, I am having an issue connecting to that site (from my home) - I have everything here

to play with this weekend (for some reason, via comcast it cannot resolve compass.freescale.net)

I will try later.

any/all suggestions would be GREATLY appreciated!

tom

0 Kudos

1,615 Views
pejmankalkhoran
Contributor III

Tom,

Did you try connecting it to an HDMI monitor?  The devices are configured to boot to HDMI.

Also, just an FYI, take a look at our blog for many i.mx6 tips:  http://boundarydevices.com/blog/

Thanks.

Pejman

1,615 Views
TomMorrison
Contributor III

I have downloaded and booted the Boundary Devices version of the Freescale release:

   http://http://boundarydevices.com/er-6-2012-08-beta-for-i-mx6/

But, I am having issues using programs (i.e.: gstreamer) to capture/encode video from the OV5642 camera

(which works with the timesys SD card version). When I use gst-inspect (gst-inspect mfw_v4lsrc) - there are

no control elements <i.e.: capture-width/height/mode>.

And if I try to launch it anyways, it complains about NOT being able to PAUSE...

Still working on getting access to ExtraNet!

Tom

0 Kudos

1,615 Views
daiane_angolini
NXP Employee
NXP Employee

Have you loaded the camera module?

0 Kudos

1,615 Views
TomMorrison
Contributor III

How do I load the camera module? I would assume it would have been loaded by default (built in the kernel itself)?

0 Kudos

1,615 Views
daiane_angolini
NXP Employee
NXP Employee

I don´t know if device baudary default kernel has it built in by default.

Freescale kernel default value is having any camera build as a module.

Try this:

cd /

find -name *.ko | grep capture

You should see camera module file.

Please, let me know your results.

0 Kudos

1,615 Views
TomMorrison
Contributor III

Yes, the camera is installed (ov5642_camera.ko)

root@freescale /$ gst-inspect mfw_v4lsrc

MFW_GST_V4LSRC_PLUGIN 3.0.1 build on Aug 28 2012 14:16:59.

Factory Details:

  Long name:    v4l2 based camera src

  Class:        Src/Video

  Description:  Capture videos by using csi camera

  Author(s):    Multimedia Team <shmmmw@freescale.com>

  Rank:         primary (256)

Plugin Details:

  Name:                 v4lsrc.imx

  Description:          v4l2-based csi camera video src

  Filename:             /usr/lib/gstreamer-0.10/libmfw_gst_v4lsrc.so

  Version:              3.0.1

  License:              LGPL

  Source module:        gst-fsl-plugins

  Binary package:       Freescle Gstreamer Multimedia Plugins

  Origin URL:           http://www.freescale.com

GObject

+----GstObject

       +----GstElement

             +----GstBaseSrc

                   +----GstPushSrc

                         +----MFWGstV4LSrc

Pad Templates:

  SRC template: 'src'

    Availability: Always

    Capabilities:

      ANY

Element Flags:

  no flags set

Element Implementation:

  Has change_state() function: gst_base_src_change_state

  Has custom save_thyself() function: gst_element_save_thyself

  Has custom restore_thyself() function: gst_element_restore_thyself

Element has no clocking capabilities.

Element has no indexing capabilities.

Element has no URI handling capabilities.

Pads:

  SRC: 'src'

    Implementation:

      Has getrangefunc(): gst_base_src_pad_get_range

      Has custom eventfunc(): gst_base_src_event_handler

      Has custom queryfunc(): gst_base_src_query

      Has custom iterintlinkfunc(): gst_pad_iterate_internal_links_default

      Has getcapsfunc(): gst_base_src_getcaps

      Has setcapsfunc(): gst_base_src_setcaps

      Has acceptcapsfunc(): gst_pad_acceptcaps_default

Aborted

---

I don't know why it is aborting - but it definitely is inserted, but nothing is home!

0 Kudos

1,615 Views
daiane_angolini
NXP Employee
NXP Employee

Do you have any unit_test? You could try to access your camera using this simple application.

Sorry, again, I don´t know it BD provides it on rootfs

0 Kudos

1,615 Views
TomMorrison
Contributor III

which unit test accesses the camera?

0 Kudos