CANifier
User’s
Guide www.ctr-electronics.com 10/8/2017
Cross The Road Electronics Page 17 10/8/2017
3. Phoenix Framework (Software)
Phoenix Framework is the CTRE Software API for CTRE CAN devices, including CANifier. The current version is in Alpha
development and can be found at the CTRE site.
http://www.ctr-electronics.com/control-system/hro.html#product_tabs_technical_resources
Support will include the following platforms…
-
HERO Development board
–
C#
-
Java FRC roboRIO
-
C++ FRC roboRIO
-
LabVIEW FRC roboRIO
3.1. Software Examples
CANifier examples can be found in the following GitHub repositories (or find on the CTRE CANifier product’s page).
HERO and FRC programming languages…
https://github.com/CrossTheRoadElec/Phoenix-Examples-Languages
FRC LabVIEW…
https://github.com/CrossTheRoadElec/Phoenix-Examples-LabVIEW
3.2. Status Frame Rates
After CANifier boots application firmware, it transmits
the following signals at their respective rates…
Default Signal CAN Bus Frame Rates
Status Frame
Default Period (ms)
Signals
Status 1
100
LED Duty Cycles, Battery Voltage, Faults
Status 2
10
Quadrature, Digital Inputs
Status 3
100
PWM Channel 0 measurement
Status 4
100
PWM Channel 1 measurement
Status 5
100
PWM Channel 2 measurement
Status 6
100
PWM Channel 3 measurement
These frame rates can be adjusted with the software API in the Phoenix Framework.
Example code snippet below…
3.3. Custom Platforms
Portions of the Phoenix Framework are open source, to allow developers to port the CAN communication to a custom protocol.
Check the Phoenix repositories on CTRE’s GitHub for more in
formation.