artf3622: Each Solenoid creates handles for all other Solenoids as well

Fixed so that one static handle is called for all Solenoids.

Change-Id: Ib5f3bbaa160d253e0533259bfe0e9e2a6f11733f
This commit is contained in:
jmanning
2015-06-17 14:42:09 -04:00
committed by Kevin O'Connor
parent 39130721d0
commit ead60eaab8
4 changed files with 38 additions and 37 deletions

View File

@@ -121,7 +121,7 @@ void DoubleSolenoid::Set(Value value)
break;
}
SolenoidBase::Set(rawValue, m_forwardMask | m_reverseMask);
SolenoidBase::Set(rawValue, m_forwardMask | m_reverseMask, m_moduleNumber);
}
/**
@@ -132,7 +132,7 @@ void DoubleSolenoid::Set(Value value)
DoubleSolenoid::Value DoubleSolenoid::Get()
{
if (StatusIsFatal()) return kOff;
uint8_t value = GetAll();
uint8_t value = GetAll(m_moduleNumber);
if (value & m_forwardMask) return kForward;
if (value & m_reverseMask) return kReverse;
@@ -148,7 +148,7 @@ DoubleSolenoid::Value DoubleSolenoid::Get()
*/
bool DoubleSolenoid::IsFwdSolenoidBlackListed()
{
int blackList = GetPCMSolenoidBlackList();
int blackList = GetPCMSolenoidBlackList(m_moduleNumber);
return (blackList & m_forwardMask) ? 1 : 0;
}
/**
@@ -161,7 +161,7 @@ bool DoubleSolenoid::IsFwdSolenoidBlackListed()
*/
bool DoubleSolenoid::IsRevSolenoidBlackListed()
{
int blackList = GetPCMSolenoidBlackList();
int blackList = GetPCMSolenoidBlackList(m_moduleNumber);
return (blackList & m_reverseMask) ? 1 : 0;
}