Spacecraft Control Bundle 1
cs_timer.h
1/*
2 * Header file for object of class cs_timer.
3 * Copyright 2008, Princeton Satellite Systems, Inc.
4 * All Rights Reserved.
5 */
6
7#include <ControlDeck2/ControlDeck2.h>
8#include "sc_events.h"
9
10#ifndef CS_TIMER
11#define CS_TIMER
12
15class cs_timer : public cd_control_module
16{
17 public:
18 cs_timer (const char * mod_name);
19 void initialize_data();
21 void initialize();
22 void handle_event(int code);
23
24 protected:
25 double control_time_last;
26 double perctol;
27
31 double get_met();
32
33 private:
35 double jD0;
37 double met_last;
38
39};
40
41extern "C"
42{
43 cd_control_module *cs_timer_builder(const char *name);
44}
45
46#endif
This times and sends triggers to all modules.
Definition: cs_timer.h:16
CD_REQUEST_REF acs_control_period_command_ref
ACS control period - Command format: double.
Definition: cs_timer.h:29
void handle_event(int code)
Trigger the sequence of events.
Definition: cs_timer.cc:55
void initialize()
Initialize. Set the time variables to zero.
Definition: cs_timer.cc:28
double get_met()
Get the mission elapsed time.
Definition: cs_timer.cc:100
void initialize_data_requests()
Request the acs_control_period_command which will be used to kick off the event sequence.
Definition: cs_timer.cc:22
void initialize_data()
Request notification of CD_SIMULATION_STEP_EVENT.
Definition: cs_timer.cc:16
Define the trigger and variables names for the software system.