NEESgrid logo

Data Acquisition Tester

This project includes code to test the data acquisition system. It may be used for testing a new DAQ system or to test a current DAQ to make sure most components of the DAQ are working properly. The software is written in Java which means that should work in most plataforms that run a JVM.

Table of of Contents
Documentation
Sample Run
Get the code
How to run the code?
Usage Notes
Related links
Navigation links
Support

Documentation

Here is the code documentation. This is is Doxygen-generated documentation from the source code; if you download the code you always have the docs. This is a snapshot from 7/22/03.
Daq Eater

Quick Overview of the GUI

Numbers refer to Figure

  1. This is the command port. Default value is 55055. Whatever the command port is set to, the data port will become the command port plus one.
  2. This is the host name where the DAQ is running. The name can also be an ip address.
  3. Button used to try to establish a connection with the DAQ.
  4. Button used to disconnect from the DAQ.
  5. Once the connection is establish. A single command can be typed and send to the DAQ and the result window will display the DAQ's responce.
  6. If the responce to a particular command is known, it can be typed and compared to the DAQ responce this will show if it PASS or FAIL.
  7. Button used to test a single command.
  8. Place where to enter how many times to read data from the DAQ. Must be a valid number.
  9. Button used to read data from the DAQ. The number of times will be determined by the number entered in #8. The results will be displayed in the result window. A port must be open manually using 'open-port [some valid port]' entered in #5 above.
  10. Place where to entered how many times to run the test suite.
  11. Button used to start the test suite.
  12. This button resets all the values of the GUI. It will not close the connection. But the command port will be set to 55055. The DAQ Machine will be set to localhost. Command to test and Known result will be both sent to blank. The times to read Data and the number to run the test suite will both be set to 1. And the result window will be cleared.
  13. This box should be check if the user wants to log debugging information.
  14. This is the result window. It will display all the results and debugging information if the correct boxes are checked.
  15. This box should be check if the user wants to see the debugging information at all times.
  16. This reset button clears the result window.
  17. This is the status of the connection to the DAQ, either 'offline' or 'connected'.
  18. Menu to save or open status of the DAQ Tests. To close the DAQ tester. NOT IMPLEMENTED YET.
  19. Tab where the Driver tester will be at. NOT IMPLEMENTED YET.
  20. Tab where the NSDS tester will be at. NOT IMPLEMENTED YET.
  21. Tab where to set values for all three test suites. NEEDS REVISION.

Sample Run

The first thing is to run the program. Go to How to run the code? if the DAQ tester is not running. Make sure a DAQ system is running in the DAQ Machine for this sample run the DAQ Machine is the localhost and the DAQ is fake_daq. Once we click the connect button the status should change from a red "offline" to a green "Connected". At this point a connections has been establish we are ready to test. To illustrate how to use the Command to test. Enter 'list-channes' under "Command to test:". Then click on the button "Test" right below it. The following is the result running fake_daq.

Daq Eater

Now in order to read some data from the DAQ we need to open a port. So in the same manner we entered 'list-channels' will enter 'open-port 0' where 0 is just any valid port. The result after clicking the "Test" button should be.

Daq Eater

The last step to read data is to enter how many lines of data we want fromm the DAQ. Will enter '10' right below "Times to read Data:" and after we click on the button label "Read Data" we get the following result.

Daq Eater

Now if we click on the button label "Run DAQ test suite" a few things will happen. First it will reset the result window. It will also clear the data socket and the command socket. After its done all ports are close. In order to read more data we would need to re-open some ports. So lets first check "Log debugging info". This will log debugging information but it will not be shown in the result window unless we also check "Show debugging Info". Now lets click on "Run DAQ test suite" to see what happends. The following is a snap shot while the test suite is in progress.

Daq Eater

There is a little dialog box that contains a progress bar and a button label "Stop testing." The button is just to terminate the testing of that particular test run. This is useful if something wrong happend and is getting no responce from the DAQ so the progress bar is not moving at all. Also the progress bar will turn red if any of the tests fails. Lets look at the display when the test suite is finish.

Daq Eater

As we can see it displays how many tests it ran. How many failed and how many passed. Currently, the specifications of what should the DAQ due when someone tries to open a bad channel or close a bad channel have not been finalized. This last two tests can be ignored. Now lets click on "Show debugging Info" to see the new display.

Daq Eater

This has has all the debugging information. The command send to the DAQ and the responce of the DAQ. If we look at the tests that failed, the command 'open-port 9,,0' has an invalid port because there can be no commas in the names of the port. The test suite expected the DAQ to acknowledge this by responding with 'Invalid port '9,,'0' but the actual responce was 'Streaming data on data channel from port 9'.

Get the code

  • Current code is available from the CVS archive, package name dndtester.
  • A binary or JAR file download it here.
  • How to run the code?

    Source Code with Ant.

    If Ant is install in your system runt the command "ant run" from inside the top most directory in the dndtester. This will compile and run the program.

    Source Code without Ant.

    There are many ways to compile the java source. One way would be to go in the src directory found inside dndtester. Then run "javac dndtester/*.java" then run "java dndtester/DaqDriverTest" will execute the code.

    From the JAR file

    If you downloaded the binary or JAR file the command to run is "java -jar dndtester.jar".

    Usage Notes

    Requires Java Platform version 1.4.1 or higher.

    Related links

  • Doxygen-generated source code docs
  • The CVS archive instructions
  • Dataq instruments home page
  • Dataq data format, local mirror
  • Navigation links

  • Back to main NEESgrid page
  • Back to home page
  • Support

    Email Jose Calderon at calderon@mcs.anl.gov.