Skip to content

Commit

Permalink
Merge pull request #184 from robotpy/2025-dev
Browse files Browse the repository at this point in the history
Updates for 2025
  • Loading branch information
virtuald authored Nov 3, 2024
2 parents c00cf24 + 697c471 commit ee83baf
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 82 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/dist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ on:

jobs:
ci:
uses: robotpy/build-actions/.github/workflows/package-ci.yml@v2024
uses: robotpy/build-actions/.github/workflows/package-ci.yml@v2025
with:
enable_raspbian: false
enable_sphinx_check: false
artifactory_repo_type: vendor
fail_fast: false
python_versions: >-
["3.9", "3.10", "3.11", "3.12"]
["3.12", "3.13"]
secrets:
META_REPO_ACCESS_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}
RTD_TOKEN: ${{ secrets.RTD_TOKEN }}
Expand Down
33 changes: 3 additions & 30 deletions phoenix5/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
from . import _init_phoenix6
from . import _init_ctre

# autogenerated by 'robotpy-build create-imports ctre'
from .version import version as __version__

# autogenerated by 'robotpy-build create-imports phoenix5 phoenix5._ctre'
from ._ctre import (
BaseMotorController,
BaseMotorControllerConfiguration,
Expand Down Expand Up @@ -47,10 +49,8 @@
LimitSwitchRoutines,
LimitSwitchSource,
MotionProfileStatus,
MotorCommutation,
MovingAverage,
NeutralMode,
Orchestra,
ParamEnum,
RemoteFeedbackDevice,
RemoteLimitSwitchSource,
Expand All @@ -60,21 +60,11 @@
SetValueMotionProfile,
SlotConfigUtil,
SlotConfiguration,
StatorCurrentLimitConfiguration,
StatusFrame,
StatusFrameEnhanced,
StatusFrameRoutines,
StickyFaults,
SupplyCurrentLimitConfiguration,
TalonFX,
TalonFXConfigUtil,
TalonFXConfiguration,
TalonFXControlMode,
TalonFXFeedbackDevice,
TalonFXInvertType,
TalonFXPIDSetConfiguration,
TalonFXSensorCollection,
TalonFXSimCollection,
TalonSRX,
TalonSRXConfigUtil,
TalonSRXConfiguration,
Expand All @@ -93,7 +83,6 @@
VictorSPXPIDSetConfiguration,
VictorSPXSimCollection,
WPI_BaseMotorController,
WPI_TalonFX,
WPI_TalonSRX,
WPI_VictorSPX,
)
Expand Down Expand Up @@ -143,10 +132,8 @@
"LimitSwitchRoutines",
"LimitSwitchSource",
"MotionProfileStatus",
"MotorCommutation",
"MovingAverage",
"NeutralMode",
"Orchestra",
"ParamEnum",
"RemoteFeedbackDevice",
"RemoteLimitSwitchSource",
Expand All @@ -156,21 +143,11 @@
"SetValueMotionProfile",
"SlotConfigUtil",
"SlotConfiguration",
"StatorCurrentLimitConfiguration",
"StatusFrame",
"StatusFrameEnhanced",
"StatusFrameRoutines",
"StickyFaults",
"SupplyCurrentLimitConfiguration",
"TalonFX",
"TalonFXConfigUtil",
"TalonFXConfiguration",
"TalonFXControlMode",
"TalonFXFeedbackDevice",
"TalonFXInvertType",
"TalonFXPIDSetConfiguration",
"TalonFXSensorCollection",
"TalonFXSimCollection",
"TalonSRX",
"TalonSRXConfigUtil",
"TalonSRXConfiguration",
Expand All @@ -189,10 +166,6 @@
"VictorSPXPIDSetConfiguration",
"VictorSPXSimCollection",
"WPI_BaseMotorController",
"WPI_TalonFX",
"WPI_TalonSRX",
"WPI_VictorSPX",
]


from .version import version as __version__
2 changes: 0 additions & 2 deletions phoenix5/_osx_phoenix6_pkgcfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ def get_library_names():
"CTRE_SimProCANcoder",
"CTRE_SimProPigeon2",
"CTRE_SimProTalonFX",
"CTRE_SimTalonFX",
"CTRE_SimTalonSRX",
"CTRE_SimVictorSPX",
]
Expand All @@ -46,7 +45,6 @@ def get_library_full_names():
"libCTRE_SimProCANcoder.dylib",
"libCTRE_SimProPigeon2.dylib",
"libCTRE_SimProTalonFX.dylib",
"libCTRE_SimTalonFX.dylib",
"libCTRE_SimTalonSRX.dylib",
"libCTRE_SimVictorSPX.dylib",
]
14 changes: 0 additions & 14 deletions phoenix5/sensors.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# autogenerated by 'robotpy-build create-imports ctre ctre._ctre.sensors'
from ._ctre.sensors import (
AbsoluteSensorRange,
AxisDirection,
BasePigeon,
BasePigeonConfigUtils,
BasePigeonConfiguration,
Expand All @@ -14,11 +13,6 @@
CANCoderStatusFrame,
CANCoderStickyFaults,
MagnetFieldStrength,
Pigeon2,
Pigeon2ConfigUtils,
Pigeon2Configuration,
Pigeon2_Faults,
Pigeon2_StickyFaults,
PigeonIMU,
PigeonIMUConfigUtils,
PigeonIMUConfiguration,
Expand All @@ -30,13 +24,11 @@
SensorTimeBase,
SensorVelocityMeasPeriod,
WPI_CANCoder,
WPI_Pigeon2,
WPI_PigeonIMU,
)

__all__ = [
"AbsoluteSensorRange",
"AxisDirection",
"BasePigeon",
"BasePigeonConfigUtils",
"BasePigeonConfiguration",
Expand All @@ -49,11 +41,6 @@
"CANCoderStatusFrame",
"CANCoderStickyFaults",
"MagnetFieldStrength",
"Pigeon2",
"Pigeon2ConfigUtils",
"Pigeon2Configuration",
"Pigeon2_Faults",
"Pigeon2_StickyFaults",
"PigeonIMU",
"PigeonIMUConfigUtils",
"PigeonIMUConfiguration",
Expand All @@ -65,6 +52,5 @@
"SensorTimeBase",
"SensorVelocityMeasPeriod",
"WPI_CANCoder",
"WPI_Pigeon2",
"WPI_PigeonIMU",
]
48 changes: 24 additions & 24 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ author_email = "[email protected]"
url = "https://github.com/robotpy/robotpy-ctre"
license = "MIT"
install_requires = [
"wpilib<2025.0.0,>=2024.3.2",
"phoenix6~=24.2",
"wpilib~=2025.0.0b1",
"phoenix6~=25.0.0b2",
]

[build-system]
requires = [
"robotpy-build<2025.0.0,>=2024.0.0",
"wpilib<2025.0.0,>=2024.3.2",
"phoenix6~=24.2",
"robotpy-build<2025.0.0b1,~=2025.0.0a1",
"wpilib~=2025.0.0b1",
"phoenix6~=25.0.0b2",
]

[tool.robotpy-build]
Expand Down Expand Up @@ -46,7 +46,7 @@ depends = [
artifact_id = "wpiapi-cpp"
group_id = "com.ctre.phoenix"
repo_url = "https://maven.ctr-electronics.com/release"
version = "5.33.1"
version = "5.34.0-beta-2"
libs = [
"CTRE_Phoenix_WPI",
]
Expand All @@ -66,7 +66,7 @@ depends = [
artifact_id = "api-cpp"
group_id = "com.ctre.phoenix"
repo_url = "https://maven.ctr-electronics.com/release"
version = "5.33.1"
version = "5.34.0-beta-2"
libs = [
"CTRE_Phoenix",
]
Expand All @@ -85,7 +85,7 @@ depends = [
artifact_id = "cci"
group_id = "com.ctre.phoenix"
repo_url = "https://maven.ctr-electronics.com/release"
version = "5.33.1"
version = "5.34.0-beta-2"
libs = [
"CTRE_PhoenixCCI",
]
Expand All @@ -101,7 +101,7 @@ ignore = false
artifact_id = "tools"
group_id = "com.ctre.phoenix6"
repo_url = "https://maven.ctr-electronics.com/release"
version = "24.2.0"
version = "25.0.0-beta-2"
libs = []

[tool.robotpy-build.wrappers."phoenix5._wpiapi_cpp_sim"]
Expand All @@ -121,7 +121,7 @@ ignore = true
artifact_id = "wpiapi-cpp-sim"
group_id = "com.ctre.phoenix.sim"
repo_url = "https://maven.ctr-electronics.com/release"
version = "5.33.1"
version = "5.34.0-beta-2"
libs = [
"CTRE_Phoenix_WPISim",
]
Expand All @@ -140,7 +140,7 @@ ignore = true
artifact_id = "api-cpp-sim"
group_id = "com.ctre.phoenix.sim"
repo_url = "https://maven.ctr-electronics.com/release"
version = "5.33.1"
version = "5.34.0-beta-2"
libs = [
"CTRE_PhoenixSim",
]
Expand All @@ -164,7 +164,7 @@ ignore = true
artifact_id = "cci-sim"
group_id = "com.ctre.phoenix.sim"
repo_url = "https://maven.ctr-electronics.com/release"
version = "5.33.1"
version = "5.34.0-beta-2"
libs = [
"CTRE_PhoenixCCISim",
]
Expand All @@ -181,7 +181,7 @@ ignore = true
artifact_id = "tools-sim"
group_id = "com.ctre.phoenix6.sim"
repo_url = "https://maven.ctr-electronics.com/release"
version = "24.2.0"
version = "25.0.0-beta-2"
libs = []
# libs = [
# "CTRE_PhoenixTools_Sim",
Expand Down Expand Up @@ -235,13 +235,13 @@ depends = [

# ctre/phoenix/motorcontrol/can
WPI_BaseMotorController = "ctre/phoenix/motorcontrol/can/WPI_BaseMotorController.h"
WPI_TalonFX = "ctre/phoenix/motorcontrol/can/WPI_TalonFX.h"
# WPI_TalonFX = "ctre/phoenix/motorcontrol/can/WPI_TalonFX.h"
WPI_TalonSRX = "ctre/phoenix/motorcontrol/can/WPI_TalonSRX.h"
WPI_VictorSPX = "ctre/phoenix/motorcontrol/can/WPI_VictorSPX.h"

# ctre/phoenix/sensors
WPI_CANCoder = "ctre/phoenix/sensors/WPI_CANCoder.h"
WPI_Pigeon2 = "ctre/phoenix/sensors/WPI_Pigeon2.h"
# WPI_Pigeon2 = "ctre/phoenix/sensors/WPI_Pigeon2.h"
WPI_PigeonIMU = "ctre/phoenix/sensors/WPI_PigeonIMU.h"

# ctre/phoenix/tasking
Expand Down Expand Up @@ -291,20 +291,20 @@ IFollower = "ctre/phoenix/motorcontrol/IFollower.h"
IMotorController = "ctre/phoenix/motorcontrol/IMotorController.h"
IMotorControllerEnhanced = "ctre/phoenix/motorcontrol/IMotorControllerEnhanced.h"
SensorCollection = "ctre/phoenix/motorcontrol/SensorCollection.h"
TalonFXSensorCollection = "ctre/phoenix/motorcontrol/TalonFXSensorCollection.h"
TalonFXSimCollection = "ctre/phoenix/motorcontrol/TalonFXSimCollection.h"
# TalonFXSensorCollection = "ctre/phoenix/motorcontrol/TalonFXSensorCollection.h"
# TalonFXSimCollection = "ctre/phoenix/motorcontrol/TalonFXSimCollection.h"
TalonSRXSimCollection = "ctre/phoenix/motorcontrol/TalonSRXSimCollection.h"
VictorSPXSimCollection = "ctre/phoenix/motorcontrol/VictorSPXSimCollection.h"

# ctre/phoenix/motorcontrol/can
BaseMotorController = "ctre/phoenix/motorcontrol/can/BaseMotorController.h"
BaseTalon = "ctre/phoenix/motorcontrol/can/BaseTalon.h"
TalonFX = "ctre/phoenix/motorcontrol/can/TalonFX.h"
# TalonFX = "ctre/phoenix/motorcontrol/can/TalonFX.h"
TalonSRX = "ctre/phoenix/motorcontrol/can/TalonSRX.h"
VictorSPX = "ctre/phoenix/motorcontrol/can/VictorSPX.h"

# ctre/phoenix/music
Orchestra = "ctre/phoenix/music/Orchestra.h"
# Orchestra = "ctre/phoenix/music/Orchestra.h"

# ctre/phoenix/platform/can
# PlatformCAN = "ctre/phoenix/platform/can/PlatformCAN.h"
Expand All @@ -314,7 +314,7 @@ BasePigeon = "ctre/phoenix/sensors/BasePigeon.h"
BasePigeonSimCollection = "ctre/phoenix/sensors/BasePigeonSimCollection.h"
CANCoder = "ctre/phoenix/sensors/CANCoder.h"
CANCoderSimCollection = "ctre/phoenix/sensors/CANCoderSimCollection.h"
Pigeon2 = "ctre/phoenix/sensors/Pigeon2.h"
# Pigeon2 = "ctre/phoenix/sensors/Pigeon2.h"
PigeonIMU = "ctre/phoenix/sensors/PigeonIMU.h"

# ctre/phoenix/signals
Expand Down Expand Up @@ -417,11 +417,11 @@ FeedbackDevice = "ctre/phoenix/motorcontrol/FeedbackDevice.h"
FollowerType = "ctre/phoenix/motorcontrol/FollowerType.h"
InvertType = "ctre/phoenix/motorcontrol/InvertType.h"
LimitSwitchType = "ctre/phoenix/motorcontrol/LimitSwitchType.h"
MotorCommutation = "ctre/phoenix/motorcontrol/MotorCommutation.h"
# MotorCommutation = "ctre/phoenix/motorcontrol/MotorCommutation.h"
NeutralMode = "ctre/phoenix/motorcontrol/NeutralMode.h"
RemoteSensorSource = "ctre/phoenix/motorcontrol/RemoteSensorSource.h"
SensorTerm = "ctre/phoenix/motorcontrol/SensorTerm.h"
StatorCurrentLimitConfiguration = "ctre/phoenix/motorcontrol/StatorCurrentLimitConfiguration.h"
# StatorCurrentLimitConfiguration = "ctre/phoenix/motorcontrol/StatorCurrentLimitConfiguration.h"
StatusFrame = "ctre/phoenix/motorcontrol/StatusFrame.h"
StickyFaults = "ctre/phoenix/motorcontrol/StickyFaults.h"
SupplyCurrentLimitConfiguration = "ctre/phoenix/motorcontrol/SupplyCurrentLimitConfiguration.h"
Expand All @@ -445,8 +445,8 @@ CANCoderFaults = "ctre/phoenix/sensors/CANCoderFaults.h"
CANCoderStatusFrame = "ctre/phoenix/sensors/CANCoderStatusFrame.h"
CANCoderStickyFaults = "ctre/phoenix/sensors/CANCoderStickyFaults.h"
MagnetFieldStrength = "ctre/phoenix/sensors/MagnetFieldStrength.h"
Pigeon2_Faults = "ctre/phoenix/sensors/Pigeon2_Faults.h"
Pigeon2_StickyFaults = "ctre/phoenix/sensors/Pigeon2_StickyFaults.h"
# Pigeon2_Faults = "ctre/phoenix/sensors/Pigeon2_Faults.h"
# Pigeon2_StickyFaults = "ctre/phoenix/sensors/Pigeon2_StickyFaults.h"
PigeonIMU_ControlFrame = "ctre/phoenix/sensors/PigeonIMU_ControlFrame.h"
PigeonIMU_Faults = "ctre/phoenix/sensors/PigeonIMU_Faults.h"
PigeonIMU_StatusFrame = "ctre/phoenix/sensors/PigeonIMU_StatusFrame.h"
Expand Down
12 changes: 2 additions & 10 deletions tests/test_ctre.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,6 @@ def test_wpi_talonsrx():
del m


def test_wpi_talonfx():
m = phoenix5.WPI_TalonFX(1)
m.setNeutralMode(phoenix5.NeutralMode.Brake)
m.set(0.5)
assert m.get() == 0.5
del m


def test_wpi_victorspx():
m = phoenix5.WPI_VictorSPX(2)
m.setNeutralMode(phoenix5.NeutralMode.Brake)
Expand All @@ -26,8 +18,8 @@ def test_wpi_victorspx():


def test_follow():
m1 = phoenix5.WPI_TalonFX(3)
m2 = phoenix5.WPI_TalonFX(4)
m1 = phoenix5.WPI_TalonSRX(3)
m2 = phoenix5.WPI_VictorSPX(4)
m2.follow(m1)
m1.set(0.5)
assert m1.get() == 0.5

0 comments on commit ee83baf

Please sign in to comment.