digicam – How you can arrange picamera on Raspberry Pi 3 B+ with an Ubuntu 20.04 OS

I've a TurtleBot3 Burger robotic which has a Raspberry Pi 3B+ on it. And the RPI has to run Ubuntu 20.04 OS, in any other case I can not use ROS and ultimately the robotic functionalities.

The RPI has a picamera v2.1 on it and my purpose is to program utilizing picamera python library. I'm able to take an image utilizing raspistill command. However when I attempt to run a easy program on Python, which takes an image and saves it, then I get the next error:

Code:

# supply: https://picamera.readthedocs.io/en/release-1.13/recipes1.html
from time import sleep
from picamera import PiCamera

digicam = PiCamera()
digicam.decision = (1024, 768)
digicam.start_preview()
# Digicam warm-up time
sleep(2)
digicam.seize('foo.jpg')

Error:

mmal: mmal_component_create_core: couldn't discover element 'vc.camera_info'
Traceback (most up-to-date name final):
  File "take a look at.py", line 4, in <module>
    digicam = PiCamera()
  File "/usr/native/lib/python3.8/dist-packages/picamera/digicam.py", line 367, in __init__
    with mo.MMALCameraInfo() as camera_info:
  File "/usr/native/lib/python3.8/dist-packages/picamera/mmalobj.py", line 2346, in __init__
    tremendous(MMALCameraInfo, self).__init__()
  File "/usr/native/lib/python3.8/dist-packages/picamera/mmalobj.py", line 631, in __init__
    mmal_check(
  File "/usr/native/lib/python3.8/dist-packages/picamera/exc.py", line 184, in mmal_check
    increase PiCameraMMALError(standing, prefix)
picamera.exc.PiCameraMMALError: Did not create MMAL element b'vc.camera_info': Operate not carried out

Is there a method to make use of Picamera like this, or is it not attainable with Ubuntu 20.04?



Source link

Leave a Reply

Your email address will not be published. Required fields are marked *