Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/2729StormRobotics/StormCV2017

Computer Vision code for the 2017 FRC season
https://github.com/2729StormRobotics/StormCV2017

computer-vision first-frc first-robotics first-robotics-competition frc frc-stronghold grip opencv python raspberry-pi vision

Last synced: 3 months ago
JSON representation

Computer Vision code for the 2017 FRC season

Awesome Lists containing this project

README

        

# StormCV2017

Computer Vision code for the 2017 FRC season. This is a GRIP based vision system. We utilize the "Generate Code" feature in order to run python code on our Raspberry Pi 3.

## Getting Started

If you wish to use our setup just clone this repo to your Raspberry Pi

```
git clone https://github.com/2729StormRobotics/StormCV2017.git
```

## Project Structure

- Base directory: ```start-mjg-streamer.sh``` streams video to port 1181.
- ```/GRIP-CodeGeneration```: Vision processing code. ```run_cv.py``` is changed manually for desired calcuations.
- ```/GRIP-CodeGeneration```: All other .py files are generated by GRIP tools > GenerateCode.

### Prerequisites

We use Python 3 and OpenCV3 on our Raspberry Pi 3. Python is super easy to install...

```
sudo apt-get install python3
```

OpenCV3 is a [bit more of a pain](http://www.pyimagesearch.com/2016/04/18/install-guide-raspberry-pi-3-raspbian-jessie-opencv-3/).

Also on a windows computer you will need [Eclipse with the wpilib plugins](http://wpilib.screenstepslive.com/s/4485/m/13503/l/599679-installing-eclipse-c-java)

Lastly you'll need to install all the other packages we use from pip which are stored inside our ```requirements.txt```
```
pip install -r requirements.txt
```
Please feel free to browse the file for a list of the pip dependencies we use

## Running the Code

Assuming you've gotten all the installs running the code is fairly straightforward

- Connect both the pi and Windows machine to the same network
- On eclipse press WPIlib>RunOutlineViewer>StartServer
- Run the python code in the StormCV2017/GRIP-CodeGeneration directory

```
python3 run_cy.py
```

## Acknowledgments

We learned how to [run our generated GRIP code from WPILibs](https://github.com/WPIRoboticsProjects/GRIP-code-generation).