raspiCAM
Posts: 57
Joined: Mon Aug 25, 2014 9:13 am

Developer please come in - Rpi-update slow down capturing

Wed Sep 03, 2014 8:18 am

Hi All,

So far my project wrote in C code and running properly.

Just now (3/9/2014) I did a rpi-update, sudo apt-get update, sudo apt-get upgrade. Rasberry PI take around 15 minutes to download and install latest firmware.

After that i try to run my code again, capturing slow down by 5 seconds.

Then I reflash with old image firmware, everything become normal again.

Please advise.

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 26013
Joined: Sat Jul 30, 2011 7:41 pm

Re: Developer please come in - Rpi-update slow down capturin

Wed Sep 03, 2014 8:56 am

Just to confirm, you are using the Raspi camera and raspistill?

What is the command line you are using?
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“My wife said to me `...you’re not even listening`.
I thought, that’s an odd way to start a conversation.."

raspiCAM
Posts: 57
Joined: Mon Aug 25, 2014 9:13 am

Re: Developer please come in - Rpi-update slow down capturin

Wed Sep 03, 2014 9:28 am

jamesh wrote:Just to confirm, you are using the Raspi camera and raspistill?

What is the command line you are using?
Hi Jamesh,

Below are detail of my image capture and command that I was using.

Everything the same but once I did rpi-update, the process slow down around 4-5 seconds(feel like the timeout not fucntiong and it default to 5s?). I check the time delay also shown 1 for both PI firmware.

raspistill Camera App v1.3.8

Width 140, Height 100, quality 85, filename /run/shm/Source.jpg
Time delay 1, Raw no
Thumbnail enabled Yes, width 64, height 48, quality 35
Link to latest frame enabled no
Full resolution preview No
Capture method : Single capture

Preview No, Full screen Yes
Preview window 0,0,1024,768
Opacity 255
Sharpness 0, Contrast 0, Brightness 50
Saturation 0, ISO 100, Video Stabilisation No, Exposure compensation 0
Exposure Mode 'auto', AWB Mode 'shade', Image Effect 'none'
Metering Mode 'matrix', Colour Effect Enabled No with U = 128, V = 128
Rotation 0, hflip No, vflip No
ROI x 0.000000, y 0.000000, w 1.000000 h 1.000000
Camera component done
Encoder component done
Starting component connection stage
Connecting camera preview port to video render.
Connecting camera stills port to encoder input port
Opening output file /run/shm/Source.jpg
Enabling encoder output port
Starting capture 0
Finished capture 0
Closing down
Close down completed, all components disconnected, disabled and destroyed

system("raspistill -t 1 -v -h 100 -w 140 -n -sh 0 -co 0 -br 50 -sa 0 -ev 0 -awb shade -mm matrix -ISO 100 -ss 1000 -o /run/shm/Source.jpg");

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 8441
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: Developer please come in - Rpi-update slow down capturin

Wed Sep 03, 2014 9:30 am

If you are doing burst capture with long exposure times, then I would expect that at the moment. See http://www.raspberrypi.org/forums/viewt ... 75#p607003
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

raspiCAM
Posts: 57
Joined: Mon Aug 25, 2014 9:13 am

Re: Developer please come in - Rpi-update slow down capturin

Wed Sep 03, 2014 9:58 am

6by9 wrote:If you are doing burst capture with long exposure times, then I would expect that at the moment. See http://www.raspberrypi.org/forums/viewt ... 75#p607003
Hi 6by9,

I tried -bm before but no respond, so I stop using it.

I just do a normal still image capture, I just do an update again still the same problem. Latest update give me 4-5 seconds delay. Hardware and source code C file all the same. Just rpi-update then run the project.

If you need me to help debug I am happy to help. Just let me know which data or log file you would like to see.

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 8441
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: Developer please come in - Rpi-update slow down capturin

Wed Sep 03, 2014 10:28 am

TBH We can't debug this easily now - note sig for both jamesh and myself! We're now both unable to access the firmware without going in to Pi Towers on a voluntary basis.

Without your source code, or at least a description of preview resolution, capture resolution, and any special settings (particularly frame rate and exposure time) that you are requesting, then there's little diagnosis that can be done at the moment.

Are you sure it is the latest firmware that is breaking your system? You can do "rpi-update <commit hash>", where the hash comes from https://github.com/Hexxeh/rpi-firmware/commits/master to pick up any arbitrary firmware release. If you can tell us the point at which it starts being slow then that would be useful.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

raspiCAM
Posts: 57
Joined: Mon Aug 25, 2014 9:13 am

Re: Developer please come in - Rpi-update slow down capturin

Thu Sep 04, 2014 10:04 am

Hi 6by9,

Thanks for your volunteer support.

My working firmware version is raspberry 3.12.26+ #703 12 Aug 2014 18:13:52

Just now I try your suggestion to grab latest firmware from github. But same problem happened again.
For the moment I will stop updating, hope some developer will found this problem and fix it.

sudo rpi-update 34662b3f2af52e1df897553f2a5a7455035adf85

Below is the command I used for capturing, I doubt if they did something on shutter speed that causing this.
system("raspistill -t 1 -v -h 100 -w 140 -n -sh 0 -co 0 -br 50 -sa 0 -ev 0 -awb shade -mm matrix -ISO 100 -ss 1000 -o /run/shm/Source.jpg");



6by9 wrote:TBH We can't debug this easily now - note sig for both jamesh and myself! We're now both unable to access the firmware without going in to Pi Towers on a voluntary basis.

Without your source code, or at least a description of preview resolution, capture resolution, and any special settings (particularly frame rate and exposure time) that you are requesting, then there's little diagnosis that can be done at the moment.

Are you sure it is the latest firmware that is breaking your system? You can do "rpi-update <commit hash>", where the hash comes from https://github.com/Hexxeh/rpi-firmware/commits/master to pick up any arbitrary firmware release. If you can tell us the point at which it starts being slow then that would be useful.

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 26013
Joined: Sat Jul 30, 2011 7:41 pm

Re: Developer please come in - Rpi-update slow down capturin

Thu Sep 04, 2014 1:53 pm

I'm always dubious about having very small timeout values. It's measured in milliseconds, and you should really have a value of at least 500 in there.
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“My wife said to me `...you’re not even listening`.
I thought, that’s an odd way to start a conversation.."

raspiCAM
Posts: 57
Joined: Mon Aug 25, 2014 9:13 am

Re: Developer please come in - Rpi-update slow down capturin

Fri Sep 05, 2014 2:03 am

jamesh wrote:I'm always dubious about having very small timeout values. It's measured in milliseconds, and you should really have a value of at least 500 in there.
Done testing on firmware version that affecting capture time.

sudo rpi-update 3d99bfb69460105c91e688a6031971e641bff354 <<<< (3.12.26+ 12/8/2014 no problem)
sudo rpi-update 995a4c011dd57031bb9290a40286439c9a05c2ed <<<< (3.12.26+ 21/8/2014 and onward version have problem)

Regarding timeout, I am curious why you need a time out for raspistill.
Capturing still image should start immediately or as soon as you trigger, I have no idea why you need a time out for this feature.

User avatar
waveform80
Posts: 350
Joined: Mon Sep 23, 2013 1:28 pm
Location: Manchester, UK
Contact: Website Twitter

Re: Developer please come in - Rpi-update slow down capturin

Sat Sep 06, 2014 12:53 am

Unfortunately I also suspect some sort of slowdown in the recent firmwares. I haven't dug into exactly which one yet but the picamera test suite which used to take about 1.5 hours to run has suddenly started taking 4.5 hours (there's a few extra tests in there but nothing that would justify that kind of extra time). My hunch at the moment is that the camera is taking rather longer to initialize (the test suite re-initializes the camera between each test). I'll try and find some time to dig into the details at the weekend, but I understand there's unlikely to be any quick fixes now that 6by9 and jamesh have no access to firmware development.

Dave.
Author of / contributor to a few pi related things (picamera, Sense HAT emulator, gpio-zero, piwheels, etc.), and currently a software engineer at Canonical responsible for Ubuntu Server and Core on the Raspberry Pi.

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 8441
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: Developer please come in - Rpi-update slow down capturin

Sat Sep 06, 2014 7:15 pm

Very odd.
As you can see from the commit text, there were a lot of changes in there. I suspect it is probably "OV5647: set restart_drop_frames correctly" or possibly "vc_image/vc_pool: minor fixes for multichannel allocs". However I'm not able to do anything any more without going in to Pi Towers, and I'm not going to manage that until probably week commencing 22nd Sept.
I don't know if jamesh is going in before then and could take a look, but otherwise it'll have to be fairly blind reverts of commits put in for good reason (either breaks burst capture or stereoscopic!).
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

lagurus
Posts: 48
Joined: Wed Aug 07, 2013 8:02 am

Re: Developer please come in - Rpi-update slow down capturin

Mon Sep 08, 2014 9:38 am

I have noticed, also some odd behavior which begins from firmware from 21/8/2014 (last working version was
also firmware from 12/8/2014).

But my problems are different, they are connected with max.fps at 1920x1080, see more in
http://www.raspberrypi.org/forums/viewt ... 70#p604104

User avatar
waveform80
Posts: 350
Joined: Mon Sep 23, 2013 1:28 pm
Location: Manchester, UK
Contact: Website Twitter

Re: Developer please come in - Rpi-update slow down capturin

Mon Sep 08, 2014 8:09 pm

6by9 wrote:Very odd.
As you can see from the commit text, there were a lot of changes in there. I suspect it is probably "OV5647: set restart_drop_frames correctly" or possibly "vc_image/vc_pool: minor fixes for multichannel allocs". However I'm not able to do anything any more without going in to Pi Towers, and I'm not going to manage that until probably week commencing 22nd Sept.
I don't know if jamesh is going in before then and could take a look, but otherwise it'll have to be fairly blind reverts of commits put in for good reason (either breaks burst capture or stereoscopic!).
No worries - stereoscopic and burst capture are both important features. If the cost of those is my test suite taking longer, then so be it - I can certainly live with that! I'll try and find some time to look into exactly which revision caused it, but likewise I'm a bit swamped at the moment so it might be a while before I get a chance to do this.

Thanks,

Dave.
Author of / contributor to a few pi related things (picamera, Sense HAT emulator, gpio-zero, piwheels, etc.), and currently a software engineer at Canonical responsible for Ubuntu Server and Core on the Raspberry Pi.

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 8441
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: Developer please come in - Rpi-update slow down capturin

Mon Sep 08, 2014 8:20 pm

waveform80 wrote:No worries - stereoscopic and burst capture are both important features. If the cost of those is my test suite taking longer, then so be it - I can certainly live with that! I'll try and find some time to look into exactly which revision caused it, but likewise I'm a bit swamped at the moment so it might be a while before I get a chance to do this.
It's more that they are both nominally implemented correctly. If there is interaction with something else then that is wrong, but it may take a while to track down. There's no fundamental reason why either of those changes should change the capture speed significantly, but raspiCAM's report of
sudo rpi-update 3d99bfb69460105c91e688a6031971e641bff354 <<<< (3.12.26+ 12/8/2014 no problem)
sudo rpi-update 995a4c011dd57031bb9290a40286439c9a05c2ed <<<< (3.12.26+ 21/8/2014 and onward version have problem)
implies that is where the problem is.
I've had some comms with those at Pi Towers, and I may be able to pop in and pick up kit to debug at home. If so then I may be able to look at this w/c 15th Sept, but we'll see.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

raspiCAM
Posts: 57
Joined: Mon Aug 25, 2014 9:13 am

Re: Developer please come in - Rpi-update slow down capturin

Thu Sep 18, 2014 2:45 am

Hi 6by9,

Any update for your test on 15 Sept?

6by9 wrote:
waveform80 wrote:No worries - stereoscopic and burst capture are both important features. If the cost of those is my test suite taking longer, then so be it - I can certainly live with that! I'll try and find some time to look into exactly which revision caused it, but likewise I'm a bit swamped at the moment so it might be a while before I get a chance to do this.
It's more that they are both nominally implemented correctly. If there is interaction with something else then that is wrong, but it may take a while to track down. There's no fundamental reason why either of those changes should change the capture speed significantly, but raspiCAM's report of
sudo rpi-update 3d99bfb69460105c91e688a6031971e641bff354 <<<< (3.12.26+ 12/8/2014 no problem)
sudo rpi-update 995a4c011dd57031bb9290a40286439c9a05c2ed <<<< (3.12.26+ 21/8/2014 and onward version have problem)
implies that is where the problem is.
I've had some comms with those at Pi Towers, and I may be able to pop in and pick up kit to debug at home. If so then I may be able to look at this w/c 15th Sept, but we'll see.

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 8441
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: Developer please come in - Rpi-update slow down capturin

Thu Sep 18, 2014 6:38 am

raspiCAM wrote:Hi 6by9,
Any update for your test on 15 Sept?
Not had a chance to go to Pi Towers as yet.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

Return to “Camera board”