# Advanced: Help me troubleshoot weird camera problems

Ensure that the camera is enabled and there is enough GPU memory:

1. Add the following lines to the `/boot/firmware/config.txt` file:

```
start_x=1
gpu_mem=128

```

And then reboot. Note that the config.txt file will say that you should not modify it and instead make the changes in a file called userconfig.txt. However I found that the userconfig.txt file is not invoked. So I added the lines above directly to config.txt.

1. Check the amount of gpu\_memory

```
vcgencmd get_mem gpu
```

It should show 256 or whatever number you put there.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://campus-rover.gitbook.io/lab-notebook/yyy/advanced-fixing-camera-problems.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
