public abstract class SolenoidBase
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
SolenoidBase.SolenoidChannel
The Enum Channel.
|
static class |
SolenoidBase.Value
The Enum Value.
|
| Modifier and Type | Field and Description |
|---|---|
private static java.nio.ByteBuffer[] |
MODULE_PORTS
Ports for blacklist checking
|
protected static byte |
SOLENOID_OFF
The Constant kSolenoidOff.
|
protected static byte |
SOLENOID_ON
The Constant kSolenoidOn.
|
private static boolean[] |
USED_CHANNELS
Keep track of already used channels.
|
| Constructor and Description |
|---|
SolenoidBase() |
| Modifier and Type | Method and Description |
|---|---|
private static void |
allocateChannel(SolenoidBase.SolenoidChannel channel)
Allocate a Solenoid channel.
|
void |
clearAllPCMStickyFaults(int module)
Clear ALL sticky faults inside PCM that Compressor is wired to.
|
protected static void |
freeChannel(SolenoidBase.SolenoidChannel channel)
Free channel.
|
abstract SolenoidBase.Value |
get() |
protected static boolean |
get(java.nio.ByteBuffer port) |
byte |
getPCMSolenoidBlacklist(int module)
Reads complete solenoid blacklist for all 8 solenoids as a single byte.
|
boolean |
getPCMSolenoidVoltageFault(int module) |
boolean |
getPCMSolenoidVoltageStickyFault(int module) |
protected static java.nio.ByteBuffer |
initChannel(SolenoidBase.SolenoidChannel channel)
Inits the module.
|
protected static void |
set(java.nio.ByteBuffer port,
byte value)
Sets the.
|
abstract void |
set(SolenoidBase.Value value)
Sets the.
|
private static void |
unallocateChannel(SolenoidBase.SolenoidChannel channel)
Free a Solenoid channel.
|
private static final boolean[] USED_CHANNELS
private static final java.nio.ByteBuffer[] MODULE_PORTS
protected static final byte SOLENOID_OFF
protected static final byte SOLENOID_ON
protected static final java.nio.ByteBuffer initChannel(SolenoidBase.SolenoidChannel channel)
channel - the channelprotected static final void freeChannel(SolenoidBase.SolenoidChannel channel)
channel - the channelprivate static final void allocateChannel(SolenoidBase.SolenoidChannel channel)
channel - the Solenoid channel to allocateprivate static final void unallocateChannel(SolenoidBase.SolenoidChannel channel)
channel - the Solenoid channel to freepublic final byte getPCMSolenoidBlacklist(int module)
module - clearAllPCMStickyFaults(int)public final boolean getPCMSolenoidVoltageStickyFault(int module)
module - public final boolean getPCMSolenoidVoltageFault(int module)
module - public final void clearAllPCMStickyFaults(int module)
module - protected static final void set(java.nio.ByteBuffer port,
byte value)
port - the portvalue - the valueprotected static final boolean get(java.nio.ByteBuffer port)
port - public abstract void set(SolenoidBase.Value value)
value - the valuepublic abstract SolenoidBase.Value get()