![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
commit
Dependencies: MPU6050_SIM5320_TEST
Fork of MPU_SDCARD by
MotionFSM/Fsm.cpp
- Committer:
- suads
- Date:
- 2017-11-10
- Revision:
- 1:75966605a6a3
File content as of revision 1:75966605a6a3:
#include <Moving.h> #include <Stacionary.h> #include <Fsm.h> FsmStates::FsmStates() : movingState_(new Moving(*this,timer)), stacionaryState_(new Stacionary(*this,timer)) { currentState(stacionaryState()); } State* FsmStates::stacionaryState() { return stacionaryState_; } State* FsmStates::movingState() { return movingState_; } State* FsmStates::currentState() { return currentState_; } void FsmStates::currentState(State* state) { currentState_ = state; } FsmStates::~FsmStates() { delete stacionaryState_; delete movingState_; } Fsm::Fsm() : states_() { }