CTRE Phoenix C++
5.33.1
PlatformCAN.h
Go to the documentation of this file.
1
/* Copyright (C) Cross The Road Electronics 2024 */
2
#include "
ctre/phoenix/cci/PlatformCAN_CCI.h
"
3
4
namespace
ctre
{
5
namespace
phoenix {
6
/** platform namespace */
7
namespace
platform {
8
/** platform-can namespace */
9
namespace
can {
10
11
/**
12
* Configures the can interface for API
13
*/
14
class
PlatformCAN
{
15
public
:
16
/**
17
* Set CAN interface
18
* @param canInterface Can interface to set. Linux example: "can0".
19
* @return ErrorCode generated by function
20
* @deprecated pass the CAN interface to device constructors instead,
21
* or call RegisterCANbus
22
*/
23
static
int32_t
SetCANInterface
(
const
char
* canInterface);
24
25
/**
26
* Registers a non-compliant CANbus
27
* @param canbus CANbus to register. Linux example: "can0".
28
* @return ErrorCode generated by function
29
*/
30
static
int32_t
RegisterCANbus
(
char
const
*canbus);
31
32
/**
33
* Starts all items in interface
34
*/
35
static
int32_t
StartAll
();
36
37
/**
38
* Destroys all items in interface
39
*/
40
static
int32_t
DestroyAll
();
41
42
/**
43
* Set Autocache state
44
* @param state state of autocache
45
*/
46
static
void
SetAutocacheLevel
(
ctre::phoenix::AutocacheState
state);
47
};
48
49
}
50
}
51
}
52
}
PlatformCAN_CCI.h
ctre::phoenix::platform::can::PlatformCAN
Configures the can interface for API.
Definition:
PlatformCAN.h:14
ctre::phoenix::platform::can::PlatformCAN::DestroyAll
static int32_t DestroyAll()
Destroys all items in interface.
ctre::phoenix::platform::can::PlatformCAN::SetAutocacheLevel
static void SetAutocacheLevel(ctre::phoenix::AutocacheState state)
Set Autocache state.
ctre::phoenix::platform::can::PlatformCAN::RegisterCANbus
static int32_t RegisterCANbus(char const *canbus)
Registers a non-compliant CANbus.
ctre::phoenix::platform::can::PlatformCAN::SetCANInterface
static int32_t SetCANInterface(const char *canInterface)
Set CAN interface.
ctre::phoenix::platform::can::PlatformCAN::StartAll
static int32_t StartAll()
Starts all items in interface.
ctre::phoenix::AutocacheState
AutocacheState
Keeps track of cache state.
Definition:
autocache.h:9
ctre
namespace ctre
Definition:
paramEnum.h:5
ctre
phoenix
platform
can
PlatformCAN.h
Generated on Fri Feb 16 2024 22:57:38 for CTRE Phoenix C++ by
1.9.4