Programming Workshop Quixilver 8404
1 2 3 Agenda Setting up the Developing Environment The Programming Workflow 2 Version Control 3 Setup development environment Download and install Android Studio Setup the phones Download FTC project from GitHub Import the project into Android Studio Create a basic program Explore the project file structure Create autonomous and teleOp programs that control a single motor Compile and upload the program onto the robot controller phone Setup the robot’s hardware configuration within the app Run the Autonomous and TeleOp programs Setup version control Create a Bitbucket account Make a new repository by importing the FTC app Download and install Git Download and install SourceTree Clone the remote repository Explore the fetch, pull, and push features Add the FTC GitHub repository as the upstream remote Explore how to stage, commit, and push code
Installing android studio Development Environment
Download Android Studio developer.android.com/studio
Development Environment Setting up the phones Development Environment
Legal Phones ZTE Speed Motorola Moto G 2nd Generation Motorola Moto G 3rd Generation Motorola Moto G4 Play Google Nexus 5 Samsung Galaxy S5
The Rules Android device is named with the official Team number followed by –DS or –RC as appropriate Android operating system satisfies the requirements: ZTE Speed – version 4.4 or higher, Motorola Moto G4 Play 6.0.1 or higher, all other allowed Android devices – version 6.0 or higher The Android device is set to airplane mode, and Bluetooth is turned off Android Wi-Fi Direct device name does not include a newline character in the name Robot is not connected to any local networks All remembered Wi-Fi Direct Groups have been removed Driver Station uses the official FTC Driver Station app to control the Robot The FTC controller app is the default application, the application launches, and no other messages pop up The FTC Wi-Fi Direct Channel Changing App is installed on the Robot Controller (for ZTE Speed devices only) Robot Controller is set to the correct Wi-Fi Direct channel
Downloading the ftc project github.com/ftctechnh/ftc_app
Development Environment Importing a project Development Environment
Programming workflow
1 2 3 4 Key Ideas Project File Structure Creating Autonomous and TeleOp Programs 2 Code Structure 3 Building and Running 4
Using Version control Code Maintenance
Git, Bitbucket, and SourceTree A commonly used version control system Bitbucket An online hosting solution SourceTree A version control client that works well with Bitbucket
Prerequisites Setup Bitbucket 1 Install Git 2 Install SourceTree 3
Setting up Bitbucket bitbucket.org
Installing Git git-scm.com
Run the Installer Leave All Settings to Defaults Mac Setup May Differ
Installing SourceTree sourcetreeapp.com