Once running each of them I get an Import Error saying No module named arducam_mipicamera
This happens even if I previously installed the libarducam_mipicamera.so, as prompted in the instructions, through the commands:
sudo pip install v4l2
sudo pip install numpy
sudo apt-get install python-opencv
Am I missing something? Is the library updated?
2 - When trying to run the opencvGui I get an error message stating:
Unable to init server: Could not connect: Connection refused
(Arducam mipi camera controller:995): Gtk-WARNING **: 16:42:35.957: cannot open display:
3 - This last might be a simple one:
when I start the camera preview by typing ./arducamstill -t 0, how do I stop it?
I usually interrupt the programs via terminal, by typing ctrl + c, but in this case it seems like having no effect.
Whoever would like to help, I’d very much appreciate so !
Once running each of them I get an Import Error saying No module named arducam_mipicamera
A: Please ensure you have done the following commands to install the arducam_mipicamera lib
cd MIPI_Camera/RPI
make install
2 – When trying to run the opencvGui I get an error message stating:
Unable to init server: Could not connect: Connection refused
(Arducam mipi camera controller:995): Gtk-WARNING **: 16:42:35.957: cannot open display:
A2:The opencv display need to a display screen. Please run the demo on the local instead of remote terminal.
3 – This last might be a simple one:
when I start the camera preview by typing ./arducamstill -t 0, how do I stop it?
I usually interrupt the programs via terminal, by typing ctrl + c, but in this case it seems like having no effect.
A: You should push CTRL+C double time to exit the demo, the first time is to exit camera and the second is to exit keyboard detected. I have not find a good way to exit at the same time.
Firstly, many thanks for your prompt and on point reply.
Everything you suggested seemed to work, a part from the issue highlighted in question number 1: “Once running each of them I get an Import Error saying: No module named arducam_mipicamera”
I keep being given the same ImportError, even if I went through the arducam_mipicamera lib installation once again. This happens all the times I try to run one of the python examples you provided in your GitHub repository.
This last time I was working on the example called capture.py. I tried both saving it within the MIPI_Camera/RPI folder and on the Desktop, and running them respectively, but no luck.
When following the commands:
cd MIPI_Camera/RPI
make install
I’m given this message: sudo install -m 644 lib/libarducam_mipicamera.so /usr/lib/
I’m now wondering if the library has actually been successfully installed?
So I can confirm that the ./ arducamstill commands work correctly. I can in fact run through all the examples you provide in the introduction documentation.
Regarding the .c code, they all seem to have issues in the code. For example, if I run ~/MIPI_Camera/RPI $ python preview.c
I’m prompted an SintaxError stating:
File “preview.c”, line 11
int main(int argc, char **argv) {
^
SyntaxError: invalid syntax
Is the one I can find in the GH repo the latest version of the code?
preview.c is C code, such as arducamstill.c, if you want to use it, you should make it using make preview command. then run it using ./preivew instead of python preview.c.
I tried what suggested for the C code and I can confirm it works, therefore all the checking tests seem pasted.
However, the python files keep prompt me the same error message.
This time I tried with the ArducamTest.py I found within the RPI folder. This is the error message I’m given: