File tree Expand file tree Collapse file tree 3 files changed +26
-7
lines changed Expand file tree Collapse file tree 3 files changed +26
-7
lines changed Original file line number Diff line number Diff line change
1
+ # Camera Data Module
2
+
3
+ This module read and writes data from available camera feeds to the ` /camera_frames ` topic.
4
+
5
+ ### Messages
6
+
7
+ - ` v_angle ` : Vertical orientation tilt of the camera enclosed in [ -90, 90] degrees (The pitch axis of rotation).
8
+ - ` h_angle ` : Horizontal orientation tilt of the camera enclosed in [ -90, 90] degrees (The Yaw axis of rotation).
9
+
10
+ ### Scripts
11
+
12
+ - ` camera_feeds.py ` : Collects available camera ports and outputs them all in distinct windows.
13
+ - ` camera_subscriber.py ` : Subscriber to the ` /camera_frames ` topic that displays the images to screen.
14
+ - ` camera_publisher.py ` : Publishes frames from the selected camera (from the ` camera_selection ` topic) to the
15
+ ` /camera_frames ` topic at a rate of __ 30fps__ .
16
+
17
+ ### Tests
18
+
19
+ - ` test_get_cameras.py ` : Tests the camera feed collection from the ` camera_feeds.py ` script.
Original file line number Diff line number Diff line change @@ -14,13 +14,13 @@ def __init__(self):
14
14
self .available_cameras .append (newCap )
15
15
16
16
def get_all_feeds (self ):
17
- retAndFrame = []
17
+ ret_frame = []
18
18
# read each capture object in vids and add as a tuple to retAndFrame
19
19
for camera in self .available_cameras :
20
20
newFeed = camera .read ()
21
- retAndFrame .append ((newFeed [0 ], newFeed [1 ]))
21
+ ret_frame .append ((newFeed [0 ], newFeed [1 ]))
22
22
23
- return retAndFrame
23
+ return ret_frame
24
24
25
25
def run_feeds (self ):
26
26
while True :
@@ -38,5 +38,5 @@ def run_feeds(self):
38
38
39
39
# Runnable to display camera feeds
40
40
if __name__ == '__main__' :
41
- camHandler = CameraHandler ()
42
- camHandler .run_feeds ()
41
+ camera_handler = CameraHandler ()
42
+ camera_handler .run_feeds ()
Original file line number Diff line number Diff line change 9
9
import getCameraFeeds as gcf
10
10
11
11
# Runnable to display camera feeds
12
- camHandler = gcf .CameraHandler ()
13
- camHandler .run_feeds ()
12
+ camera_handler = gcf .CameraHandler ()
13
+ camera_handler .run_feeds ()
You can’t perform that action at this time.
0 commit comments