updating code from Flying Laptop
This is the framework of Flying Laptop OBSW version A.13.0.
This commit is contained in:
@ -1,35 +1,58 @@
|
||||
/*
|
||||
* DataPoolAdmin.h
|
||||
*
|
||||
* Created on: 05.12.2013
|
||||
* Author: baetz
|
||||
*/
|
||||
|
||||
#ifndef DATAPOOLADMIN_H_
|
||||
#define DATAPOOLADMIN_H_
|
||||
|
||||
#include <framework/ipc/MessageQueue.h>
|
||||
#include <framework/memory/MemoryHelper.h>
|
||||
#include <framework/action/HasActionsIF.h>
|
||||
#include <framework/action/SimpleActionHelper.h>
|
||||
#include <framework/objectmanager/SystemObject.h>
|
||||
#include <framework/returnvalues/HasReturnvaluesIF.h>
|
||||
#include <framework/tasks/ExecutableObjectIF.h>
|
||||
#include <framework/parameters/ReceivesParameterMessagesIF.h>
|
||||
#include <framework/datapool/DataPoolParameterWrapper.h>
|
||||
#include <framework/ipc/MessageQueueIF.h>
|
||||
|
||||
class DataPoolAdmin : public ExecutableObjectIF, public AcceptsMemoryMessagesIF, public HasReturnvaluesIF, public SystemObject {
|
||||
private:
|
||||
MessageQueue commandQueue;
|
||||
MemoryHelper memoryHelper;
|
||||
void handleCommand();
|
||||
class DataPoolAdmin: public HasActionsIF,
|
||||
public ExecutableObjectIF,
|
||||
public AcceptsMemoryMessagesIF,
|
||||
public HasReturnvaluesIF,
|
||||
public ReceivesParameterMessagesIF,
|
||||
public SystemObject {
|
||||
public:
|
||||
static const ActionId_t SET_VALIDITY = 1;
|
||||
|
||||
DataPoolAdmin(object_id_t objectId);
|
||||
|
||||
ReturnValue_t performOperation();
|
||||
~DataPoolAdmin();
|
||||
|
||||
ReturnValue_t performOperation(uint8_t opCode);
|
||||
|
||||
MessageQueueId_t getCommandQueue() const;
|
||||
|
||||
ReturnValue_t handleMemoryLoad(uint32_t address, const uint8_t* data, uint32_t size, uint8_t** dataPointer);
|
||||
ReturnValue_t handleMemoryDump(uint32_t address, uint32_t size, uint8_t** dataPointer, uint8_t* copyHere );
|
||||
ReturnValue_t handleMemoryLoad(uint32_t address, const uint8_t* data,
|
||||
uint32_t size, uint8_t** dataPointer);
|
||||
ReturnValue_t handleMemoryDump(uint32_t address, uint32_t size,
|
||||
uint8_t** dataPointer, uint8_t* copyHere);
|
||||
|
||||
ReturnValue_t executeAction(ActionId_t actionId,
|
||||
MessageQueueId_t commandedBy, const uint8_t* data, uint32_t size);
|
||||
|
||||
//not implemented as ParameterHelper is no used
|
||||
ReturnValue_t getParameter(uint8_t domainId, uint16_t parameterId,
|
||||
ParameterWrapper *parameterWrapper,
|
||||
const ParameterWrapper *newValues, uint16_t startAtIndex);
|
||||
|
||||
ReturnValue_t initialize();
|
||||
private:
|
||||
StorageManagerIF *storage;
|
||||
MessageQueueIF* commandQueue;
|
||||
MemoryHelper memoryHelper;
|
||||
SimpleActionHelper actionHelper;
|
||||
void handleCommand();
|
||||
ReturnValue_t handleParameterCommand(CommandMessage *command);
|
||||
ReturnValue_t sendParameter(MessageQueueId_t to, uint32_t id,
|
||||
const DataPoolParameterWrapper* wrapper);
|
||||
void rejectCommand(MessageQueueId_t to, ReturnValue_t reason,
|
||||
Command_t initialCommand);
|
||||
};
|
||||
|
||||
|
||||
#endif /* DATAPOOLADMIN_H_ */
|
||||
|
Reference in New Issue
Block a user