Ignore:
Timestamp:
12/14/15 15:48:32 (9 years ago)
Author:
tbretz
Message:
Another try to solve the problems with the emergency parking. Note that it is only tried if possible during sun-rise and never again.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/drivectrl.cc

    r18387 r18388  
    21742174    {
    21752175        const int rc = CheckState();
    2176         return rc>0 ? rc : T::GetCurrentState();
     2176        return rc>0 ? rc : State::kInitialized;
    21772177    }
    21782178
     
    25162516        if (now>fSunRise && T::GetCurrentState()!=State::kParking)
    25172517        {
    2518             if (T::GetCurrentState()>State::kLocked && T::GetCurrentState()!=StateMachineImp::kError)
     2518            fSunRise = now.GetNextSunRise();
     2519
     2520            ostringstream msg;
     2521            msg << "Next sun-rise will be at " << fSunRise;
     2522            T::Info(msg);
     2523
     2524            if (T::GetCurrentState()>State::kArmed && T::GetCurrentState()!=StateMachineImp::kError)
    25192525                return Park();
    2520 
    2521             if (T::GetCurrentState()==State::kLocked)
    2522             {
    2523                 fSunRise = now.GetNextSunRise();
    2524 
    2525                 ostringstream msg;
    2526                 msg << "Next sun-rise will be at " << fSunRise;
    2527                 T::Info(msg);
    2528 
    2529                 return State::kLocked;
    2530             }
    25312526        }
    25322527
Note: See TracChangeset for help on using the changeset viewer.