Skip to content

team401/Vision-Tutorials

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 

Repository files navigation

401 Vision

GPLV3 licensed

NOTE: This code will only run on a Linux based operating system. Ubuntu is free, easy to install, and great for beginners. You will also need to install OpenCV, the installation guides for the most common distros of Linux can be found here.

This is FRC Team 401 Copperhead Robotics' Vision Code for 2017, the files in this repository are the three most important files used in vision processing for STEAMWORKS. We used a Playstation Eye webcam as our main camera and the traditional green LED ring. The following files are included:

  • Main.cpp: The main vision processing file that calculates yaw, pitch, and distance
  • flCalculator.cpp: Finds the focal length of your camera, import for being used in Main.cpp
  • hsvFinder.cpp: Finds the HSV values of a pixel while looking through your camera

OpenCV Installation

Ubuntu Guide

Debian Guide

Fedora Guide

Arch Guide

Running one of the Programs

Open up a terminal and navigate to the folder and run the following commands:

Create a directory called build

mkdir build

Go inside of build

cd build

Set up CMake so it can easily compile code on the fly

cmake ..

Compile the code to create runnable files

make

Go back up a directory

cd ..

Run the selected file

./bin/FILENAME

For any questions about our vision code you can reach us here, good luck to all of the teams out there this year!