]> jspc29.x-matter.uni-frankfurt.de Git - trbnettools.git/commitdiff
now ready for RPC calls
authorhadaq <hadaq>
Mon, 17 May 2010 23:50:34 +0000 (23:50 +0000)
committerhadaq <hadaq>
Mon, 17 May 2010 23:50:34 +0000 (23:50 +0000)
trbrich/pulser.c
trbrich/trb_i2c.c
trbrich/trbflash.c
trbrich/trbrichcmd.c

index 5ab913853737193befda6a1409b636079bb9124c..0792a4d0772b37ddda699b690adcfcffce1cafbd 100644 (file)
@@ -11,7 +11,7 @@
 #include <trbnet.h>
 #include <trberror.h>
 
-static const char pulser_version[] = "$Revision: 1.7 $"; 
+static const char pulser_version[] = "$Revision: 1.8 $"; 
 
 /* 6MByte for 6 Sectors should be enough */
 #define BUFFER_SIZE (6 * 1024 * 1024 / 4)
@@ -107,7 +107,11 @@ int main(int argc, char ** argv)
   }
 
   /* open port */
-  init_ports();  
+#ifndef TRB_RPC
+  init_ports();
+#else
+  trb_connect(NULL);
+#endif  
 
   /* Open HLD-File */
   if (strncmp(hldFileName, "stdout", 256) != 0) {
index 2960f2942798a85e35730a49dfbca11da2f20bbd..bed9eca60438abde9ced1ef7bf8c319211642e34 100644 (file)
@@ -11,7 +11,7 @@
 
 #define BUFFER_SIZE (6 * 4096)
 
-static const char trb_i2c_version[] = "$Revision: 1.6 $"; 
+static const char trb_i2c_version[] = "$Revision: 1.7 $"; 
 
 static const uint16_t trb_i2c_register = 0x8040;
 
@@ -159,7 +159,11 @@ int main(int argc, char** argv)
   }
         
   /* Open port */
+#ifndef TRB_RPC
   init_ports();
+#else
+  trb_connect(NULL);
+#endif
   
   if (strcmp(argv[optind], "w") == 0) {
     
index a750e2d74f0207645fe082a4520f751665982ae7..aa39c479717dd96b0de1649478d2c55345356320 100644 (file)
@@ -90,7 +90,7 @@ static const char FlashTypeStr[][32] =
 
 static FlashType flashType = FLASH_INVALID; 
 static uint32_t manId = 0;
-static const char trbflash_version[] = "$Revision: 2.15 $"; 
+static const char trbflash_version[] = "$Revision: 2.16 $"; 
 
 static uint32_t mdcFlashSelect = 1;
 
@@ -1182,11 +1182,15 @@ int main(int argc, char ** argv)
     usage(basename(argv[0]));
     exit(EXIT_FAILURE);
   }
-  
+#ifndef TRB_RPC 
   if (init_ports() == -1) {
     trb_error("Init_Ports");
     exit(EXIT_FAILURE);
   }
+#else
+  trb_connect(NULL);
+#endif
   
   atexit(atexit0);
 
index 4a0e5122bb2e921ce6552686e0ed1e84521cff74..4f9571de83b1b92e4c1afaf48424765e262d1d06 100644 (file)
@@ -13,7 +13,7 @@
 
 #define TEMP_RESOLUTION 0.0625
 
-static const char trbrichcmd_version[] = "$Revision: 1.7 $"; 
+static const char trbrichcmd_version[] = "$Revision: 1.8 $"; 
 
 static const uint16_t adcm_uid_register = 0xc000;
 
@@ -70,8 +70,12 @@ int main(int argc, char** argv)
   }
         
   /* Open port */
+#ifndef TRB_RPC
   init_ports();
-  
+#else
+  trb_connect(NULL);
+#endif
+
   if (strcmp(argv[optind], "uid") == 0) {
     
     /*************************************************/