jupyter notebooks & HTML files containing material for introducing FRC programming for beginners, introducing java syntax and features as well as WPILib and 3rd party libraries.
there are a few things that are needed for this series of documents:
The JDK is essential to running java code and comes with JShell, which will be used for demonstration purposes.
WPILib is the primary tool used for FRC programming and comes with a packaged version of VSCode, the editor that we'll use to write our programs in, in addition to a number of other useful applications.
Git is a version control system that we'll use to manage the development of our programs and keep track of changes to our code (and roll things back if necessary)
Documents can be viewed as HTML files by cloning/downloading the repository, and then opening up the HTML documents in the Pages folder.
Alternatively, the ipynb files can be viewed directly through nbviewer, providing this GitHub repository's URL into the box
The content is broken down into 4 different parts:
- basic java: introducing basic java concepts such as control structures, statements, and scoping through jshell.
- Statements
- Comments
- Variables and Types
- Conditionals (ifs)
- Loops (while, for)
- Functions
- Scopes
- Operators (arith & logical)
- Arrays
- classes in java: introducing classes, as well as fields/methods, and creating complete java programs without jshell.
- Classes (syntax & motivation)
- Fields & Methods
- Constructors
- Access Modifiers
- Static Modifier (maybe add section on final)
- Import & Packages
- even more java: expands on classes, and introduces interfaces, generics, and more advanced java features.
- Inheritance & Polymorphism
- Abstract Classes
- Interfaces
- Javadocs
- Generics
- Enums
- frc introduction: introducing FRC programming by installing and introducing tools, and taking a brief look at the code.
- Tool installation (WPILib, Git)
- FRC Project Creation
- Project Structure & Deployment
- 3rd Party Libraries
- Code Structure
- Electronics (identifications)
- Electronics in Code
- Competition Phases
- Git introduction
- frc code in detail: introducing code components in detail
- High-level Organization
- Subsystems
- Controller Inputs through polling
- General Project Organization
- lambdas and command-based design / philosophy
- Lambdas and method references
- Commands
- Command Scheduler
- Subsystem-Command interactions
- Command factories
- BooleanEvents and Triggers as alternatives to polling
Note, none of the documents are fully exhaustive in their content. For more in depth explanations, look for long form tutorials on websites like Baeldung, or alternatively, look at the java language specification
For information more related to FRC programming, it is best to visit the wpilib documentation (An offline copy can be accessed after installing WPILib)
To make modifications, it's necessary to install jupyter as well as the java kernel. From there, either use the provided editor, or notebook extensions/plugins on editors like VSCode to make changes to the files inside Notebooks
.
To convert the notebooks into viewable html files, run make
(if you have a gnu make installation) or alternatively copy the contents of the mkPages
rule and run it.