mebin
Posts: 11
Joined: Sun Sep 03, 2017 2:20 am

OpenCV -python program-at startup-not working-raspbian

Thu Sep 14, 2017 3:53 am

Hi,
I m working in a project, where i want start a opencv-python program on raspbian startup. The program is such like to open the picamera and do some image processing and display it in full-screen mode. Actually i did it by adding the command "python filename.py" at the end of the file .bashrc.
And set the pi to boot to CLI (command line interface). after rebooting it shows errors

Code: Select all

final:920: Gtk-WARNING**: cannot open display:


How can i fix it?
Please help me.
Thanks in advance

User avatar
topguy
Posts: 6491
Joined: Tue Oct 09, 2012 11:46 am
Location: Trondheim, Norway

Re: OpenCV -python program-at startup-not working-raspbian

Thu Sep 14, 2017 1:28 pm

OpenCV depends on having a running X-Windows server, so you cant use "boot to CLI".
You need to let the X-server (Desktop) start before you can start your program.

Return to “General discussion”