Skip to content

Commit

Permalink
send output to sys.stderr
Browse files Browse the repository at this point in the history
  • Loading branch information
VanDavv authored Jan 25, 2022
1 parent 4f079aa commit cb38edb
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions apps/uvc/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@
import platform
import depthai as dai
import time
import sys
from depthai_helpers.arg_manager import parseArgs

args = parseArgs()


if platform.machine() == 'aarch64':
print("This app is temporarily disabled on AARCH64 systems due to an issue with stream preview. We are working on resolving this issue")
print("This app is temporarily disabled on AARCH64 systems due to an issue with stream preview. We are working on resolving this issue", file=sys.stderr)
raise SystemExit(1)

enable_4k = True # Will downscale 4K -> 1080p
Expand All @@ -35,7 +36,7 @@
# Pipeline defined, now the device is connected to
with dai.Device(pipeline, usb2Mode=args.usbSpeed == "usb2") as device:
if device.getDeviceInfo().desc.protocol == dai.XLinkProtocol.X_LINK_USB_VSC and device.getUsbSpeed() not in (dai.UsbSpeed.SUPER, dai.UsbSpeed.SUPER_PLUS):
print("This app is temporarily disabled with USB2 connection speed due to known issue. We're working on resolving it. In the meantime, please try again with a USB3 cable/port for the device connection")
print("This app is temporarily disabled with USB2 connection speed due to known issue. We're working on resolving it. In the meantime, please try again with a USB3 cable/port for the device connection", file=sys.stderr)
raise SystemExit(1)
print("\nDevice started, please keep this process running")
print("and open an UVC viewer. Example on Linux:")
Expand Down

0 comments on commit cb38edb

Please sign in to comment.