allwpilib
allwpilib copied to clipboard
Renamed Encoder to QuadratureEncoder
Fixes #2185
A version of PR #2416 with both Java and C++ fix.
Moved functionality to QuadratureEncoder class, leaving Encoder a deprecated wrapper class.
How do I run wpiformat, etc.?
Follow https://github.com/wpilibsuite/styleguide/blob/master/wpiformat/README.rst to install it. py3 -m wpiformat
or python3 -m wpiformat
runs it. See wpiformat --help
for more.
It would seem that the problem here is C++ compiling. Now working on it, in addition to adjusting examples.
Looks like examples are failing. e.g.
wpilibcExamples/src/main/cpp/examples/GyroDriveCommands/cpp/subsystems/DriveSubsystem.cpp:41:6: error: 'Encoder' in namespace 'frc' does not name a type
Needs a styleguide fix:
wpilibc/src/main/native/include/frc/Encoder.h:118: Add #include <memory> for shared_ptr<> [build/include_what_you_use] [4]
To fix this, add #include <memory>
to the includes at the top of Encoder.h
what's this waiting on?
Looks like there are conflicts.
The conflict is the change itself.
@Starlight220 Its a conflict in the file. There has to be no conflicts before we can merge. Likely just need to grab changes off of master.
Many of the conflicts are method prototypes that I removed as they are inherited. Those method prototypes should be removed, correct?
The conflict is because commit https://github.com/wpilibsuite/allwpilib/commit/3a5e541b2d895790ea5a9e372d277de0fbf0993e also changed Encoder.h, specifically it added a missing WPI_DEPRECATED call. Git isn't smart enough to figure out if your change should override that change, that change should override your change, or whether they both apply, which is why it marks it as a conflict that you need to resolve.
In this case, you should add that same change to your PR.
And, windows is failing again for no reason.
Linux is failing for no reason. Rerun the pipeline?
It looks like the Linux_Arm job correctly failed - the examples that use frc::Encoder need to be updated.
Looks like wpilibcExamples\src\main\cpp\examples\DMA\cpp\Robot.cpp needs updating too.
please rerun the pipeline, it lost record of the build and the DMA example was fixed in an earlier commit.
/azp run
Commenter does not have sufficient privileges for PR 2418 in repo wpilibsuite/allwpilib
Commenter does not have sufficient privileges for PR 2418 in repo wpilibsuite/allwpilib
/azp run
Azure Pipelines successfully started running 2 pipeline(s).
DMASample.h/c needs to be changed, will get to it later, might be next week.
The Shuffleboard example needs updating, will do later.
We still want this PR, but it needs rebasing.
Lots of merge conflicts, and abandoned by contributor.