Index: /vtcross/trunk/src/cognitive_engines/cbr_demo.c
===================================================================
--- /vtcross/trunk/src/cognitive_engines/cbr_demo.c	(revision 161)
+++ /vtcross/trunk/src/cognitive_engines/cbr_demo.c	(revision 181)
@@ -538,5 +538,5 @@
 {
     // Send register message to cognitive radio
-    SendMessage(sockfd, "c_register");
+    SendMessage(sockfd, "register_engine_cognitive");
     return 1;
     
Index: /vtcross/trunk/src/include/vtcross/components.h
===================================================================
--- /vtcross/trunk/src/include/vtcross/components.h	(revision 173)
+++ /vtcross/trunk/src/include/vtcross/components.h	(revision 181)
@@ -65,4 +65,8 @@
  * inherit (e.g. cognitive and policy engines). Inherits all functions from the
  * ABC Component publically.
+ *
+ * TODO perhaps this shouldn't be an abstract base class? Some functions, like
+ * GetRemoteComponentType, are going to be the same for all child classes
+ * anyways...
  */
 class Engine : public Component
@@ -130,4 +134,15 @@
 
 
+/* Contains information regarding the SML in a VTCROSS system.  Note that if
+ * there is no SML present, the engine should have no instantiation of this
+ * struct.
+ */
+struct SML_Info {
+    std::string hostname;
+    std::string port;
+    int32_t socketFD;
+};
+
+
 /* Policy Engine class declaration.  All public functions are inherited from
  * parent classes.
@@ -138,4 +153,10 @@
         PolicyEngine();
         ~PolicyEngine();
+
+
+        /* Overloaded constructor that creates a policy engine object with SML
+         * information pre-defined.
+         */
+        PolicyEngine(const char* serverName, const char* portNumber);
 
         void GetRemoteComponentType(int32_t socketFD);
@@ -167,4 +188,11 @@
         void ValidateParameters(struct Parameter pList[], \
                 struct CE_Info *ce_info, int decision_array[]);
+
+
+        /* Contains information regarding the presence of a service management
+         * layer.  If this pointer is NULL, then there is no SML present in the
+         * radio system.
+         */
+        struct SML_Info *SML;
 };
 
@@ -219,4 +247,12 @@
         void ReceiveFeedback(Observable *observables, \
                 Parameter *parameters, std::string service);
+
+
+        /* Contains information regarding the presence of a service management
+         * layer.  If this pointer is NULL, then there is no SML present in the
+         * radio system.
+         */
+        struct SML_Info *SML;
+
 };
 
Index: /vtcross/trunk/src/policy_engines/PolicyEngine.cpp
===================================================================
--- /vtcross/trunk/src/policy_engines/PolicyEngine.cpp	(revision 164)
+++ /vtcross/trunk/src/policy_engines/PolicyEngine.cpp	(revision 181)
@@ -24,4 +24,5 @@
 {
     LOG("Creating Policy Engine.\n");
+    SML = NULL;
     LoadPolicies();
 }
@@ -30,4 +31,23 @@
 PolicyEngine::~PolicyEngine()
 {
+    if(SML)
+        delete SML;
+}
+
+
+PolicyEngine::PolicyEngine(const char* serverName, const char* portNumber)
+{
+    LOG("Creating Policy Engine.\n");
+
+    SML = new SML_Info;
+    SML->hostname = std::string(serverName);
+    SML->port = std::string(portNumber);
+
+    SML->socketFD = ClientSocket(serverName, portNumber);
+    RegisterServices(SML->socketFD);
+
+    LOG("Policy Engine connected to SML at %s.\n", serverName);
+
+    LoadPolicies();
 }
 
@@ -74,6 +94,7 @@
 PolicyEngine::RegisterComponent(int32_t socketFD)
 {
-    SendMessage(socketFD, "p_register");
+    SendMessage(socketFD, "register_engine_policy");
     LOG("Policy Engine:: Registration message sent.\n");
+
 }
 
@@ -88,4 +109,9 @@
 PolicyEngine::RegisterServices(int32_t socketFD)
 {
+    LOG("Policy Engine:: Registering services.\n");
+    SendMessage(socketFD, "register_service_pe_geo");
+    SendMessage(socketFD, "register_service_pe_time");
+    SendMessage(socketFD, "register_service_pe_spectrum");
+    SendMessage(socketFD, "register_service_pe_spacial");
 }
 
@@ -94,4 +120,9 @@
 PolicyEngine::DeregisterServices(int32_t socketFD)
 {
+    LOG("Policy Engine:: Deregistering services.\n");
+    SendMessage(socketFD, "deregister_service_pe_geo");
+    SendMessage(socketFD, "deregister_service_pe_time");
+    SendMessage(socketFD, "deregister_service_pe_spectrum");
+    SendMessage(socketFD, "deregister_service_pe_spacial");
 }
 
Index: /vtcross/trunk/src/shell/cr_shell.cpp
===================================================================
--- /vtcross/trunk/src/shell/cr_shell.cpp	(revision 179)
+++ /vtcross/trunk/src/shell/cr_shell.cpp	(revision 181)
@@ -512,8 +512,8 @@
     LOG("Cognitive Radio:: Message Received - %s.\n\n", buffer);
 
-    if(strcmp(buffer,"c_register") == 0) 
+    if(strcmp(buffer,"register_engine_cognitive") == 0) 
 	    InitializeCE(socketFD, uList, pList, oList, ce_info);
 
-    if(strcmp(buffer,"p_register") == 0)
+    if(strcmp(buffer,"register_engine_policy") == 0)
 	    InitializePE(socketFD, ce_info);
 
Index: /vtcross/trunk/src/service_management_layer/ServiceManagementLayer.cpp
===================================================================
--- /vtcross/trunk/src/service_management_layer/ServiceManagementLayer.cpp	(revision 164)
+++ /vtcross/trunk/src/service_management_layer/ServiceManagementLayer.cpp	(revision 181)
@@ -72,5 +72,5 @@
 ServiceManagementLayer::RegisterComponent(int32_t socketFD)
 {
-    SendMessage(socketFD, "sml_register");
+    SendMessage(socketFD, "register_sml");
     LOG("ServiceManagementLayer:: Registration message sent.\n");
 }
Index: /vtcross/trunk/src/Makefile.am
===================================================================
--- /vtcross/trunk/src/Makefile.am	(revision 161)
+++ /vtcross/trunk/src/Makefile.am	(revision 181)
@@ -1,2 +1,2 @@
-SUBDIRS = lib policy_engines cognitive_engines service_management_layer \
-		  libvtcross shell include
+SUBDIRS = lib include policy_engines cognitive_engines service_management_layer \
+		  libvtcross shell
