User avatar
benderman
Posts: 15
Joined: Wed Dec 17, 2014 8:19 am

Camera not working

Mon Jan 05, 2015 12:45 pm

Hi Guys,

I have recently got the camera module to go with my B+ and when I try and take a picture like using the following command

Code: Select all

raspistill -o testcapture.jpg
I get the red light on (stays on) and I get an unexpected callback message.

I have googled it and tried:

Checking the cable (both ends)
Amending etc/modules as per a tutorial on github
Pressing the beige part of the camera

Is there anything else I could try or is it dead?

Cheers,

Ben

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

Re: Camera not working

Mon Jan 05, 2015 12:49 pm

Check the small "SUNNY" connector between the camera and the camera board. Use thumb & forefinger pressure to ensure it's clicked all the way into it's socket.
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 fake doctors are on my foes list.

User avatar
benderman
Posts: 15
Joined: Wed Dec 17, 2014 8:19 am

Re: Camera not working

Mon Jan 05, 2015 2:49 pm

Thanks I'll try that tonight.

User avatar
pluggy
Posts: 3635
Joined: Thu May 31, 2012 3:52 pm
Location: Barnoldswick, Lancashire,UK
Contact: Website

Re: Camera not working

Mon Jan 05, 2015 3:21 pm

You could try a beefier power supply, the camera (and pi while its running it) use a lot of power and it can cause problems if the power supply isn't up to it.
Don't judge Linux by the Pi.......
I must not tread on too many sacred cows......

didzan
Posts: 5
Joined: Mon Jan 05, 2015 11:29 pm

Re: Camera not working

Wed Jan 07, 2015 8:44 pm

Hi all,
I'm having an issue with the Pi Camera. I want to stream video and detect faces with OpenCV. I have found some tutorial and work in my Ubuntu. However when I try to run the same file.py on Raspberry Pi doesn't work.
My code is like that:

Code: Select all

import cv2
import numpy
import sys

faceCascade = cv2.CascadeClassifier(filename='haarcascade_frontalface_default.xml')

video_capture = cv2.VideoCapture(0)
video_capture.open(0)

while True:
    ret, frame = video_capture.read()

    gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)

    faces = faceCascade.detectMultiScale(
        gray,
        scaleFactor=1.1,
        minNeighbors=5,
        minSize=(30, 30),
        flags=cv2.cv.CV_HAAR_SCALE_IMAGE
    )

    # Draw a rectangle around the faces
    for (x, y, w, h) in faces:
        cv2.rectangle(frame, (x, y), (x+w, y+h), (0, 255, 0), 2)

    # Display the resulting frame
    cv2.imshow('Video', frame)

    if cv2.waitKey(1) & 0xFF == ord('q'):
        break

# When everything is done, release the capture
video_capture.release()
cv2.destroyAllWindows()
I'm using a Pi NoIR Camera Board.
The terminal shows in cv2.COLOR_BGR2GRAY
Please help, and excuse my English

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

Re: Camera not working

Wed Jan 07, 2015 9:26 pm

http://www.raspberrypi.org/forums/viewt ... 37&t=91269

Also take a look at
http://www.themagpi.com/issue/issue-28/
http://www.themagpi.com/issue/issue-29/

There's a couple of articles and some sample code from Derek "Guzunty" Campbell on this exact subject.
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 fake doctors are on my foes list.

Return to “Camera board”