WIP: somethings wrong.. #19
@ -1,5 +1,6 @@
|
|||||||
#include <framework/devicehandlers/FixedSlotSequence.h>
|
#include <framework/devicehandlers/FixedSlotSequence.h>
|
||||||
#include <framework/serviceinterface/ServiceInterfaceStream.h>
|
#include <framework/serviceinterface/ServiceInterfaceStream.h>
|
||||||
|
#include <cstdlib>
|
||||||
|
|
||||||
FixedSlotSequence::FixedSlotSequence(uint32_t setLengthMs) :
|
FixedSlotSequence::FixedSlotSequence(uint32_t setLengthMs) :
|
||||||
slotLengthMs(setLengthMs) {
|
slotLengthMs(setLengthMs) {
|
||||||
@ -87,7 +88,15 @@ uint32_t FixedSlotSequence::getLengthMs() const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ReturnValue_t FixedSlotSequence::checkSequence() const {
|
ReturnValue_t FixedSlotSequence::checkSequence() const {
|
||||||
// Iterate through slotList and check successful creation.
|
if(slotList.empty()) {
|
||||||
|
error << "Fixed Slot Sequence: Slot list is empty!" << std::endl;
|
||||||
|
// does check sequence have to be const?
|
||||||
|
// if I want to check a class, I need the ability to set
|
||||||
|
// internal class states.
|
||||||
|
//isEmpty = true;
|
||||||
|
std::exit(0);
|
||||||
|
}
|
||||||
|
// Iterate through slotList and check successful creation.
|
||||||
// Checks if timing is ok (must be ascending) and if all handlers were found.
|
// Checks if timing is ok (must be ascending) and if all handlers were found.
|
||||||
auto slotIt = slotList.begin();
|
auto slotIt = slotList.begin();
|
||||||
uint32_t count = 0;
|
uint32_t count = 0;
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
#include <framework/devicehandlers/FixedSequenceSlot.h>
|
#include <framework/devicehandlers/FixedSequenceSlot.h>
|
||||||
#include <framework/objectmanager/SystemObject.h>
|
#include <framework/objectmanager/SystemObject.h>
|
||||||
|
#include <framework/returnvalues/HasReturnvaluesIF.h>
|
||||||
#include <list>
|
#include <list>
|
||||||
#include <set>
|
#include <set>
|
||||||
|
|
||||||
@ -23,7 +24,6 @@ using SlotListIter = std::multiset<FixedSequenceSlot>::iterator;
|
|||||||
class FixedSlotSequence {
|
class FixedSlotSequence {
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief The constructor of the FixedSlotSequence object.
|
* @brief The constructor of the FixedSlotSequence object.
|
||||||
*
|
*
|
||||||
@ -127,6 +127,8 @@ protected:
|
|||||||
SlotList slotList;
|
SlotList slotList;
|
||||||
|
|
||||||
uint32_t slotLengthMs;
|
uint32_t slotLengthMs;
|
||||||
|
|
||||||
|
bool isEmpty = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* FIXEDSLOTSEQUENCE_H_ */
|
#endif /* FIXEDSLOTSEQUENCE_H_ */
|
||||||
|
@ -112,7 +112,6 @@ void FixedTimeslotTask::taskFunctionality() {
|
|||||||
vTaskDelayUntil(&xLastWakeTime, interval);
|
vTaskDelayUntil(&xLastWakeTime, interval);
|
||||||
//TODO deadline missed check
|
//TODO deadline missed check
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user