3 Replies Latest reply on Sep 11, 2021 10:48 PM by hanif99

    Raspiberry pi Camera module ERROR - mmal: mmal_vc_component_enable: failed to enable component: ENOSPC

    will.mendil

      Hi,

       

      I don't know if this is the best place to ask this kind of question, but I am following tbhs' directives. I need help with the raspberry pi camera. I have been looking all other google for help but nothing seems to work although a lot of people seem to meet the same problem.

       

      I basically intent to use a raspberry pi camera ask a surveillance camera but I cannot seem to get it to work on the last version of raspbian 3.12.28.

      Whenever I type

       

      raspistill -v
      

       

      I get this response

       

       

      raspistill Camera App v1.3.8
      
      Width 2592, Height 1944, quality 85, filename image.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_enable: failed to enable component: ENOSPC
      mmal: camera component couldn't be enabled
      mmal: main: Failed to create camera component
      mmal: Failed to run camera app. Please check for firmware updates
      

       

      I tried changing the /etc/modules but nothing seems to work, I tried changing /etc/modprobe.d/raspi_blacklist.conf etc... nothing.

       

      I read somewhere that downdating the version of raspberry pi worked so I did so

       

      sudo rpi-update 8234d5148aded657760e9ecd622f324d140ae89
      

       

      then raspistill works but I get another error that prevents me from using motion or RPi_Web_cam_interface. The error displays right at the beginning

       

      raspberrypi login : Error: Could not set annotation
      

       

      and persists if I use RPi_Web_Interface. This error does not seem to be in any forum.

       

      I'm pretty upset of having bought the module if it does not work at all...

       

      Anyway if anyone has any idea on what I could do to get it to work, I would be very grateful

       

      Cheers

       

      Will

        • Re: Raspiberry pi Camera module ERROR - mmal: mmal_vc_component_enable: failed to enable component: ENOSPC
          iancarbarns

          I think the problem is likely that you have not set camera support to 'on' using "sudo raspi-config". Without this, I get similar (but not identical) errors.


          All works fine with the latest Raspian  as obtained using:

          sudo apt-get update

          sudo apt-get dist-upgrade


          If I DISABLE camera support I get:

           

          <<Early Parts Deleted>>

          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 enabled in this build. Try running "sudo raspi-config" and ensure that "camera" has been enabled

           

          But if I ENABLE camera support I get the following, with a preview picture on the monitor for several seconds as it runs:

           

          <<Early Parts Deleted>>

          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

          Closing down

          Close down completed, all components disconnected, disabled and destroyed

            • Re: Raspiberry pi Camera module ERROR - mmal: mmal_vc_component_enable: failed to enable component: ENOSPC
              iancarbarns

              Now to go back on my own post ... that's not what this is at all!

               

              The error message is the one that is created when 2 processes try to access the camera module simultaneously (ie, 2nd  one starts before 1st has COMPLETELY ended).

               

              I can suimulate that by entering at the command prompt in quick succession:

              raspistill -v &

              raspistill -v

               

              This gives the following output (the 2 sets mixed together .. but see the error messages. I've tried to distinguish the 2 mixed up output streams using Italics

               

              pi@Pi-3 ~ $ raspistill -v &

              [1] 5943

              pi@Pi-3 ~ $

              raspistill Camera App v1.3.8

              Width 2592, Height 1944, quality 85, filename (null)

              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

              raspistill -v &

              [2] 5949

              pi@Pi-3 ~ $

              raspistill Camera App v1.3.8

              Width 2592, Height 1944, quality 85, filename (null)

              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

              Camera component done

              mmal: mmal_vc_component_enable: failed to enable component: ENOSPC

              mmal: Encoder component done

              Starting component connection stage

              Connecting camera preview port to video render.

              camera component couldn't be enabled

              mmal: main: Failed to create camera component

              mmal: Failed to run camera app. Please check for firmware updates

              Connecting camera stills port to encoder input port

              Closing down

              Close down completed, all components disconnected, disabled and destroyed

               

              So have you got something else running that is using the camera? Either deliberately, or something that has not closed down properly?

            • Re: Raspiberry pi Camera module ERROR - mmal: mmal_vc_component_enable: failed to enable component: ENOSPC
              hanif99

              Hello brother, finally i can solve this problem after a lot of hours troubleshooting.

               

              I already share it in my YouTube (https://youtu.be/on8UlkRvLok)

               

              This problem only occur in camera raspberry pi V2.1 (IMX219) from Element14. But in camera raspberry pi V2.1 from OKdo, i don't get this error

               

              So, the solution when error

              "mmal: mmal_vc_component_enable: failed to enable component: ENOSPC

              mmal: camera component couldn't be enabled

              mmal: main: Failed to create camera component

              mmal: Failed to run camera app. Please check for firmware updates"

               

              You need some initialization with a works camera (me camera from OKdo).

              So, the step is

              1. Plug your works camera to Raspberry Pi (me using Raspberry Pi 4B)

              2. Turn on your Raspberry Pi

              3. check

              Code: Select all

              vcgencmd get_camera

              to make sure your hardware is detected the camera

              4. capture image using

              Code: Select all

              raspistill -v

              and camera will capture the image

              5. Then replace the works camera with ENOSPC Error Camera (from Element14)

              6. then try to capture the image

              Code: Select all

              raspistill -v

              and the ENOSPC Error will not occur

               

              Notes:
              - But, after the ENOSPC Error Camera works, and then you restart/shutdown the raspberry pi, the error will occur again :(

               

              OS Raspberry Pi 4 Model B (4GB)

              - Linux raspberrypi 5.10.60-v7l+ #1449 SMP Wed Aug 25 15:00:44 BST 2021 armv7l GNU/Linux