changes for FSFW power refactoring
This commit is contained in:
@ -205,7 +205,7 @@ void PCDUHandler::updatePdu1SwitchStates() {
|
||||
|
||||
LocalDataPoolManager* PCDUHandler::getHkManagerHandle() { return &poolManager; }
|
||||
|
||||
void PCDUHandler::sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) const {
|
||||
ReturnValue_t PCDUHandler::sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) {
|
||||
using namespace pcduSwitches;
|
||||
ReturnValue_t result;
|
||||
uint16_t memoryAddress = 0;
|
||||
@ -261,7 +261,7 @@ void PCDUHandler::sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) const
|
||||
}
|
||||
// This is a dangerous command. Reject/Igore it for now
|
||||
case pcduSwitches::PDU2_CH0_Q7S: {
|
||||
return;
|
||||
return RETURN_FAILED;
|
||||
// memoryAddress = PDU2::CONFIG_ADDRESS_OUT_EN_Q7S;
|
||||
// pdu = ObjectManager::instance()->get<GomspaceDeviceHandler>(objects::PDU2_HANDLER);
|
||||
// break;
|
||||
@ -309,7 +309,7 @@ void PCDUHandler::sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) const
|
||||
|
||||
default: {
|
||||
sif::error << "PCDUHandler::sendSwitchCommand: Invalid switch number " << std::endl;
|
||||
return;
|
||||
return RETURN_FAILED;
|
||||
}
|
||||
}
|
||||
|
||||
@ -322,7 +322,7 @@ void PCDUHandler::sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) const
|
||||
break;
|
||||
default:
|
||||
sif::error << "PCDUHandler::sendSwitchCommand: Invalid state commanded" << std::endl;
|
||||
return;
|
||||
return RETURN_FAILED;
|
||||
}
|
||||
|
||||
GomspaceSetParamMessage setParamMessage(memoryAddress, ¶meterValue, parameterValueSize);
|
||||
@ -347,9 +347,12 @@ void PCDUHandler::sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) const
|
||||
// Can't use trigger event because of const function constraint, but this hack seems to work
|
||||
this->forwardEvent(power::SWITCH_CMD_SENT, parameterValue, switchNr);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
void PCDUHandler::sendFuseOnCommand(uint8_t fuseNr) const {}
|
||||
ReturnValue_t PCDUHandler::sendFuseOnCommand(uint8_t fuseNr) {
|
||||
return RETURN_OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PCDUHandler::getSwitchState(uint8_t switchNr) const {
|
||||
if (switchNr >= pcduSwitches::NUMBER_OF_SWITCHES) {
|
||||
|
Reference in New Issue
Block a user