Changeset 518 for vtcross/trunk/src/include/vtcross/cross_shell.h
- Timestamp:
- 11/13/09 15:37:02 (14 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
vtcross/trunk/src/include/vtcross/cross_shell.h
r465 r518 15 15 */ 16 16 17 /* This header exports the declaration for the VTCROSS Shell component, which is18 * a critical part of every VTCROSS system.17 /*! This header exports the declaration for the CROSS Shell component, which is 18 * a critical part of every CROSS system. 19 19 */ 20 20 … … 26 26 27 27 28 /* Cognitive Radio Shell class declaration. 28 /*! \brief Cognitive Radio Shell class declaration. 29 * 30 * The CROSS Cognitive Radio Shell (CRS) is the central control component of 31 * most CROSS radios. It is a requirement for any CROSS radio, regardless of 32 * the presence or lack thereof of the SML. 29 33 */ 30 34 class CognitiveRadioShell 31 35 { 32 36 public: 37 /*! \brief Default CRS costructor. */ 33 38 CognitiveRadioShell(); 39 40 /*! \brief Default CRS destructor. */ 34 41 ~CognitiveRadioShell(); 35 42 36 /* Overloaded constructor that creates a CR Shell object and loads the 43 /*! \brief Preferred CRS constructor. 44 * 45 * Overloaded constructor that creates a CR Shell object and loads the 37 46 * passed radio configuration XML file. 38 47 */ … … 40 49 int16_t policyPort, int16_t commandPort); 41 50 42 /* Ask for the component type of a remote component via sockets, or 43 * respond to such a query sent to the shell itself. 44 */ 51 /*! \brief Request the component type of a remote component. */ 45 52 std::string GetRemoteComponentType(int32_t socketFD); 53 54 /*! \brief Respond to a request to identify component type. */ 46 55 void SendComponentType(int32_t socketFD); 47 56 57 /*! \brief Shutdown the CRS. 58 * 59 * Since the CRS is the central control component of the CROSS radio, 60 * shutting down the CRS will shutdown the entire radio. 61 */ 48 62 void Shutdown(); 63 64 /*! \brief Restart the CRS. 65 * 66 * Restart the CRS component - reloads configuration files, and 67 * re-initializes the CRS component. 68 */ 49 69 void Reset(); 50 70 51 /* Start all the socket servers */ 71 /*! \brief Start the CRS's socket server. 72 * 73 * This function will make the CRS create a socket server and begin 74 * listening for incoming connections from other components. 75 */ 52 76 void StartShellServer(); 53 77 78 /*! \brief Load the radio configuration. 79 * 80 * This function reads in the radio's XML configuration file, which is 81 * typically located on the same system as the CRS, although it can also 82 * be passed to the CRS from the radio host platform if necessary. 83 */ 54 84 int32_t LoadRadioConfiguration(const char* radioConfig, Parameter* &pList, \ 55 85 Utility* &uList, Observable* &oList, Radio_Info* radioInfo); 56 86 private: 57 /* Parse and load/reload policies into the policy engine. 58 */ 59 void LoadPolicies(); 60 void ReloadPolicies(); 61 62 /* Register and Deregister the different components. 87 /*! \brief Handle component registration activities. 88 * 89 * Register and Deregister the different components. 90 * TODO Are multiple functions really necessary? They are all basically 91 * doing the same thing... 63 92 */ 64 93 void RegisterCognitiveEngine(int32_t socketFD); … … 69 98 void DeregisterSML(int32_t socketFD); 70 99 100 /*! \brief Set the active mission. 101 * 102 * This function handles a request by the radio host platform to set or 103 * change the current active mission in the service management layer. 104 * This command is basically passed through the CRS to the SML. 105 */ 71 106 void SetActiveMission(int32_t socketFD); 72 107 … … 75 110 int32_t HandleMessage(int32_t socketFD); 76 111 77 /* Send optimization request to primary port FD. 112 /*! \brief Send optimization request to CE. 113 * 114 * The host application requested that parameters be optimized - pass 115 * the parameters and command to the CE. 116 * 117 * TODO How is the CE being selected if multiple CEs are available? 78 118 */ 79 119 void GetOptimalParameters(int32_t socketFD); 80 120 81 /* TODO121 /*! TODO 82 122 */ 83 123 bool SendRadioConfiguration(int32_t socketFD); 84 124 bool SendRadioExperience(int32_t socketFD); 85 125 86 /* TODO126 /*! TODO 87 127 */ 88 128 bool UpdateParameterPerformance(int32_t socketFD); 89 129 90 /* TODO130 /*! TODO 91 131 */ 92 132 bool SML_present; … … 94 134 bool CE_present; 95 135 96 /* TODO136 /*! TODO 97 137 */ 98 138 int32_t numberOfCognitiveEngines; 99 139 100 /* TODO140 /*! TODO 101 141 */ 102 142 int16_t primaryPort; … … 104 144 int16_t commandPort; 105 145 106 /* TODO 146 /*! TODO 147 * 148 * I'm confused as to what exactly these are for... there can be 149 * multiple CEs and PEs, and the CRS _IS_ the command component. 150 * --BCH 107 151 */ 108 152 int32_t ceSocketFD; … … 110 154 int32_t policySocketFD; 111 155 112 /* TODO156 /*! TODO 113 157 */ 114 158 Utility *utils; … … 116 160 Observable *observables; 117 161 118 /* TODO162 /*! TODO 119 163 */ 120 164 struct Radio_Info *radio_info;