Artifact artf3925 : PCM : Can't find any user facing java/C++ API for getting/clearing PCM faults

Change-Id: If5cb5b08f685158c5317233c4d9bc8e688138df7
This commit is contained in:
Omar Zrien
2014-12-26 19:40:39 -05:00
parent 3c4a1d9a1a
commit 548941dd99
20 changed files with 671 additions and 3 deletions

View File

@@ -138,6 +138,32 @@ DoubleSolenoid::Value DoubleSolenoid::Get()
if (value & m_reverseMask) return kReverse;
return kOff;
}
/**
* Check if the forward solenoid is blacklisted.
* If a solenoid is shorted, it is added to the blacklist and
* disabled until power cycle, or until faults are cleared.
* @see ClearAllPCMStickyFaults()
*
* @return If solenoid is disabled due to short.
*/
bool DoubleSolenoid::IsFwdSolenoidBlackListed()
{
int blackList = GetPCMSolenoidBlackList();
return (blackList & m_forwardMask) ? 1 : 0;
}
/**
* Check if the reverse solenoid is blacklisted.
* If a solenoid is shorted, it is added to the blacklist and
* disabled until power cycle, or until faults are cleared.
* @see ClearAllPCMStickyFaults()
*
* @return If solenoid is disabled due to short.
*/
bool DoubleSolenoid::IsRevSolenoidBlackListed()
{
int blackList = GetPCMSolenoidBlackList();
return (blackList & m_reverseMask) ? 1 : 0;
}
void DoubleSolenoid::ValueChanged(ITable* source, const std::string& key, EntryValue value, bool isNew) {
Value lvalue = kOff;