Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wpimath: Add Rotation2d.fromRotations #68

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions subprojects/pyntcore/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ base_package = "ntcore"
[tool.robotpy-build.wrappers."ntcore".maven_lib_download]
artifact_id = "ntcore-cpp"
group_id = "edu.wpi.first.ntcore"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["ntcore"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-apriltag/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ base_package = "robotpy_apriltag"
[tool.robotpy-build.wrappers."robotpy_apriltag".maven_lib_download]
artifact_id = "apriltag-cpp"
group_id = "edu.wpi.first.apriltag"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["apriltag"]

Expand Down
8 changes: 4 additions & 4 deletions subprojects/robotpy-cscore/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,16 @@ base_package = "cscore"
[tool.robotpy-build.static_libs."cscore_cpp".maven_lib_download]
artifact_id = "cscore-cpp"
group_id = "edu.wpi.first.cscore"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["cscore"]

[tool.robotpy-build.static_libs."cameraserver_cpp".maven_lib_download]
artifact_id = "cameraserver-cpp"
group_id = "edu.wpi.first.cameraserver"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["cameraserver"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-hal/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ base_package = "hal"
artifact_id = "hal-cpp"
group_id = "edu.wpi.first.hal"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["wpiHal"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-halsim-ds-socket/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ base_package = "halsim_ds_socket"
artifact_id = "halsim_ds_socket"
group_id = "edu.wpi.first.halsim"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

dlopenlibs = ["halsim_ds_socket"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-halsim-gui/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ base_package = "halsim_gui"
artifact_id = "halsim_gui"
group_id = "edu.wpi.first.halsim"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

dlopenlibs = ["halsim_gui"]

Expand Down
8 changes: 4 additions & 4 deletions subprojects/robotpy-halsim-ws/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ base_package = "halsim_ws"
artifact_id = "halsim_ws_server"
group_id = "edu.wpi.first.halsim"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

dlopenlibs = ["halsim_ws_server"]

Expand All @@ -44,8 +44,8 @@ depends = ["wpiHal", "wpinet"]
artifact_id = "halsim_ws_client"
group_id = "edu.wpi.first.halsim"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

dlopenlibs = ["halsim_ws_client"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-romi/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,6 @@ RomiMotor = "frc/romi/RomiMotor.h"
artifact_id = "romiVendordep-cpp"
group_id = "edu.wpi.first.romiVendordep"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"
libs = ["romiVendordep"]
4 changes: 2 additions & 2 deletions subprojects/robotpy-wpilib/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ base_package = "wpilib"
[tool.robotpy-build.wrappers."wpilib._impl".maven_lib_download]
artifact_id = "wpilibc-cpp"
group_id = "edu.wpi.first.wpilibc"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["wpilibc"]

Expand Down
18 changes: 14 additions & 4 deletions subprojects/robotpy-wpimath/gen/geometry/Rotation2d.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,16 @@ classes:
Rotation2d:
overloads:
'[constexpr]':
units::radian_t [constexpr]:
units::degree_t [constexpr]:
ignore: true
auto [constexpr]:
doc: |
Constructs a Rotation2d with the given radian value.

:param value: The value of the angle in radians.
param_override:
value:
x_type: 'units::radian_t'
template_impls:
- ['units::radian_t']
double, double [constexpr]:
RotateBy:
Radians:
Expand All @@ -40,8 +47,11 @@ classes:
inline_code: |
cls_Rotation2d
.def_static("fromDegrees", [](units::degree_t value) {
return std::make_unique<Rotation2d>(value);
return Rotation2d(value);
}, py::arg("value"))
.def_static("fromRotations", [](units::turn_t value) {
return Rotation2d(value);
})
.def("__repr__", py::overload_cast<const Rotation2d&>(&rpy::toString));

SetupWPyStruct<frc::Rotation2d>(cls_Rotation2d);
4 changes: 2 additions & 2 deletions subprojects/robotpy-wpimath/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ base_package = "wpimath"
[tool.robotpy-build.wrappers."wpimath._impl".maven_lib_download]
artifact_id = "wpimath-cpp"
group_id = "edu.wpi.first.wpimath"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"


libs = ["wpimath"]
Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-wpinet/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ generation_data = "gen"
artifact_id = "wpinet-cpp"
group_id = "edu.wpi.first.wpinet"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"

libs = ["wpinet"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-wpiutil/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ generation_data = "gen"
[tool.robotpy-build.wrappers."wpiutil".maven_lib_download]
artifact_id = "wpiutil-cpp"
group_id = "edu.wpi.first.wpiutil"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
# repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1"
version = "2024.2.1-10-g84ef71a"

libs = ["wpiutil"]

Expand Down
4 changes: 2 additions & 2 deletions subprojects/robotpy-xrp/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,6 @@ XRPServo = "frc/xrp/XRPServo.h"
artifact_id = "xrpVendordep-cpp"
group_id = "edu.wpi.first.xrpVendordep"
# repo_url = "https://frcmaven.wpi.edu/artifactory/release"
repo_url = "https://frcmaven.wpi.edu/artifactory/release"
version = "2024.2.1"
repo_url = "https://frcmaven.wpi.edu/artifactory/development"
version = "2024.2.1-10-g84ef71a"
libs = ["xrpVendordep"]
Loading