started gyro handler, renamed
This commit is contained in:
66
mission/devices/GyroL3GD20Handler.cpp
Normal file
66
mission/devices/GyroL3GD20Handler.cpp
Normal file
@ -0,0 +1,66 @@
|
||||
#include <mission/devices/GyroL3GD20Handler.h>
|
||||
|
||||
GyroHandler::GyroHandler(object_id_t objectId, object_id_t deviceCommunication,
|
||||
CookieIF *comCookie):
|
||||
DeviceHandlerBase(objectId, deviceCommunication, comCookie) {
|
||||
}
|
||||
|
||||
GyroHandler::~GyroHandler() {}
|
||||
|
||||
void GyroHandler::doStartUp() {
|
||||
if(internalState == InternalState::STATE_NONE) {
|
||||
internalState = InternalState::STATE_CONFIGURE;
|
||||
}
|
||||
|
||||
if(internalState == InternalState::STATE_CONFIGURE) {
|
||||
if(commandExecuted) {
|
||||
internalState = InternalState::STATE_NORMAL;
|
||||
commandExecuted = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void GyroHandler::doShutDown() {
|
||||
setMode(_MODE_POWER_DOWN);
|
||||
}
|
||||
|
||||
ReturnValue_t GyroHandler::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
return HasReturnvaluesIF::RETURN_OK;
|
||||
}
|
||||
|
||||
ReturnValue_t GyroHandler::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return HasReturnvaluesIF::RETURN_OK;
|
||||
}
|
||||
|
||||
ReturnValue_t GyroHandler::buildCommandFromCommand(
|
||||
DeviceCommandId_t deviceCommand, const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return HasReturnvaluesIF::RETURN_OK;
|
||||
}
|
||||
|
||||
ReturnValue_t GyroHandler::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return HasReturnvaluesIF::RETURN_OK;
|
||||
}
|
||||
|
||||
ReturnValue_t GyroHandler::interpretDeviceReply(DeviceCommandId_t id,
|
||||
const uint8_t *packet) {
|
||||
return HasReturnvaluesIF::RETURN_OK;
|
||||
}
|
||||
|
||||
uint32_t GyroHandler::getTransitionDelayMs(Mode_t from, Mode_t to) {
|
||||
return 5000;
|
||||
}
|
||||
|
||||
ReturnValue_t GyroHandler::initializeLocalDataPool(
|
||||
LocalDataPool &localDataPoolMap, LocalDataPoolManager &poolManager) {
|
||||
return HasReturnvaluesIF::RETURN_OK;
|
||||
}
|
||||
|
||||
void GyroHandler::fillCommandAndReplyMap() {
|
||||
|
||||
}
|
||||
|
||||
void GyroHandler::modeChanged() {
|
||||
|
||||
}
|
Reference in New Issue
Block a user