00001 /* 00002 * Header file for automobile_network, 2010 Princeton Satellite Systems. 00003 */ 00004 00005 #include <DSimEngine2/dsim_model.h> 00006 00007 #ifndef AUTOMOBILE_NETWORK 00008 #define AUTOMOBILE_NETWORK 00009 00010 00012 00023 class automobile_network : public dsim_model 00024 { 00025 public: 00027 automobile_network(dsim_model_setup *setup); 00029 void initialization_complete(); 00031 void initialize_data(); 00033 void initialize_timestep(); 00035 void pre_calculate(); 00037 void post_calculate(); 00039 dsim_value handle_message(const std::string &sender_path,const std::string &message_name,const dsim_value &argument); 00040 00041 00042 protected: 00044 dsim_variable parent_yaw_matrix_dsim; 00046 dsim_variable parent_position_dsim; 00048 dsim_variable transmit_dsim; 00050 dsim_variable message_outgoing_dsim; 00052 dsim_variable message_incoming_dsim; 00054 dsim_variable position_dsim; 00055 00056 00057 00058 // Position 00059 ml_matrix r; 00060 // Velocity 00061 ml_matrix v; 00062 00063 // Incoming message 00064 ml_matrix message_incoming; 00065 }; 00066 00067 #endif