Skip to content

DevonRD/Motion-Profile-Mapper-2018

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logo

Motion Profile Mapper (2018)

Report Bug · My Portfolio

Table of Contents

  1. About The Project
  2. Try it Out
  3. Usage
  4. License
  5. Contact

About The Project

In my final year of high school, as lead programmer of FRC Team 3539, my main goal was to develop an application that creates paths on the field that the robot could read and follow based solely on user input. In the first 15 seconds of every game the robot needed to move by itself, and instead of hard-coding motor speeds and times manually and spending hours testing each resulting path, we created this application to quickly design a specific path and automatically generate motor velocity and time data in Java for the robot to follow that path. This was much easier to use and allowed us to be more versatile during competitions, where the ability to change based on your teammates' needs was essential. I am extremely grateful to our mentor, Mr. VanCamp, who provided framework and guidance and was absolutely essential in our journey to reaching the end product.

Built With

The User Interface

In the game for 2018, there were obstacles on the field (shown as green, red, and yellow boxes) that needed to be traversed autonomously. We could only stand back and watch as the robot moved on its own, without any human input. All robot movement was guided by the paths generated in this program, as seen in the demonstration.

Product Name Screen Shot

The user creates points on the chart that the robot should follow, and the program uses those points to create two separate paths, one for each side of the robot.

Velocity Calculation

After two splines are generated for the left and right sides of the robot, the application then creates a complete guide of velocity values that the robot should apply to its motors in order to accurately follow the path. This was an especially difficult task, since the motors have physical limitations beyond what might be mathematically possible.

Product Name Screen Shot

Shown here are the corresponding velocity maps for the left (blue) and right (red) sides of the robot. This data was generated from the demonstrated path above! Turns are indicated by an increase in velocity for one side and a decrease in velocity for the other side.


Some issues that we had to work around were the minor physical differences between motors, the need to ramp-up and ramp-down velocities for optimal performance (including battery saving), and possible variations in actual field measurements from competition to competition.

Competition Versatility

During competition, we were often paired with teammates that had autonomous plans that conflicted with ours. For example, both of our robot paths could end up colliding during the game, which could break the robots. In those cases, instead of having to re-code, debug, and test new plans (which was impossible given competition time constraints), we simply opened up the motion profile mapper, drew a new path according to their needs, and had everything ready to go within minutes. This proved to be critical to our success in many matches.

Good Practice

One major difference between this project and my other projects at the time was the necessity of programming professionally. Upon graduation, this application was going to be passed down to future programmers on the team to improve and maintain for years to come. Because of that, I needed to make sure that all code that I wrote was clean, easy to follow, and properly documented. This, of course, is much easier said than done. However, this was where I developed most of my good programming practices, which have influenced the structures of my future projects. This application is still used by team programmers today!

Try it Out

This GitHub repository contains an archived version of this mapper from when I graduated in 2018. Feel free to download it and try it out! You can watch this video of our robot following a motion profile path live at the FRC State Championship in Michigan. Watch team 3539 for the first 15 seconds!

Usage

Click on the map to create points for the robot to follow. The "Apply" button creates splines along this point path and generates the motion profile. After creating a path, click the "Data" tab to view the distance and velocity calculations that will be sent to the robot.

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Devon Doyle - Portfolio - [email protected]

Project Link: https://github.com/DevonRD/Motion-Profile-Mapper-2018

About

Archived version from 2018

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published