- The
ClockGeneratorgenerates clock for classes which inheritITickable. - It is mainly used to manage update the component states since the
Componentclass inheritsITickable - This class is not managed by
GlobalEnvironmentclass. TheSpacecraftclass directly has the instance of this class and execute the update function.
src/environment/global/clock_generator.cpp, .hppsrc/components/base/interface_tickable.hpp
- Make an instance of a class which inherit
ITickable. Then, the instance is automatically registered to the component listClockGenerator::components_. - The
Spacecraftclass calls theUpdateComponentsfunction to update the states of the registered components.
- Call
TickToComponentswhen the component update timing flag istrue.
- Increment count and execute the
ITickable::TickorITickable::FastTickfunction. - They call the
component::MainRoutineandcomponent::FastUpdatefunctions, respectively.
- NA
- NA