Skip to content

Commit 4f52706

Browse files
committed
update alt text and add Cameras and USB Hubs section with new images.
1 parent fa817cb commit 4f52706

File tree

4 files changed

+89
-10
lines changed

4 files changed

+89
-10
lines changed

docs/source/hardware_and_software_configuration/configuring/configuring_external_webcam/configuring-external-webcam.rst

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Type of External Camera
1818
-----------------------
1919

2020
Theoretically, any USB Video Class (UVC) camera should work with the
21-
system. However, FIRST recommends using UVC web cameras from Logitech.
21+
system. However, *FIRST* recommends using UVC web cameras from Logitech.
2222
The following cameras have been tested and calibrated to work accurately
2323
with SDK software:
2424

@@ -53,6 +53,8 @@ powered USB hub.
5353
with devices plugged into the USB 2.0 port.
5454
Using the USB 2.0 Port may cause ESD to affect your Control Hub's Wi-Fi Chip (causing Wi-Fi disconnects with the driver hub).
5555
Ensure that you plug USB devices, such as a Camera, into the USB 3.0 Port on your Control Hub.
56+
57+
If you wish to connect two webcams see `Cameras and USB Hubs`_.
5658

5759
Camera Configuration
5860
--------------------
@@ -180,3 +182,56 @@ For custom streams, advanced users of Android Studio may consult the
180182
and
181183
`CameraStreamSource <https://javadoc.io/doc/org.firstinspires.ftc/RobotCore/latest/org/firstinspires/ftc/robotcore/external/stream/CameraStreamSource.html>`__
182184
classes.
185+
186+
Cameras and USB Hubs
187+
^^^^^^^^^^^^^^^^^^^^
188+
189+
You can already connect a UVC webcam into the USB 3.0 port of a Control Hub.
190+
But what if you want to use two webcams?
191+
Perhaps you want the robot to be able to look forward and/or behind without having to spin the robot.
192+
In order to use two webcams on the Control Hub's USB 3.0 port you can add a USB Hub.
193+
This avoid the ESD issue with devices on the USB 2.0 port.
194+
195+
.. note:: If you're using two standard UVC webcams you are not required to use a powered USB hub.
196+
197+
Another use case for a USB hub is if you have a `Limelight 3A <https://limelightvision.io/products/limelight-3a>`_ camera.
198+
This device has its own processor on board and one drawback of this is that the camera always draws power, even when an opMode is not running.
199+
By adding a powered USB hub the Limelight will not drain your robot's battery.
200+
201+
One suitable powered USB hub is the Acer ODK350 5-IN-1 USB 3.0 Hub.
202+
It provides USB 3.0 data speeds to all ports and it has a USB C port that can supply power to all connected devices.
203+
204+
.. note:: At the time this was written, the Acer ODK350 hub was not listed on Acer's website, but was available on Amazon's website.
205+
206+
Not all USB hubs are powered hubs.
207+
Typically, you can't just plug a power bank into any of the USB hub's ports. It must be a port that is designed to supply power.
208+
So if you looking for a powered USB hub there should be a note in the specifications something like the following:
209+
*Note: This USB C port (with IN 5V printed) can not be used for data transfer and charge other devices. It can only supply power for the other 4 USB ports.*
210+
211+
.. figure:: images/two-webcams.jpg
212+
:alt: A USB hub with two webcams is connected to a REV Control Hub.
213+
214+
Acer ODK350 USB hub
215+
216+
The USB Hub is connected to the USB 3.0 port of the Control Hub.
217+
A powerbank is connected to the USB C port on the USB hub to supply power to the connected devices.
218+
Two Logitech 920 webcams are connected to the USB hub.
219+
220+
See the `AprilTag Switchable Cameras <https://github.com/FIRST-Tech-Challenge/FtcRobotController/blob/master/FtcRobotController/src/main/java/org/firstinspires/ftc/robotcontroller/external/samples/ConceptAprilTagSwitchableCameras.java>`_ sample program that demonstrates swapping between the two cameras to detect AprilTags.
221+
222+
The other use case is using a Limelight a with a powered USB hub to reduce robot battery drain.
223+
This example shows both a Limelight and a webcam.
224+
225+
.. figure:: images/webcam-and-limelight-3a.jpg
226+
:alt: A USB hub with a webcam and a Limelight 3A connected to a REV Control Hub.
227+
228+
Acer ODK350 USB hub
229+
230+
The USB Hub is connected to the USB 3.0 port of the Control Hub.
231+
A powerbank is connected to the USB C port on the USB hub to supply power to the connected devices.
232+
A Logitech 270 webcam and a Limelight 3A are connected to the USB hub.
233+
234+
The Limelight 3A is not a compatible VisionPortal device. So you can't use the AprilTag switchable camera sample code.
235+
But you can still get results from either the Limelight and/or the VisionPortal webcam and use them as required.
236+
237+
211 KB
Loading
238 KB
Loading

docs/source/hardware_and_software_configuration/configuring/configuring_uvc_camera/configuring-uvc-camera.rst

Lines changed: 33 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,33 +23,42 @@ run properly.
2323
What type of External Camera can be Used?
2424
-----------------------------------------
2525

26-
The system supports a UVC” or USB Video Device Class cameras.
26+
The system supports a UVC cameras.
2727
Theoretically, if a camera is UVC compliant, then it should work with
2828
the system. However, there are a couple of recommended web cameras that
29-
have been tested with the FIRST Tech Challenge software and have been
29+
have been tested with the *FIRST* Tech Challenge software and have been
3030
calibrated to work accurately with this software:
3131

3232
- Logitech HD Webcam C310
3333
- Logitech HD Pro Webcam C920
3434

35+
There are notes on :doc:`other UVC webcams <../../../apriltag/vision_portal/visionportal_webcams/visionportal-webcams>`
36+
that teams can use.
37+
3538
Note that calibrating a UVC camera is an advanced task. Details on how
3639
to create a calibration file can be found in the comments of the
3740
*teamwebcamcalibrations.xml* file that is available as part of the
3841
ftc_app project folder (visit this
3942
`link <https://github.com/ftctechnh/ftc_app/blob/master/TeamCode/src/main/res/xml/teamwebcamcalibrations.xml>`__
4043
for an online copy of the file).
4144

45+
REV Expansion Hub and Phone
46+
---------------------------
47+
48+
For teams using an Android phone and an Expansion Hub you are required to add a USB Hub to use a webcam.
49+
4250
.. image:: images/uvcdiagram.png
51+
:alt: A REV expansion hub connected to an Android phone and a webcam via a USB Hub.
4352

4453
USB Hub
45-
-------
54+
^^^^^^^
4655

4756
Teams who would like to use an external camera will need a USB hub to
4857
connect their Android Robot Controller to the external camera and the
4958
REV Robotics Expansion Hub. To work properly, the USB hub should meet
5059
the following requirements:
5160

52-
1. Compatible with USB 2.0.
61+
1. Compatible with USB 2.0. Note: a USB 3.0 hub will still work, just not at the faster speed.
5362
2. Supports a data transfer rate of 480Mbps.
5463

5564
Note that the Modern Robotics Core Power Distribution Module cannot be
@@ -66,17 +75,19 @@ come from either of the following sources:
6675
2. The 5V DC Aux power port of a REV Robotics Expansion Hub (note that
6776
this requires advanced skills to implement).
6877

69-
FIRST has tested a few USB 2.0 powered hubs and recommends one from
78+
*FIRST* has tested a few USB 2.0 powered hubs and recommends one from
7079
Anker. At the time this document was written, this hub was available
7180
from `Anker.com <https://www.anker.com/products/a7516>`__.
7281

7382
.. image:: images/ankerhub.jpg
83+
:alt: Hub with charger and cable.
7484

7585
The Anker 4-port powered hub is convenient because it has a Micro USB
7686
port that is used to connect the hub to a 5V power source (highlighted
7787
with orange circle in figure below).
7888

7989
.. image:: images/ankerpowerport.jpg
90+
:alt: USB Hub with Micro USB port.
8091

8192
This port allows a user to plug a standard USB type B Micro Cable into
8293
the hub, and then connect the other end of the cable (which has a USB
@@ -86,14 +97,25 @@ pack. In the image below, the Anker 4 port hub is powered by a
8697
USB Micro cable. Note the battery is highlighted by the yellow outline
8798
in the figure below.
8899

89-
.. image:: images/limefuel.png
100+
.. figure:: images/limefuel.png
101+
:alt: A complete setup for using a phone and webcam.
102+
103+
The USB hub is drawing power from a power bank.
104+
105+
The USB hub is connected via it's Type A connector and cable to an OTG cable which connects to the phone.
106+
The power bank is connected to the USB type B Micro port on the USB hub.
107+
The webcam is connected to one of the USB type A ports on the USB hub.
108+
A USB Type A to USB Mini B cable connects the USB hub to the REV Expansion Hub.
90109

91110
A USB hub can also draw power from the 5V auxiliary ports on the REV
92111
Robotics Expansion Hub. This configuration requires that the user have a
93112
special cable that on one end can be plugged into the 5V Auxiliary port
94113
and on the other end can be plugged into the power port of the USB hub.
95114

96-
.. image:: images/5vauxcable.png
115+
.. figure:: images/5vauxcable.png
116+
:alt: :alt: A complete setup for using a phone and webcam.
117+
118+
The USB hub is connected to the 5V Auxiliary port.
97119

98120
Note that teams can create this special cable using one end of a servo
99121
extension cable (to plug into the 5V aux port) and one end of a Micro
@@ -105,10 +127,10 @@ special cable. If the polarity is reversed it could damage your
105127
electronic equipment.**
106128

107129
Sample Op Modes
108-
---------------
130+
^^^^^^^^^^^^^^^
109131

110132
There are sample Blocks and Java Op Modes that demonstrate how to use
111-
the external UVC web camera for Vuforia or TensorFlow operations. Before
133+
the external UVC web camera for VisionPortal operations. Before
112134
a team can use the external UVC camera, a configuration file must be
113135
configured with the external camera defined as one of the USB-connected
114136
devices.
@@ -118,3 +140,5 @@ programmer can use the external UVC camera, instead of the internal
118140
Android cameras, for vision-related tasks.
119141

120142
.. image:: images/blockswebcam.png
143+
:alt: Sample Blocks code
144+

0 commit comments

Comments
 (0)