Just import picamerax if Pi is used

tis
Jeff Moe 2022-07-31 22:09:59 -06:00
parent cf5916dd0e
commit 4b7842a737
2 changed files with 5 additions and 3 deletions

View File

@ -99,7 +99,7 @@ Get the latest TLEs:
```
# Misc
# Fixed
When running `acquire.py` on `amd64` architecture it gives this error:
```
@ -117,6 +117,8 @@ That error comes from installing `picamerax` on `amd64`, which was added to
env/lib/python3.10/site-packages/picamerax/bcm_host.py:_lib = ct.CDLL('libbcm_host.so')
```
For now, just import the library that calls for that binary if the
Pi camera is used. No need to call it (and crash) if CV2 is used on non-Pi.
# Upstream

View File

@ -15,12 +15,12 @@ import logging
import configparser
import argparse
import zwoasi as asi
from picamerax.array import PiRGBArray
from picamerax import PiCamera
# Capture images from pi
def capture_pi(image_queue, z1, t1, z2, t2, nx, ny, nz, tend, device_id, live, cfg):
from picamerax.array import PiRGBArray
from picamerax import PiCamera
# Intialization
first = True
slow_CPU = False