JDIS Tool Setup

Required Software Packages

  1. Java installation (JDK 1.6 or later version),
  2. Java Swing Package,
  3. CORBA IIOP implementation (JWORB), and
  4. CORBA based HLA RTI implementation (OWRTI).

Java and Swing can be obtained from http://www.javasoft.com/. Before proceed in this Setup procedure, please make sure that you have necessary installations in your environment ready and functional.

See How to obtain softwares? for information about obtaining JWORB, OWRTI, and JDIS packages.

Directories

When you unpack the JDIS archive, you will get the following subdirectories under the main JDIS directory. These sub-directories are:

classes:class binaries
config:configuration files.
data:some PDU data.
docs:documents and User Guide.
include:CDRCoderEncoder.h object for C++ clients to solve Big/Little Endian problem.
src:Java source files and changed mil.navy.nps.* package.

How to Run

On Unix Machines

config/config.unix file contains the following settings:

JAV_HOME: Set this variable to your java home
SWING_HOME: Set this variable to your SWING installation where swingall.jar file is.
JDIS_HOME: Set this variable to your JDIS installation directory
OWRTI_HOME: Set this variable to your OWRTI installation directory
JWORB_HOME: Set this variable to your JWORB installation directory

In the following example, Java is installed in /usr/npac/jdk1.2.1 directory therefore JAV_HOME is set to /usr/npac/jdk1.2.1. JDIS is installed in /iwt99/projects/monitor and JDIS_HOME points this directory.

# JAVA HOME
JAV_HOME =  /usr/npac/jdk1.2.1
JAVAC    =  $(JAV_HOME)/bin/javac
JAVA     =  $(JAV_HOME)/bin/java
SWING_HOME = /iwt99/technologies/swing-1.1

# JDIS HOME
JDIS_HOME  = /iwt99/projects/monitor
# OWRTI HOME
OWRTI_HOME = /iwt99/projects/owrti
# JWORB HOME
JWORB_HOME = /iwt99/projects/jworb
   

After set up is complete, goto $(JDIS_HOME) directory

cd /iwt99/projects/monitor 

and start the program with:

runJDIS

this script uses make utility to start up the program. If you want to change the command line options, you can edit the Makefile in $(JDIS_HOME) directory. An example line looks as:

SMain:
        $(JAVA) $(CORBA_SETTINGS) -classpath $(CPATH) jdis.SMain -nserver osprey1.npac.syr.edu -nport 4004
   

If you are running JWORB server on machine osprey1.npac.syr.edu port 4004, then everything is fine. If you are running JWORB server on machine herman.arl.mil port 4321 then you have to change these settings by editing the file, and it should look as follows after your edit.

SMain:
        $(JAVA) $(CORBA_SETTINGS) -classpath $(CPATH) jdis.SMain -nserver herman.arl.mil -nport  4321
   

See Using JDIS for more information about command line options.

On Windows/NT Machines:

runJDIS.bat file in $(JDIS_HOME) directory contains the necessary settings for Windows/NT machines.

set JAV_HOME=c:\jdk1.2.1
set JAV_CLASSES=%JAV_HOME%\lib\classes.zip
set SWING_HOME=d:\users\timucin\swing-1.1

set SERVER_PORT=4004
set SERVER_MNAME=osprey1.npac.syr.edu

set JDIS_HOME=d:\users\timucin\monitor
set JWORB_HOME=d:\users\timucin\jworb
set OWRTI_HOME=d:\users\timucin\owrti

# CORBA IIOP Settings points to JWORB
set ORBClass=worb.protocols.iiop.ORBImpl 
set ORBSingletonClass=worb.protocols.iiop.ORBImpl

This example assumes that the Java is installed in c:\jdk1.2.1 directory, therefore JAV_HOME points c:\jdk1.2.1 directory. In this example, if you are running the JWORB server on osprey1.npac.syr.edu port number 4004, there is nothing to set up. If you are running the JWORB server on herman.arl.mil port number 4321, then you have to edit runJDIS.bat as the following to setup the right machine name and port number of the JWORB server.

set SERVER_PORT=4321
set SERVER_MNAME=herman.arl.mil

JDIS_HOME points to d:\users\timucin\monitor directory since it assumes that JDIS package is installed in d:\users\timucin\monitor. If you installed the JDIS package in another directory, for example e:\users\iwt99\monitor, then this settings should be changed as follows:

 set JDIS_HOME=e:\users\iwt99\monitor 

JWORB_HOME points to d:\users\timucin\jworb directory since it assumes that JWORB package is installed in d:\users\timucin\jworb. If you installed the JWORB in another directory, for example e:\users\iwt99\jworb, then this settings should be changed as follows:

 set JWORB_HOME=e:\users\iwt99\jworb 

OWRTI_HOME points to d:\users\timucin\owrti directory since it assumes that OWRTI package is installed in d:\users\timucin\owrti. If you installed the OWRTI in another directory, for example e:\users\iwt99\owrti, then this settings should be changed as follows:

 set OWRTI_HOME=e:\users\iwt99\owrti 

ORBClass and ORBSingletonClass variables are used to tell Java org.omg.CORBA package that we want to use JWORB CORBA 2.2 implementation. You do not need to change this settings. The value of these variables are used to set org.omg.CORBA.ORBClass and org.omg.CORBA.ORBSingletonClass standard environment variables.

Based on above installation changes, the runJDIS.bat file looks as the following:

set JAV_HOME=c:\jdk1.2.1
set JAV_CLASSES=%JAV_HOME%\lib\classes.zip
set SWING_HOME=d:\users\timucin\swing-1.1

set SERVER_PORT=4321
set SERVER_MNAME=herman.arl.mil

set JDIS_HOME=e:\users\iwt99\monitor
set JWORB_HOME=e:\users\iwt99\jworb
set OWRTI_HOME=e:\users\iwt99\owrti

# CORBA IIOP Settings points to JWORB
set ORBClass=worb.protocols.iiop.ORBImpl 
set ORBSingletonClass=worb.protocols.iiop.ORBImpl

How to Compile

$(JDIS_HOME)/config directory contains two configuration file: config.unix and config.win. These files includes the necessary variables to compile the sources. For practical reasons, we used the same names in both files. The variables are:

JAV_HOME: Set this variable to your java home
SWING_HOME: Set this variable to your SWING installation where swingall.jar file is.
JDIS_HOME: Set this variable to your JDIS installation directory
OWRTI_HOME: Set this variable to your OWRTI installation directory
JWORB_HOME: Set this variable to your JWORB installation directory

On Unix platforms, you have to edit $(JDIS_HOME)/config/config.unix file and set the variables to the proper directories.

# JAVA HOME
JAV_HOME =  /usr/npac/jdk1.2.1

# SWING HOME
SWING_HOME  = /iwt99/technologies/swing-1.1

# JDIS HOME
JDIS_HOME  = /iwt99/projects/monitor
# OWRTI HOME
OWRTI_HOME = /iwt99/projects/owrti
# JWORB HOME
JWORB_HOME = /iwt99/projects/jworb
   

On Windows/NT platforms, you have to edit $(JDIS_HOME)/config/config.win file and set the variables to the proper directories.

# JAVA HOME
JAV_HOME =  c:\jdk1.2.1

# Java Swing Home
SWING_HOME = d:\users\timucin\swing-1.1
# JDIS Home
JDIS_HOME = d:\users\timucin\monitor
# JWORB Home
JWORB_HOME = d:\users\timucin\jworb
# OWRTI Home
OWRTI_HOME = d:\users\timucin\owrti
   

On Unix platforms, go to $(JDIS_HOME)/src directory

	cd /iwt99/projects/monitor/src 

run the make utility;

	make 

This uses the Makefile in the $(JDIS_HOME)/src directory to build the binaries for JDIS.

On Windows/NT platforms, go to $(JDIS_HOME)/src directory

	cd d:\users\timucin\monitor\src

run the nmake utility;

	nmake /f Makefile.win

This uses the Makefile.win in the $(JDIS_HOME)/src directory to build the binaries for JDIS.


Updated on : January 9, 1999