As Scouting Captain of Team 175, I have been working to develop a Scouting app for this years game. This program is a start to basic data insert, and recording for team data. This code down below can be used by others, I am sharing it so other teams may use it as well, to begin with the personal learning, experience, and developing of their own Scouting Application.
//Scouting Summary Card Creator Application Version 1.0 Alpha
//Imports
import java.util.Scanner;
import java.util.Arrays;
import java.util.Collection;
import java.io.FileWriter;
import java.io.IOException;
import java.io.PrintWriter;
import java.io.File;
import java.util.Date;
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class SummaryCardApplication {
static Scanner input = new Scanner(System.in);
public static void main(String[] args) throws IOException {
// TODO Auto-generated method stub
//int
int ta = 0;
//Strings
String welcome = "Welcome to Scoutastic alpha 1.0:";
String appinfo = "This applicaiton is open source, and programed by Bradley Hornung"
+ "from FRC team Buzz Robotics 175 Enfield Application Version: 1.0 Alpha";
String ui = "How many summary cards do you wish to make today?";
String tar = "Array data has been created for " + ta + " teams:";
String w1 = "Once you begin, you cannot stop until all data is entered, in order for data "
+ "to be entered into file:";
//String questions
String qn = "Enter team number, and name:";
String q1 = "What did they do for Gate? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q2 = "What did they do for Sea Saw? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q3 = "What did they do for Moat? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q4 = "What did they do for Ramp? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q5 = "What did they do for DrawBridge? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q6 = "What did they do for Sally Door? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q7 = "What did they do for Rock Wall? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q8 = "What did they do for Rough Terrain? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q9 = "What did they do for Low Bar? Key [A]Auto [AF]Auto Fail [T]Teleop [F]Teleop Fail";
String q10 = "Comments:";
//Junk
String j;
//User intro to application
System.out.println(welcome);
System.out.println(ui);
ta = input.nextInt();
//User's response String variables
String[] tn;
tn = new String[ta];
String[] g;
g = new String[ta];
String[] ss;
ss = new String[ta];
String[] m;
m = new String[ta];
String[] r;
r = new String[ta];
String[] db;
db = new String[ta];
String[] sd;
sd = new String[ta];
String[] rw;
rw = new String[ta];
String[] rt;
rt = new String[ta];
String[] lb;
lb = new String[ta];
String[] c;
c = new String[ta];
j = input.nextLine();
//Questions
for (int i = 0; i < ta; i++){
System.out.println(qn);
tn[i]= input.nextLine();
System.out.println(q1);
g[i]= input.nextLine();
System.out.println(q2);
ss[i]= input.nextLine();
System.out.println(q3);
m[i]= input.nextLine();
System.out.println(q4);
r[i]= input.nextLine();
System.out.println(q5);
db[i]= input.nextLine();
System.out.println(q6);
sd[i]= input.nextLine();
System.out.println(q7);
rw[i]= input.nextLine();
System.out.println(q8);
rt[i]= input.nextLine();
System.out.println(q9);
lb[i]= input.nextLine();
System.out.println(q10);
c[i] = input.nextLine();
}
PrintWriter pwriter = new PrintWriter
(new FileWriter("ScoutingSummaryCard.csv"));
pwriter.println("Team Name" + "," + "Gate" + "," + "Sea Saw" + "," + "Moat" + "," + "Ramp"
+ "," + "Draw Bridge" + "," + "Sally Door" + "," + "Rock Wall" + "," + "Rough Terrain" + "," + "Low Bar");
for (int i = 0; i < ta; i ++){
pwriter.println(tn + "," + g + "," + ss + "," + m + "," + r + "," + db + "," + sd
+ "," + rw + "," + rt + "," + lb + "," + c);
}
}
}