Computer Monitoring Project with Tango (Problem with device driver testing in Jive)

Hello everyone,
I'm currently studying Automation and computer science, and during my fifth and last year I have a final study project to do.

My project is to work on Sardana, understand how it works and to develop at least a small project as a proof of concept.

I’ve been trying to understand how Tango and all its dependencies (Jive, Pogo, Taurus etc…) are working. This website, forum and all the files here we very helpful, thank you.

My teacher suggests me to develop a monitoring server for several computer of the school. For example, design a page with several computer represented and several information for each one. (Power ON, %CPU, %Memory, Network traffic…).

So far I have developed the client program in Java. It’s based on the Hyperic Sigar API with which I can get the computer information and I wrapped all of this in a TCP/IP server. (By the way, it should be cross-platform)

My goal now is to develop via Pogo a driver (in Python). Here is the design: http://i84.servimg.com/u/f84/18/98/19/12/2016-010.png.
Since I’m a total beginner with Tango and moreover Pogo, I’m not sure I’m developing the right way.
My idea is to use the function: read_attr_hardware. I will code the TCP client in this function. This client will connect to wrapper of the client machine. As soon as the client socket is accept in my wrapper is sending a message with the information (ie: “Mem = 39,32|CPU = 46,06|File = 85”). Then I will substring the three info to the attributes (attr_XXXX_read).

Sorry for this very long post but since I’m total beginner I would like to be sure that my design of the project seems correct to you please.

Finally, I also have another question. I didn’t understand what are steps to implement the driver that I’ve created (in Pogo) into Jive in order to test it in Tango.
Could you please tell me how should I do it?

Once again, thank you for your help.
Regards,
Robin
Edited 8 years ago
My project is to work on Sardana, understand how it works and to develop at least a small project as a proof of concept.

From the rest of the information that you have provided I do not see a clear relation to the Sardana project. Your project sounds more like a general monitoring system exporting the diagnostic values to the Tango world, what would allow to easily create, for example, Taurus based client application (based on Qt). Regarding Sardana, I suggest to read the following explanation of the project.

My teacher suggests me to develop a monitoring server for several computer of the school. For example, design a page with several computer represented and several information for each one. (Power ON, %CPU, %Memory, Network traffic…).

I know about one, already existing, device server of similar purposes. This is Process Profiller, and serves to monitor status of the given processes distributed on remote hosts (Linux only). Maybe there are other, similar, device servers already developed that could help in developing your project. I would look in the SoftwareSystem family in the repository.

So far I have developed the client program in Java. It’s based on the Hyperic Sigar API with which I can get the computer information and I wrapped all of this in a TCP/IP server. (By the way, it should be cross-platform)

I'm not sure if I've understood well your setup yet. It is probably because I don't know the Hyperic Sigar API. Could you elaborate more on the principal setup. Is the TCP/IP server, that you have developed, running on each of the PCs that you monitor and the idea is that your Tango device server opens sockets to all of them and requests the information? Or maybe there are some Hyper Sigar agents running on each of the PCs, and a single instance of the TCP/IP server (at the same time client of the agents) monitors all of the PCs?

My goal now is to develop via Pogo a driver (in Python). Here is the design: http://i84.servimg.com/u/f84/18/98/19/12/2016-010.png.
Since I’m a total beginner with Tango and moreover Pogo, I’m not sure I’m developing the right way.
My idea is to use the function: read_attr_hardware. I will code the TCP client in this function. This client will connect to wrapper of the client machine. As soon as the client socket is accept in my wrapper is sending a message with the information (ie: “Mem = 39,32|CPU = 46,06|File = 85”). Then I will substring the three info to the attributes (attr_XXXX_read).

I think that your idea to use the read_attr_hardware method in order to request the information and parse it in the attr_XXXX_read is correct. Chapter 1.13.2 from the TANGO Device Server Guidelines confirms that.

Finally, I also have another question. I didn’t understand what are steps to implement the driver that I’ve created (in Pogo) into Jive in order to test it in Tango.
Could you please tell me how should I do it?

In order to test your device server, you would need to create an instance in the database and run the device server process. Please follow this guide on how to create a device server in the database. This guide is not updated to the latest version of Jive, so instead of opening the Create/Edit a server dialog via right click on the "SERVER" node you would need to navigate to the menu Edit and select the Create server option. The rest of the guide is correct.
 
Register or login to create to post a reply.