Refactored Insight GUI to accommodate the many changes made to Bloom's internals
Also lots of tidying.
This commit is contained in:
25
src/Insight/InsightWorker/Tasks/SetTargetGpioPadState.cpp
Normal file
25
src/Insight/InsightWorker/Tasks/SetTargetGpioPadState.cpp
Normal file
@@ -0,0 +1,25 @@
|
||||
#include "SetTargetGpioPadState.hpp"
|
||||
|
||||
using Services::TargetControllerService;
|
||||
|
||||
SetTargetGpioPadState::SetTargetGpioPadState(
|
||||
const Targets::TargetPadDescriptor& padDescriptor,
|
||||
const Targets::TargetGpioPadState& state
|
||||
)
|
||||
: padDescriptor(padDescriptor)
|
||||
, state(state)
|
||||
{}
|
||||
|
||||
QString SetTargetGpioPadState::brief() const {
|
||||
return "Updating target pin state";
|
||||
}
|
||||
|
||||
TaskGroups SetTargetGpioPadState::taskGroups() const {
|
||||
return {
|
||||
TaskGroup::USES_TARGET_CONTROLLER,
|
||||
};
|
||||
}
|
||||
|
||||
void SetTargetGpioPadState::run(TargetControllerService& targetControllerService) {
|
||||
targetControllerService.setGpioPadState(this->padDescriptor, this->state);
|
||||
}
|
||||
Reference in New Issue
Block a user