User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

camera board rPi 2 Camera is not detected [SOLVED]

Sun Feb 22, 2015 2:53 pm

hello rPi people,

I got new rig yesterday (rPi 2),
I guess my power supply. is ok

my OS is arch: http://archlinuxarm.org/platforms/armv7 ... berry-pi-2


Camera module is giving:

Code: Select all

[mala@katrca pics]$ raspistill -o cam.jpg
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly

[mala@katrca pics]$ raspivid -o vid.h264
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly

[mala@katrca pics]$ raspistill -v -o test.jpg

raspistill Camera App v1.3.8

Width 2592, Height 1944, quality 85, filename test.jpg
Time delay 5000, 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 Yes, Full screen Yes
Preview window 0,0,1024,768
Opacity 255
Sharpness 0, Contrast 0, Brightness 50
Saturation 0, ISO 0, Video Stabilisation No, Exposure compensation 0
Exposure Mode 'auto', AWB Mode 'auto', Image Effect 'none'
Metering Mode 'average', 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
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly


[mala@katrca pics]$ vcgencmd get_camera
supported=1 detected=0
I have my old rig (rPi B),
and i switched camera boards,
new camera board is working beautifully on old rig,
old camera board in not working on new rig,
and I do get same error on rPi 2.
So I guess camera board is working,
since my search proposed such results (or my Englis is bad):
( http://raspberrypi.stackexchange.com/qu ... ot-working
http://www.element14.com/community/thre ... 0&tstart=0
http://www.raspberrypi.org/forums/viewt ... 43&t=79890
http://www.raspberrypi.org/forums/viewt ... 3&p=655380 )

What seems to be the problem?

Thank you
Last edited by Seiduna on Sat Feb 28, 2015 10:51 pm, edited 1 time in total.
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

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

Re: camera board rPi 2 Camera is not detected

Sun Feb 22, 2015 3:08 pm

Have you enabled the camera in raspi-config?
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Sun Feb 22, 2015 3:16 pm

hello jamesh,

khuh:

Code: Select all

[root@katrca /]# raspi-config
bash: raspi-config: command not found
[root@katrca /]# 
I can edit /boot/config.txt, it that is the file to modify, but what to put?

Thank you
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Sun Feb 22, 2015 9:20 pm

oi

so I guess i have enabled camera, from here: http://www.raspberrypi.org/forums/viewt ... 43&t=44539
my /boot/config.txt:

Code: Select all

disable_overscan=1
gpu_mem=128
#disable_camera_led=1
start_file=start_x.elf
fixup_file=fixup_x.dat
#start_x=1
What could be next troubleshoot?

Thank you
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

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

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 7:55 am

Seiduna wrote:What could be next troubleshoot?
Test with Raspbian.
The Pi2 needed various updates to firmware and dtblob - have all of those been ported over to Arch properly?
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.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 1:16 pm

hey 6by9, hello there,

fresh install of raspbian, first boot:
sudo raspi-config - I enabled camera board here
sudo reboot, I tried camera here, not working
sudo apt-get update
sudo apt-get upgrade
sudo rpi-update
sudo reboot

Code: Select all

pi@raspberrypi ~ $ raspistill -o cam.jpg
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly

hmmm... I am noob, am I supposed to turn on something else in raspbian?
What is that dtblob you mentioned?

Thank you
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

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

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 1:45 pm

Odd. Cameras shoudl work with no difference to the older model.

There may be a problem with the B2's camera interface. Do you have another one you can try?
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed.
I've been saying "Mucho" to my Spanish friend a lot more lately. It means a lot to him.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 2:33 pm

hey jamesh,

'the B2's camera interface' - that is too fancy ford for me, and I am not a native English speaker, could I bother you for more on what that is?

I have another camera board, I can try to change that, but I already did that on arch, but not in raspbian, so i'll try that, but camera board is working since I tested it on rPi B model that I also have.

Will report back shortly
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

0lly
Posts: 77
Joined: Sun Mar 02, 2014 5:07 pm

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 2:34 pm

Seiduna wrote: sudo apt-get update
sudo apt-get upgrade
sudo rpi-update
sudo reboot
Maybe help it.
use sudo apt-get dist-upgrade instead of sudo apt-get upgrade.
My rpi2 +cam works perfect.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 3:32 pm

ok, i thin it is time to panic, but before let me elaborate:

two days ago I got new rPi 2 and camera board.
I have old rPi B and old camera board, in service since 2013.

Since new rig did not work, I replaced the cameras,
mind you, that is touching radiator to de-electrify myself a lot,
also precision to case rpi and camera, it is hard work and it takes time...

So yesterday I put new camera on old rig and it worked.
Old camera on new rig did not work.
This led me to assumtion, that there is nothing wrong with cameras.

Since changing cameras is teadious work, i left cameras as they were.
Just now, I switched them back, but to my surpurise, old rig stopped working, with same error:

Code: Select all

[osa@malina ~]$ raspistill -o cam.jpg
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly

[osa@malina ~]$ vcgencmd get_camera
supported=1 detected=0
[osa@malina ~]$ 
Now cameras are not working, and I get same message on both...

What in Pi's name is going on?

Also I did sudo apt-get dist-upgrade instead of sudo apt-get upgrade, no go...

Thank you
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

User avatar
DougieLawson
Posts: 38798
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 4:20 pm

Have you tried reseating the tiny "Sunny" connector on the front of the camera?
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Mon Feb 23, 2015 5:34 pm

hy DougieLawson,

yes, that is what I did, i used a peace of paper between my finger and that sunny thingy, and ever so gently pressed against the board, every time I enclose camera.

So you guys think this is hardware problem?

Now I have two nonworking cameras, I will see if I have time today, week has started, but I have to make this work...

Thank you
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

User avatar
Seiduna
Posts: 109
Joined: Wed Nov 20, 2013 4:12 pm

Re: camera board rPi 2 Camera is not detected

Sat Feb 28, 2015 10:51 pm

oi oi, happy news!!!

after working week i had time tonight to mess with camera boards.

I actually got pissed off since everything looked connected,
and i decided to destroy one camera sunny thing by just squeeshing it hard....


to my astonishment - it clicked....

now, it clicked before, but much gentler, so my advice is to click that sunny thingy as hard as you can.

So I unclicked it, quite forcefully out again, and clicked it back again - again quite forcefully...

Now i had to calm down and power up this thing to see if it works ... and it does...

Well, for my part, this stuff is made quite durable, seence i force myself onto it and it still works...

DougieLawson, you are my man of the week!!!!


Thanks everyone for helping this noob out
Gnu/Linux,
because I'd rather own a free OS
than steal one that's not worth paying for.

ppumkin
Posts: 82
Joined: Tue May 29, 2012 10:22 pm

Re: camera board rPi 2 Camera is not detected [SOLVED]

Wed Apr 01, 2015 9:59 pm

That sunny thing should just click in gently. Squishing it hard will just destroy it, its beyond me how that fixed it for you.

i am having the same problem. Just says check if camera is conneced. i amusing the uv4l driver, and that starts and registers the video0 but when i try to stream the LED only blinks quickly and nothing.

Code: Select all

[....] Starting UV4L Raspberry CSI Camera Driver: uv4l
<notice> [core] Trying driver 'raspicam' from built-in drivers...
<warning> [core] Driver 'raspicam' not found
<notice> [core] Trying driver 'raspicam' from external plug-in's...
<notice> [driver] Dual Raspicam Video4Linux2 Driver v1.9.27 built Feb 21 2015
<notice> [driver] Selected format: 1920x1080, encoding: mjpeg, JPEG Video Capture
<notice> [driver] Framerate max. 30 fps
<notice> [driver] ROI: 0, 0, 1, 1
<notice> [core] Device detected!
<notice> [core] Registering device node /dev/video0
now using

Code: Select all

using  dd if=/dev/video0 of=snapshot.jpeg bs=11M count=1
says

Code: Select all

dd: opening `/dev/video0': Operation not permitted
raspivid

Code: Select all

mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly

WTF? It worked on B model and B+ (Pi2) it doesnt. I updated everything. All connected properly.

User avatar
DougieLawson
Posts: 38798
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: camera board rPi 2 Camera is not detected [SOLVED]

Wed Apr 01, 2015 10:26 pm

Have you added

Code: Select all

gpu_mem=128
start_x=1
to the bottom of your /boot/config.txt?
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

ppumkin
Posts: 82
Joined: Tue May 29, 2012 10:22 pm

Re: camera board rPi 2 Camera is not detected [SOLVED]

Thu Apr 02, 2015 6:59 am

DougieLawson wrote:Have you added

Code: Select all

gpu_mem=128
start_x=1
to the bottom of your /boot/config.txt?

I installed from NOOBs and it was already there. I changed my mem 256 via raspi_config and reflects in the config.txt

I am going to try and reinstall Raspbian from scratch.

ppumkin
Posts: 82
Joined: Tue May 29, 2012 10:22 pm

Re: camera board rPi 2 Camera is not detected [SOLVED]

Thu Apr 02, 2015 4:33 pm

Fresh install and the same.

Maybe the camera is bricked. I will just have to buy a new one... *sigh*

Johnjohngiannis
Posts: 4
Joined: Sat Apr 18, 2015 7:16 am

Re: camera board rPi 2 Camera is not detected [SOLVED]

Sat Apr 18, 2015 7:27 am

Dear Rasps

I have encounter a problem :

I had a board of raspberry pi b+ with NOOBS sd card. I bought a raspberry pi2 board and I followed instructions to upgrade my SD card in order to work with raspberry pi2.

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install raspberrypi-ui-mods
sudo shutdown -h now

Then I downloaded NOOBS LITE and unzipped eveything to the SD card except from the file recovery.cmdline

After I boot with raspberry pi2 and tried to load an opencv program I had made it said the following error:

/dev/video0 does not support memory mapping
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
Unable to stop the stream.: Bad file descriptor
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument

What can I do ? Does anyone knows what is the problem?

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

Re: camera board rPi 2 Camera is not detected [SOLVED]

Sat Apr 18, 2015 2:40 pm

Johnjohngiannis wrote:Then I downloaded NOOBS LITE and unzipped eveything to the SD card except from the file recovery.cmdline

After I boot with raspberry pi2 and tried to load an opencv program I had made it said the following error:

/dev/video0 does not support memory mapping
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
Unable to stop the stream.: Bad file descriptor
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument

What can I do ? Does anyone knows what is the problem?
Generally worth starting a new thread unless your problem exactly matches the situation of the existing thread (yours doesn't), and duplicating posts annoys people too (viewtopic.php?f=28&t=107728&p=741675)

Have you loaded the V4L2 driver?

Code: Select all

sudo modprobe bcm2835-v4l2
It wasn't in the list of thing you say you did, and if not then /dev/video0 won't exist.
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.

Johnjohngiannis
Posts: 4
Joined: Sat Apr 18, 2015 7:16 am

Re: camera board rPi 2 Camera is not detected [SOLVED]

Sat Apr 18, 2015 3:35 pm

6by9 wrote:
Johnjohngiannis wrote:Then I downloaded NOOBS LITE and unzipped eveything to the SD card except from the file recovery.cmdline

After I boot with raspberry pi2 and tried to load an opencv program I had made it said the following error:

/dev/video0 does not support memory mapping
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
Unable to stop the stream.: Bad file descriptor
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument
munmap: Invalid argument

What can I do ? Does anyone knows what is the problem?
Generally worth starting a new thread unless your problem exactly matches the situation of the existing thread (yours doesn't), and duplicating posts annoys people too (viewtopic.php?f=28&t=107728&p=741675)

Have you loaded the V4L2 driver?

Code: Select all

sudo modprobe bcm2835-v4l2
It wasn't in the list of thing you say you did, and if not then /dev/video0 won't exist.

Hi Thank you for your fast reply,

Now all the error are gone, but I get on the LXTerminal the following (each time I get a frame from the camera ) :


select timeout
select timeout
select timeout
select timeout

Also I see the windows of the command imshow() but I do not see any picture from the camera.

Do you know what is happening?

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

Re: camera board rPi 2 Camera is not detected [SOLVED]

Sat Apr 18, 2015 5:54 pm

Johnjohngiannis wrote:Hi Thank you for your fast reply,

Now all the error are gone, but I get on the LXTerminal the following (each time I get a frame from the camera ) :


select timeout
select timeout
select timeout
select timeout

Also I see the windows of the command imshow() but I do not see any picture from the camera.

Do you know what is happening?
Seeing as you haven't given any detail as to what the opencv program you're running is trying to do, or preferably posted the code for it somewhere, then no, I haven't the foggiest as to what is happening.
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.

ppumkin
Posts: 82
Joined: Tue May 29, 2012 10:22 pm

Re: camera board rPi 2 Camera is not detected [SOLVED]

Sat Apr 18, 2015 7:57 pm

Got new camera, works straight away.

Johnjohngiannis
Posts: 4
Joined: Sat Apr 18, 2015 7:16 am

Re: camera board rPi 2 Camera is not detected [SOLVED]

Sun Apr 19, 2015 7:46 am

6by9 wrote:
Johnjohngiannis wrote:Hi Thank you for your fast reply,

Now all the error are gone, but I get on the LXTerminal the following (each time I get a frame from the camera ) :


select timeout
select timeout
select timeout
select timeout

Also I see the windows of the command imshow() but I do not see any picture from the camera.

Do you know what is happening?
Seeing as you haven't given any detail as to what the opencv program you're running is trying to do, or preferably posted the code for it somewhere, then no, I haven't the foggiest as to what is happening.
Hello, goodmorning,

Here is a piece of my code:

int main()
{
int c;
c= 0;
Mat a;
Mat b;
VideoCapture cap(0);
while (c=1)
{
cap >> a;
cap >> b;


if (a.empty() || b.empty())
return -1;

cv::imshow("a", a);
cv::imshow("b", b);
cv::waitKey(1);

//return 0;
}

Grallator
Posts: 1
Joined: Fri Nov 27, 2015 7:02 am

Re: camera board rPi 2 Camera is not detected [SOLVED]

Fri Nov 27, 2015 7:12 am

Is there a solution to this? I get the same error on Pi 2 with Jessie (and wheezy) but the camera works on a Pi B+ running Wheezy. I've enabled the camera using raspi-configure, updated, upgraded, etc, etc. The camera is a couple of years old - is there a hardware incompatibility?

Return to “Camera board”