PicarX Camera not working

I get the following error when running the computer vision script python3 7.display.py
Local display failed, because there is no gui.

Rechecked the cabling and ran the libcamera but the raspberry pi is not recognizing the camera. I’ve noticed no lights on the camera and the when running the script is says that the display failed and is not recognized. Any ideas as to what might be wrong. Could it be the ribbon cable?

  1. Please check if the camera wiring is correct and the wiring direction is correct?
  2. Please replace the spare camera cable and verify the camera is working correctly again.
    Run libcamera-hello to test the webcam and provide the printout to us.




I did recheck the wiring by confirming direction, and reconnecting. It all appears to be correct. I am using a raspberry pi zero so my cable and is different than what it shown. I will attach pictures and screenshots shortly

Ran libcamer-hello; below is the message:

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Fri Jan 17 17:21:48 2025
mjkie@raspberrypi:~ $ libcamera-hello
[0:01:45.793615855] [1888] INFO Camera camera_manager.cpp:325 libcamera v0.3.2+99-1230f78d
[0:01:45.980768298] [1909] WARN RPiSdn sdn.cpp:40 Using legacy SDN tuning - please consider moving SDN inside rpi.denoise
[0:01:45.987154656] [1909] INFO RPI vc4.cpp:447 Registered camera /base/soc/i2c0mux/i2c@1/ov5647@36 to Unicam device /dev/media2 and ISP device /dev/media0
[0:01:45.987299795] [1909] INFO RPI pipeline_base.cpp:1120 Using configuration file ‘/usr/share/libcamera/pipeline/rpi/vc4/rpi_apps.yaml’
Preview window unavailable
Mode selection for 1296:972:12:P
SGBRG10_CSI2P,640x480/0 - Score: 3296
SGBRG10_CSI2P,1296x972/0 - Score: 1000
SGBRG10_CSI2P,1920x1080/0 - Score: 1349.67
SGBRG10_CSI2P,2592x1944/0 - Score: 1567
Stream configuration adjusted
[0:01:46.010344834] [1888] INFO Camera camera.cpp:1197 configuring streams: (0) 1296x972-YUV420 (1) 1296x972-SGBRG10_CSI2P
[0:01:46.010988407] [1909] INFO RPI vc4.cpp:622 Sensor: /base/soc/i2c0mux/i2c@1/ov5647@36 - Selected sensor format: 1296x972-SGBRG10_1X10 - Selected unicam format: 1296x972-pGAA
#0 (0.00 fps) exp 33239.00 ag 8.00 dg 1.00
#1 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#2 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#3 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#4 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#5 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#6 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#7 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#8 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#9 (30.02 fps) exp 33239.00 ag 8.00 dg 1.00
#10 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#11 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#12 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#13 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#14 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#15 (30.00 fps) exp 33239.00 ag 8.00 dg 1.00
#16 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#17 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#18 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#19 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#20 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#21 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#22 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#23 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#24 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#25 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#26 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#27 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#28 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#29 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#30 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#31 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#32 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#33 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#34 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#35 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#36 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#37 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#38 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#39 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#40 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#41 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#42 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#43 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#44 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#45 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#46 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#47 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#48 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#49 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#50 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#51 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#52 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#53 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#54 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#55 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#56 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#57 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#58 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#59 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#60 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#61 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#62 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#63 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#64 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#65 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#66 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#67 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#68 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#69 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#70 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#71 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#72 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#73 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#74 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#75 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#76 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#77 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#78 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#79 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#80 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#81 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#82 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#83 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#84 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#85 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#86 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#87 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#88 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#89 (29.99 fps) exp 33239.00 ag 8.00 dg 1.00
#90 (30.03 fps) exp 33239.00 ag 8.00 dg 1.00
#91 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#92 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#93 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#94 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#95 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#96 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#97 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#98 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#99 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#100 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#101 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#102 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#103 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#104 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#105 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#106 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#107 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#108 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#109 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#110 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#111 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#112 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#113 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#114 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#115 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#116 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#117 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#118 (30.00 fps) exp 33239.00 ag 8.00 dg 1.00
#119 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#120 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#121 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#122 (30.00 fps) exp 33239.00 ag 8.00 dg 1.00
#123 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#124 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#125 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#126 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#127 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#128 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#129 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#130 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#131 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#132 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#133 (30.00 fps) exp 33239.00 ag 8.00 dg 1.00
#134 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#135 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#136 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#137 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#138 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#139 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#140 (30.01 fps) exp 33239.00 ag 8.00 dg 1.00
#141 (30.00 fps) exp 33239.00 ag 8.00 dg 1.00

here is the error i get when running video_car.py

mjkie@raspberrypi:~/picar-x/example $ sudo python3 11.video_car.py
vilib 0.3.11 launching …
picamera2 0.3.24
Local display failed, because there is no gui.

Web display on:
eth0: error fetching interface information: Device not found
http://10.0.0.65:9000/mjpg

Starting web streaming …

  • Serving Flask app ‘vilib.vilib’
  • Debug mode: off

Press key to call the function(non-case sensitive):

O: speed up
P: speed down
W: forward
S: backward
A: turn left
D: turn right
F: stop
T: take photo

Ctrl+C: quit

status: stop , speed: 0 camera close

From the printout you provided of libcamera-hello running, the camera is recognized and working properly.

  1. What version of Raspberry Pi system are you currently using, please let us know.
  2. We recommend that you reinstall the vilib library before running the video screen example code.
    cd vilib
    sudo python3 install.py

3.Raspberry Pi Zero please configure the WiFi network.

I’m not sure exactly what I did but I turned some features on i.e. enabled vnc etc. and I am able to view the camera now. Perhaps reinstalling the vidlib helped. Thank you for your assistance. I now have another issue that I’m trying to correct but I will post in a separate post.

1 Like