Quantcast
Viewing all articles
Browse latest Browse all 4867

Camera board • Re: Camera Module 3 Wide - Cannot allocate memory

Hi, I'm not really sure what may have happened to provoke the change. Here are a couple of things that you might try.

1. Have a look at the output of "grep Cma /proc/meminfo". Depending on what the current Cma total is, you might try increasing it to 256 or 384MB. (Edit the "dtoverlay=vc4-kms-v3d" line in your /boot/firmware/config.txt to add ",cma-256" or ",cma-384".)

2. You could consider using a Python script that doesn't shut the camera down but keeps the resources allocated. That means that so long as it captures the first picture, it should run forever. It would look something like this (untested):

Code:

import timefrom picamera2 import Picamera2picam2 = Picamera2()config = picam2.create_still_configuration()picam2.start(config)for i in range(9999999):    picam2.capture_file(f"image_{i:04}.jpg")    time.sleep(30)

Statistics: Posted by therealdavidp — Mon Jun 17, 2024 8:50 am



Viewing all articles
Browse latest Browse all 4867

Trending Articles