我試圖在我的樹莓派上運行picam。不幸的是,我沒有得到圍繞以下導入錯誤:導入錯誤在樹莓派上運行picam
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-1-ae50f21e1c18> in <module>()
----> 1 import picam
2 import time
/usr/local/lib/python2.7/dist-packages/picam/__init__.py in <module>()
1 # Copyright (c) 2013 Sean Ashton
2 # Licensed under the terms of the MIT License (see LICENSE.txt)
----> 3 from _picam import *
4 import StringIO
5 from PIL import Image
ImportError: /usr/local/lib/python2.7/dist-packages/picam/_picam.so: cannot open shared object file: No such file or directory
我一直在尋找所有的地方(例如:cannot open shared object file: No such file or directory),但至今沒有成功。重新編譯也沒有工作,由於一大堆失蹤庫(mmal.h,vcos.h等)
更新:
UPDATE2:
[email protected] ~ $ ldd /usr/local/lib/python2.7/dist-packages/picam/_picam.so
not a dynamic executable
update3:
[email protected] ~ $ file /usr/local/lib/python2.7/dist-packages/picam/_picam.so
/usr/local/lib/python2.7/dist-packages/picam/_picam.so:ELF 32位LSB共享對象,ARM版本1(SYSV),動態鏈接,BuildID [sha1] = 0xe403bf379f8c1dc2cb82df774ac3f11998661ff1,不去除
readelf -d /usr/local/lib/python2.7/dist-packages/picam/_picam.so
Dynamic section at offset 0x700c contains 37 entries:
Tag Type Name/Value
0x00000001 (NEEDED) Shared library: [libmmal_core.so]
0x00000001 (NEEDED) Shared library: [libmmal_util.so]
0x00000001 (NEEDED) Shared library: [libmmal_vc_client.so]
0x00000001 (NEEDED) Shared library: [libvcos.so]
0x00000001 (NEEDED) Shared library: [libbcm_host.so]
0x00000001 (NEEDED) Shared library: [libpython2.7.so.1.0]
0x00000001 (NEEDED) Shared library: [libpthread.so.0]
0x00000001 (NEEDED) Shared library: [libdl.so.2]
0x00000001 (NEEDED) Shared library: [librt.so.1]
0x00000001 (NEEDED) Shared library: [libvchiq_arm.so]
0x00000001 (NEEDED) Shared library: [libc.so.6]
0x0000000e (SONAME) Library soname: [_picam.so]
0x0000000f (RPATH) Library rpath: [/home/pi/SOURCE/userland/build/lib]
0x0000000c (INIT) 0x1d88
0x0000000d (FINI) 0x5840
0x00000019 (INIT_ARRAY) 0xf000
0x0000001b (INIT_ARRAYSZ) 4 (bytes)
0x0000001a (FINI_ARRAY) 0xf004
0x0000001c (FINI_ARRAYSZ) 4 (bytes)
0x00000004 (HASH) 0xf8
0x6ffffef5 (GNU_HASH) 0x444
0x00000005 (STRTAB) 0xcbc
0x00000006 (SYMTAB) 0x5bc
0x0000000a (STRSZ) 2330 (bytes)
0x0000000b (SYMENT) 16 (bytes)
0x00000003 (PLTGOT) 0xf154
0x00000002 (PLTRELSZ) 712 (bytes)
0x00000014 (PLTREL) REL
0x00000017 (JMPREL) 0x1ac0
0x00000011 (REL) 0x16f8
0x00000012 (RELSZ) 968 (bytes)
0x00000013 (RELENT) 8 (bytes)
0x6ffffffe (VERNEED) 0x16b8
0x6fffffff (VERNEEDNUM) 2
0x6ffffff0 (VERSYM) 0x15d6
0x6ffffffa (RELCOUNT) 114
0x00000000 (NULL) 0x0
任何幫助將不勝感激!
你是如何安裝它的?我的意思是模塊? – Oz123
我使用了兩種方法 - 第一種是通過'''sudo python setup.py install''',然後通過'''sudo pip install https://github.com/ashtons/picam/zipball/master/ egg = picam'' '用相同的結果 - 在我之間用''sudo pip卸載picam'''來卸載它 –
你可以在http://raspberrypi.stackexchange.com/ – Oz123