please choosego to mobile | Continue to access the PC version
Author: Sitheek

H3 CSI Camera support ???

[Copy link]
Published in 2015-12-6 02:41:55 | Show all floors
Edited by bronco at 2015-12-6 03:39
@lex replied at 2015-12-5 05:20
I attached the code, don't know you can get it (it does not show to me)
Unfortunately i still have i ...

Thanks, I'm able to download the attachment and will give it a try when my camera board arrives.

Regarding your settings (both reduced cpufreq and DRAM clockspeed). The approach is useless. You won't need to clock the DRAM down if you fix the insane dvfs settings.

I prepared in the meantime a 2nd RPi-Monitor approach to be able to monitor Vcore voltage too (that's the voltage supplied to the ARM cores and the display engine). If these settings are fixed stability/heat problems are gone and there's no need to underclock the DRAM

8

threads

55

posts

252

credits

Intermediate member

Rank: 3Rank: 3

credits
252
Published in 2015-12-6 06:04:03 | Show all floors
Great. Looking forward to your conclusive and optimized dvfs! Keep stressing the SBCs...
Published in 2015-12-8 14:55:16 | Show all floors
@lex replied at 2015-12-5 05:20
I attached the code, don't know you can get it (it does not show to me)
Unfortunately i still have i ...

I compiled the kernel yesterday including your fixes and can confirm they work on the OPi PC -- except for 1600x1200: (just a quick test)

But quality is pretty low and I've not even the slightest idea how to proceed since v4l is completely new to me.

I had instant success with the RPi B/B+ and its camera module using raspivid and letting the VPU do all the encoding (recording a h.264/1080p stream while downclocking the single ARM core to 200 MHz works there) and fear there's nothing available comparable to that? Using motion I've only been able to use 640x480 (and quality/framerates suck) and still have no idea what would be the best way to record streams at the camera's native resolution. Motion seems to capture JPEG stills and reassembles them in a movie container afterwards.

I'm a bit stuck here since I wanted to use the camera to record video with 'best quality possible'. Any hints?

8

threads

55

posts

252

credits

Intermediate member

Rank: 3Rank: 3

credits
252
Published in 2015-12-9 01:53:18 | Show all floors
I have tested 640x480 and 1280x720 using v4l2, so you could try 720P in motion.
Motion most likely grab the image using v4l2 and convert it to JPG with ffmpeg, no VPU used, that's why @cnxsoft got 2 fps.
If someone could get the https://github.com/allwinner-zh/media-codec code sample and implement it in motion it could work, just a thought.

Regarding quality, well, OV5640 AF is far superior but price.

You could comment that line, rebuild  and test 800x600 (or revert to the original) and see if you get better quality, but my understanding is that the modified code for  640x480 and 1280x720 should have the same quality as 800x600 (in the original code).

Maybe @Sitheek who has both camera module working could comment on this?

8

threads

55

posts

252

credits

Intermediate member

Rank: 3Rank: 3

credits
252
Published in 2015-12-14 07:08:00 | Show all floors
Fixed the 1600x1200 !

Now works 640x480 (best quality, best framerate), 1280x720 (worst quality) and 1600x1200 (similar quality as legacy code).
We should push @Steven to design a module with OV5647 (5MP) to compete with rasppi.

Attached the uncleaned code. Enjoy!

This thread contains more resources

You need to Log in to download or view,No account?    Register

x
Published in 2015-12-14 15:46:29 | Show all floors
@lex replied at 2015-12-14 07:08
Fixed the 1600x1200 !

Now works 640x480 (best quality, best framerate), 1280x720 (worst quality) an ...

Thx for the update, you should think about cloning https://github.com/loboris/OrangePI-Kernel and send loboris the changes as pull request.

Regarding 'compete with RPi'. I doubt that will ever be possible. On the RPi I can now use raspivid to encode a raw h.264 videostream from the camera module (1080p@30fps) on the VideoCore VPU. This also works on the single CPU core A/B/B+ models even when the CPU core is clocked down to 200 MHz (already tried, it works since all the magic happens inside the VPU)

That's the reason we still use RPi B+ for video surveillance (fetching the encoded h.264 with netcat and then writing it to disk on an ARM server while 'transcoding' it with VLC as stream that can be viewed instantly on any other device on the network using VLC as well):
  1. cvlc -v - --sout "#rtp{sdp=rtsp://:${StartPort}/${Hostname}}" :demux=h264
Copy code

I doubt that the H3 is powerful enough to do this encoding on the CPU cores even if we have a camera module that produces good quality.

8

threads

55

posts

252

credits

Intermediate member

Rank: 3Rank: 3

credits
252
Published in 2015-12-19 07:50:45 | Show all floors
Edited by @lex at 2015-12-19 20:02

Just for the curious : http://www.cnx-software.com/2015 ... ludes-a-5mp-camera/

The odd thing is that it is advertised as 5MP and 2MP?

Update:
here is a 2.0 MP
http://www.dx.com/p/hd23-quad-co ... iliate#.VnXghh-c38s

and then a 5.0 MP (and surprise, cheaper)
http://www.hongkongeek.com/en/an ... -h3-android-44.html


And watch the videos and see if you can spot the differences.

4

threads

1119

posts

8571

credits

Moderator

Rank: 7Rank: 7Rank: 7

credits
8571
Published in 2016-1-13 02:19:22 | Show all floors
bronco replied at 2015-12-14 08:46
Thx for the update, you should think about cloning https://github.com/loboris/OrangePI-Kernel and  ...

I know that it is a bit old thread but anyway - if you want, I can provide you a binary library for HW supported encoding for OPi. Sadly, it didn't come with any example, just with OpenMAX wrapper source code (with no clear license). It should still suffice to make this thing working.

0

threads

7

posts

81

credits

Registered member

Rank: 2

credits
81
Published in 2016-1-13 19:39:19 | Show all floors
jernej,

I am assuming this "blob" is for Linux, and if yes, could place it somewhere I can try it ?

4

threads

1119

posts

8571

credits

Moderator

Rank: 7Rank: 7Rank: 7

credits
8571
Published in 2016-1-14 01:20:41 | Show all floors
Edited by jernej at 2016-1-13 19:01

Yes. Actually, it can be found on baidu for quite some time. Just search for "liballwinner_linux.rar"... You will find some other interesting stuff as well.
You need to log in before you can reply login | Register

Points Rule

Quick reply Top Return list