Flashing band across video


38 posts   Page 1 of 2   1, 2
by fuzzyfelt » Thu May 16, 2013 2:46 pm
I tried out the camera this morning and there is a flashing band across the video that the camera records. I'm pretty sure this wasn't caused by static as I used our workshop (with ant-static wrist bands) when connecting the module.

I'll try the camera with another Pi this evening and will link to an example.

Has anyone else had a similar issue?
Posts: 5
Joined: Thu May 16, 2013 2:41 pm
by MarkDaniels » Thu May 16, 2013 5:33 pm
by fuzzyfelt » Thu May 16, 2013 2:46 pm
I tried out the camera this morning and there is a flashing band across the video that the camera records. I'm pretty sure this wasn't caused by static as I used our workshop (with ant-static wrist bands) when connecting the module.

I'll try the camera with another Pi this evening and will link to an example.

Has anyone else had a similar issue?


Are you in the UK / Europe or other 50 Hz zone of the world? If so you might want to try adding -fps 25 to the command line for the camera, as below:

sudo raspivid -fps 25 -o video.h264

This will set the camera to 25 frames per second as opposed to 30. The flicker is usually due to fluorescent lighting and 25 frames per second will reduce it significantly. The camera defaults to 30 fps which is compatible with 60 Hz lighting systems such as in the USA.

this made a huge difference to my camera.
Last edited by MarkDaniels on Fri May 17, 2013 8:40 am, edited 1 time in total.
Posts: 53
Joined: Sun Oct 28, 2012 2:01 pm
by fuzzyfelt » Thu May 16, 2013 6:15 pm
I thought it might have been the lighting at work... but it seemed to persist when the light was blocked out. I started searching for other potential sources of interference as there are a lot of electrical things on my desk. Good suggestion on the fps though - I only had a bit of time to play at lunch and hadn't tried fiddling that parameter.

Have brought the camera home and tried on a 512MB Model B (problem seen on a 256MB) and don't get the same effect but it's mostly natural light ATM. I'll try again in the office with both Pis to see what I can find.
Posts: 5
Joined: Thu May 16, 2013 2:41 pm
by dhid » Thu May 16, 2013 9:32 pm
I had a problem that was very similar to what you have described too and in my case it appeared that it was some interference being caused by the HDMI to VGA convertor I was using. When I connected to a proper HDMI display the problem went away.
Posts: 13
Joined: Wed Feb 06, 2013 3:23 pm
Location: UK
by ppumkin » Thu May 16, 2013 10:02 pm
I have the same problem. Like a blueish haze band across the entire screen in any size, 640x480 @ 90fps or default settings.

I tried the 25fps at HD and it reduced it allot. I have noraml halogen light bultbs and use original HTC 1A power supply running headless.

:(
Posts: 72
Joined: Tue May 29, 2012 10:22 pm
by redhawk » Thu May 16, 2013 10:06 pm
Does this happen during daytime light or under artificial lighting??

Richard S.
User avatar
Posts: 3305
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1
by ppumkin » Thu May 16, 2013 10:10 pm
It happens at night with light bulbs only. Im UK also

When i set it 640x480 @ 75fps there is almost no band.

and default @ 25fps is much better - the band only shows up in very high lighted area like when i go from dark under table up the wall towards the ceiling brightest.

With those settings it is almost unnoticeable. Will see what happens in the day.
Posts: 72
Joined: Tue May 29, 2012 10:22 pm
by towolf » Fri May 17, 2013 5:13 am
I got heavy colored banding. I have two power supplies. After switching banding disappeared. Funnily they are both rated high enough. The Belkin Duo plug thing gives banding.

No fluorencent lighting, or any artificial light for that matter.
Attachments
ima.jpg
ima.jpg (63.98 KiB) Viewed 4144 times
Posts: 387
Joined: Fri Jan 18, 2013 2:11 pm
by joshftx » Fri May 17, 2013 7:06 am
I've noticed the same banding when recording video. I've only tried in fluorescent lights indoors so far, and in the same room with the lights off. horizontal bands show up every time so far. I'll try to give it a shot in bright natural light tomorrow. Stills look fine.
Posts: 10
Joined: Sun Dec 02, 2012 3:29 pm
by jamesh » Fri May 17, 2013 8:09 am
I'm not sure that I added flicker cancellation (for 50 or 60 Hz lightling) but I think it defaults to 50 if present, so should be OK in the UK. The bands looks like interference from somewhere.
Soon to be unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11517
Joined: Sat Jul 30, 2011 7:41 pm
by jamesh » Fri May 17, 2013 8:11 am
ppumkin wrote:I have the same problem. Like a blueish haze band across the entire screen in any size, 640x480 @ 90fps or default settings.

I tried the 25fps at HD and it reduced it allot. I have noraml halogen light bultbs and use original HTC 1A power supply running headless.

:(


Well, the current max frame rate support is 30 so not sure why setting 90 made a difference.

If you have a blue haze over everything - have you removed the lens protector film from the camera? That's light blue..
Soon to be unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11517
Joined: Sat Jul 30, 2011 7:41 pm
by MarkDaniels » Fri May 17, 2013 8:34 am
by dhid » Thu May 16, 2013 9:32 pm
I had a problem that was very similar to what you have described too and in my case it appeared that it was some interference being caused by the HDMI to VGA convertor I was using. When I connected to a proper HDMI display the problem went away.


I was getting purple banding, yesterday when running at 30 fps, then changed to 25 fps and it was greatly improved. My lighting is line frequency (50 Hz) fluorescent tubes. At home I run electronic ballast compact fluorescents and have no problem at 25 or 30 fps.

Back in my office this morning with the same Pi and camera I used here and at home, yesterday and I have no purple banding at 25 or 30 fps, so I guess it must be something other than frame rate and lamp flicker. I do have slow downward moving bands of slight brightness shift at present and I can prove that these are line frequency related because at the time of the test the mains frequency in the UK was 49.88 Hz and my frame rate was 25 Hz. Decreasing frame rate to 24 fps increases the speed at which the bands move, whilst increasing the frame rate to 26 fps causes the bands to move upwards.

Placing the camera near to an HDMI to VGA converter does seem to occasionally induce the purple banding, but I cannot get consistent results. I might try shielding the ribbon cable with copper foil or braid to see if the cable is acting as an antenna, but I would have thought that alternate lines were grounded in the cable to provide a modicum of shielding.

I'll report back later when I have done more tests.
Posts: 53
Joined: Sun Oct 28, 2012 2:01 pm
by fuzzyfelt » Fri May 17, 2013 8:40 am
towolf wrote:I got heavy colored banding. I have two power supplies. After switching banding disappeared. Funnily they are both rated high enough. The Belkin Duo plug thing gives banding.

No fluorencent lighting, or any artificial light for that matter.


Changing the power supply has solved the problem for me. The worst problems were noticed when I powered the Pi from the USB port on a KVM. Second place goes to the USB power supply I bought from CPC. A clean image was obtained using a laptop USB port for power.

Unfortunately it's not viable to run the laptop as a power supply so I'll have to use the CPC one for now.

http://cpc.farnell.com/pro-power/mwusb3 ... dp/PW03051

I'll try my Apple USB power supply as they are supposed to be pretty good on the noise front.
Posts: 5
Joined: Thu May 16, 2013 2:41 pm
by fuzzyfelt » Fri May 17, 2013 8:41 am
You can get an idea of how variable power supplies are here:

http://www.righto.com/2012/10/a-dozen-u ... le-is.html
Posts: 5
Joined: Thu May 16, 2013 2:41 pm
by redhawk » Fri May 17, 2013 9:11 am
Switch mode power supplies tend to put out a lot of RF and high frequency crap on the power lines, this should be fairly noticeable with a nearby radio on the AM and sometimes FM band.
Unlike PCs and Laptop power supplies mobile chargers tend to skip on power line filtering because there's no real need for it and it would only push up the cost of manufacturing.
It's quite possible the Pi Camera maybe highly susceptible to interference on the power lines, small ripples in the 50/60Hz supply or via outside influences.
There are a few things you could try like snap-on ferrite cores at both ends of your power supply cable similar to the plastic blobbed ends on high quality USB cables.

When I get the time I'll have to buy one of them Pi Cameras myself to find out :)

Richard S.
User avatar
Posts: 3305
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1
by fuzzyfelt » Fri May 17, 2013 9:24 am
Quality with the Apple USB adapter is as good as I achieved with my laptop USB port. Pity they're so expensive.
Posts: 5
Joined: Thu May 16, 2013 2:41 pm
by MarkDaniels » Fri May 17, 2013 9:43 am
Update

I have shielded the camera cable with a copper braid which is connected to earth. It makes no difference. I have managed to consistently obtain the purple banding on a VGA monitor connected via a CPC HDMI-VGA converter. I cannot get the banding on an NEC LCD2070NX monitor when connected via the DVI (HDMI) connector. I have repeated the tests a dozen times and the results are perfectly consistent: banding with HDMI-VGA and no banding when connected directly via HDMI/DVI.
Posts: 53
Joined: Sun Oct 28, 2012 2:01 pm
by MarkDaniels » Fri May 17, 2013 10:14 am
More Information

I have just noticed that I only get banding on the VGA monitor when the camera module is propped up on the d.c. power lead feeding the Pi. But still no banding on the HDMI/DVI monitor. If I move the camera well away from the power lead the banding on the VGA monitor disappears.
Posts: 53
Joined: Sun Oct 28, 2012 2:01 pm
by dhid » Fri May 17, 2013 12:29 pm
Me yesterday...
I had a problem that was very similar to what you have described too and in my case it appeared that it was some interference being caused by the HDMI to VGA convertor I was using. When I connected to a proper HDMI display the problem went away.


I have today done extensive testing using a Model B Rev1, Model B Rev2 (Chinese), Model B Rev2 (UK) and a Model A (UK). I have used 3 different power supplies, an HDMI to VGA Converter with VGA Monitor and an HDMI Monitor only.

My conclusion is that the problem is related to power supply current capability.

Initially when I noticed the problem I was using a Model B Rev 1 with an MW USBUK1 power supply from CPC (it has Farnell branding) rated at 1A and an HDMI to VGA conveter.

With preview only I had no interference but when saving to file as well I had varying degrees of banding.

Changing to an HDMI monitor I had no problem even when saving to file.

I then tested recording to file with daylight, Compact Fluorescent and Incandescent light sources and had no problem provided I had the HDMI monitor connected and not the HDMI to VGA converter.
If I connected the HDMI to VGA conveter the problem came back but disappeared if disconnected whilst recording.

As the problem occurred when the Pi was saving to file I concluded that as the CPU/GPU were busier the Pi was probably drawing more current, and with the HDMI to VGA convertor connected this is even more (around 150mA to 200mA).
This probably explained why there was no problem with an HDMI monitor, which only draws a few milliamps from the HDMI connector.

So, I changed to an RS power supply rated at 1.2A and I had no problem at all, even when the HDMI to VGA convertor was connected.

To check further I then repeated the tests using a Chinese made Model B Rev2, a UK made Model B Rev2 and a UK made Model A.
I used the CPC and RS power supplies and also used an "el-cheapo" that I had bought from Asda which is supposed to be 1A (but most definitely isn't!).

I rather disturbingly discovered that the problem was MUCH worse with the Chinese made Model B Rev2 - to the extent that even the RS 1.2A power supply was unable to solve the problem.
Both of the other power supplies caused the display to blank completely when trying to save to file!

The UK made Model B Rev2 worked perfectly with the RS and CPC supplies when the HDMI to VGA convertor was connected, but not with the Asda supply.

The UK made Model A worked perfectly with ALL the supplies, including the Asda one - not surprising considering the much lower current requirement of the Model A.

So I am fairly confident that a better power supply is needed when using the camera and as the RS 1.2A one worked in all cases (EXCEPT with the Chinese made Model B Rev2) that's the one I shall use.

Note that this is clearly even more true if using an HDMI to VGA convertor that draws power via the HDMI - a problem which has been highlighted in the past as the HDMI supply is not supposed to be supplying that kind of current.

I am also wondering if the Chinese made Model B Rev2 has some dodgy "knock off" regulators which aren't up to to the job?
I'd be interested to see what other poeple find.
Posts: 13
Joined: Wed Feb 06, 2013 3:23 pm
Location: UK
by ppumkin » Fri May 17, 2013 2:19 pm
Yup - Low quality power supplies - The consequences are now comming out..

Will try various power supplies too.
Posts: 72
Joined: Tue May 29, 2012 10:22 pm
by joshftx » Fri May 17, 2013 2:37 pm
Same issue in natural light. Although not as noticeable. I tried different power supplies and USB cables. Tried repositioning the camera further away from the Pi. NO matter what, a slight flicker/banding is still visible. Picture quality looks great other than that. Very disappointing though.
Hopefully someone will come up with the magic fix for this problem. Does "feel" like interference of some kind. (model B - UK built)
Posts: 10
Joined: Sun Dec 02, 2012 3:29 pm
by towolf » Fri May 17, 2013 8:36 pm
I have to correct myself. It was not the power supply, in my case it was the micro-USB cable.

With a 12cm cable on a powered USB hub it gives a clear image, with a ~1m cable without ferrite cores on the same hub it gives the heavy banding shown in my above image.

I’ll have to find another long cable with cores to confirm.
Posts: 387
Joined: Fri Jan 18, 2013 2:11 pm
by Pihard » Fri May 17, 2013 8:56 pm
I have several camera USB cables. Heavy so I am sure they are shielded, but the also have a ferrite core line/noise filter. (seen them on the dc end of laptop power cables as well.) Wouldn't these help with this problem? ( haven't received my camera yet, so can't check it for you). A few years ago, quite a few, you could buy these ferrite line filters at Radio Shack/Tandy for use on landline phone lines. Less than $5 and would clean up the line noise from radio interference and static. Used to hook them on my 300-1200bps modem lines on my BBS.
If that helps any.
Ed - http://PiHard.blogspot.com
Raspberry Pi, Gertboard & PiFace
Arduino R3 Plus & Arduino Mega 2560
Posts: 8
Joined: Tue Apr 30, 2013 7:41 am
Location: Burbank, California.USA
by Wakey » Fri May 17, 2013 9:10 pm
I have tried it with various power supplies as well using the USB on the TV and am getting interference no matter what. Have tried all the fixes listed here apart from trying a different micro usb cable (as I don't currently have another).

The fact that a Chinese Rev 2 is having issues when the UK ones aren't has me worried as I have a Chinese Rev 1 so I hope that's not the cause
Posts: 4
Joined: Sat Jul 28, 2012 8:31 am
by kaos » Sat May 18, 2013 10:55 am
Good point about the power cable. Note that if the cable was not bundled with the power supply, it may be too thin to carry this much current, as the standard USB spec. calls for 500mA max. And a bundled cable may be no guarantee either; given the horror stories we have seen about some cheap power supply designs, a substandard cable wouldn't worry some of those manufacturers.

Note that there are actually two potential problems with power supplies; voltage drop under load, and interference. A too long or too thin cable will produce and/or exacerbate voltage drop, and ferrites won't help. Ferrites may help, however, with interference from the power supply.

Also worth noting is that interference may come from something else than the power supply. Badly filtered and/or shielded motors are a classic source of interference; so are lighting dimmers.

--
Kári.
Posts: 101
Joined: Mon Mar 26, 2012 8:14 pm