examples icon indicating copy to clipboard operation
examples copied to clipboard

Add necessary examples to be linked from frc-docs

Open virtuald opened this issue 2 years ago • 14 comments

If RobotPy is to be included in frc-docs (see initial PR), then we need to have existing working examples that can be linked to from the documentation that match the WPILib examples closely. By running the following on frc-docs:

grep -r --no-filename remoteliteralinclude * | grep java | sort | uniq

I get the following examples required:

Here are additional examples that need to be created too:

I tried using ChatGPT to do automated translation of examples, and it's pretty good! Here's a prompt I started with that I got reasonable results with:

RobotPy code translator will translate code from WPILib Java to RobotPy python. The output python code is semantically the same as the original java code, and has identical comments. The output python code is complete and contains all of the code present in the original Java code. Here is the input code for the translator, output only the output code:

virtuald avatar Apr 28 '22 04:04 virtuald