We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7942c5a commit 3cffd3bCopy full SHA for 3cffd3b
examples/Script/script_read_calibration.py
@@ -1,4 +1,4 @@
1
-import cv2
+#!/usr/bin/env python3
2
import depthai as dai
3
4
# Start defining a pipeline
@@ -8,6 +8,7 @@
8
script = pipeline.create(dai.node.Script)
9
script.setProcessor(dai.ProcessorType.LEON_CSS)
10
script.setScript("""
11
+ import time
12
13
cal = Device.readCalibration2()
14
left_camera_id = cal.getStereoLeftCameraId()
@@ -19,9 +20,14 @@
19
20
print(extrinsics)
21
print(intrinsics_left)
22
23
+ time.sleep(1)
24
+ node.io['end'].send(Buffer(32))
25
""")
26
27
+xout = pipeline.create(dai.node.XLinkOut)
28
+xout.setStreamName('end')
29
+script.outputs['end'].link(xout.input)
30
+
31
# Connect to device with pipeline
32
with dai.Device(pipeline) as device:
- while True:
- pass
33
+ device.getOutputQueue('end').get()
0 commit comments