Anda di halaman 1dari 8

Configuring Store and Forward

If you have already been collecting data for the CIM-IO Server (Interface), prior to the
configuration of store and forward, you will want to turn off the processing of the Cim-IO client.
(This will enable you to change the configuration, without getting errors in the process.)

In the IP21 Administrator, turn off the IO_DEVICE_PROCESSING of the device record
In the IP21 Administrator, turn off the IO_RECORD_PROCESSING of the transfer
record(s)

CIM-IO SERVER

ENSURE THAT THE CIMIO_LOGICAL_DEVICES.DEF FILE HAS THE


APPROPRIATE ENTRIES
On the CIM-IO server machine, navigate to <drive>:\Program Files\Aspentech\Cim-
io\etc and open cimio_logical_devices.def in notepad.
Make a note of these entries, as you will need them to complete some of the following
configuration.
Note: Cim-IO for OPC is currently the only interface that makes its own entries in this
file upon startup. For all other Cim-IO interfaces, the interface specific installation
manual will direct the user to make certain entries in this file. If your
cimio_logical_devices.def file is empty, please refer to the interface specific manual for
instructions on the proper entries for this file.

MODIFY THE CIMIO_AUTOSTART.BAT FILE, TO START THE STORE AND


FORWARD PROCESSES
There are three executables that manage the Store and Forward process. You can start them
manually each time you start the Cim-IO server, or you can modify the cimio_autostart.bat
file so that each time the Cim-IO Manager service (which can be set to start automatically on
boot) is started, it also starts the Store and Forward processes.
In NT Explorer, navigate to <drive>:\Program Files\AspenTech\Cim-
IO\Commands\cimio_autostart.bat
Right-click on the file, and choose edit
Modify the file to call the Cim-IO Store and Forward start batch file. You must add
the DLGP service name of your Cim-IO server as a parameter to the startup batch
file.
Modify your cimio_autostart.bat file with the following line:
call %cimiorootq%\commands\cimio_sf_start <DLGP service name>

The file should look something like this screen capture:


MODIFY THE CIMIO_AUTOSTOP.BAT FILE, TO STOP THE STORE AND
FORWARD PROCESSES
The three executables that manage the Store and Forward process occasionally need to be
shutdown. In order to simplify the process, you can modify the cimio_autostop.bat file so
that shutting down the Cim-IO Manager service also shuts them down. To configure the
shutdown:
In NT Explorer, navigate to <drive>:\Program Files\AspenTech\Cim-
IO\Commands\cimio_autostop.bat
Right-click on the file, and choose edit
Modify the file to call the CIM-IO Store and Forward shutdown executable. You
must add the DLGP service name of your Cim-IO server as a parameter to the
shutdown file.
Modify your cimio_autostop.bat file with the following line:
call %cimiorootq%\code\cimio_sf_shutdown /S=<DLGP service name>

The file should look something like this screen capture:

ADD SERVICE ENTRIES FOR STORE AND FORWARD PROCESSES


The Store and Forward processes will run as a service, so they will need to be entered into
the NT Services file of the Cim-IO server.
Open the NT Services file on the Cim-IO Server (c:\winnt\system32\drivers\etc)
Using unique port numbers for each service, add the following 3 service entries
<DLGP service name>_SC
<DLGP service name>_ST
<DLGP service name>_FW
You should already have an entry for the DLGP service of the CIM-IO server in the
NT services file. (You may also have services defined for DIOPs if your interface

2
requires them.) If you do not have an entry in the services file for the DLGP service
name, refer to the cimio_logical_devices.def file for the name. Enter it in the services
file and assign it a unique TCP port.

Note: Service names cannot exceed 15 characters in length. If your DLGP service name
is between 13 -15 characters in length, delete the first three characters in the beginning
of DLGP service name and add the 3 character store and forward extension, to make a
total of 15 characters for the store and forward service entries. For example, if your
DLGP service name was CIOPROCESSXOPCS, your entries for the store and forward
services would be:
PROCESSXOPCS_SC
PROCESSXOPCS_ST
PROCESSXOPCS_FW

Make note of these service entries and port numbers, because you will need to add the
same ones to the Cim-IO client machine (IP.21). The port numbers will need to be the
same on both server and client, so if the service numbers you chose on the Cim-IO server
are already used on the IP.21 machine, you’ll need to adjust them.
IMPORTANT REMINDER – Ensure that there is a carriage return at the end of the NT
services file before saving. When this file is read by the system it disregards the last line
of the file, therefore ignoring the final service in the file if there isn’t a carriage return.

START THE CIM-IO SERVER


Start the CIM-IO server. If you aren’t sure how, please refer to the interface specific manual
for your CIM-IO server.

START THE STORE AND FORWARD PROCESSES


Go to Start | Settings | Control Panel | Services

3
Start the Cim-IO Manager service
In the NT Task manager, verify that the following three processes are running:
o cimio_sf_forward.exe
o cimio_sf_scanner.exe
o cimio_sf_store.exe
(The Cim-IO Manager service starts all these, since it calls the
cimio_autostart.bat file, which you just modified to call the Store and Forward
start file.)

If these processes are running, you have properly configured the cimio_autostart.bat file, and
the NT services file. Store and Forward is now successfully configured on the Cim-IO
Server. Proceed to the client side configuration.

CIM-IO CLIENT CONFIGURATION (IP.21 machine)

NOTE: As of InfoPlus.21 version 3.1 and CIM-IO core version 5, a wizard is available in the
IP.21 Administrator tool. The wizard can guide the user through configuring the client side
records and files, but is not described in this guide. (The intent of this guide is to also
familiarize the user with the individual records and files involved in configuration.) For more
information on using the wizard, please refer chapter 7 of the CIMIO Version 5 Users Manual.

ADD SERVICE ENTRIES FOR STORE AND FORWARD PROCESSES


You will need to duplicate the service entries and port numbers of the three Store and
Forward processes in the NT Services file of the Cim-IO client.
Open the NT Services file on the InfoPlus.21 machine (c:\winnt\system32\drivers\etc)

4
Using the exact same port numbers as you entered on the Cim-IO server, add the 3
store and forward service entries (the services ending in _SC, _ST and _FW).
NOTE: You should already have an entry for the DLGP service of the CIM-IO server
in the NT services file. If you do not have an entry in the services file for the DLGP
service name, make an entry that matches the one on the CIM-IO server node. Make
sure to use the exact same TCP port number on both machines.
ADD ENTRIES TO THE CIMIO_LOGICAL_DEVICES.DEF FILE
Add the exact entries you noted from the cimio_logical_devices.def file on the CIM-IO
server machine to the cimio_logical_devices.def file on the InfoPlus.21 machine. There may
already be entries in this file if you are scanning from other CIM-IO servers, so just append
your entries to the end of this file and save.
CONFIGURE THE MAIN CLIENT TASK
In order for the client to actively connect to the Cim-IO server, a main client task, and
corresponding task record must be created. If this hasn’t already been done, please complete
the following steps:
Using the IOExternalTaskDef record, create a record named TSK_M_<X> (The <X>
should be replaced with something to specify which CIM-IO server this task will
operate for. (An example would be TSK_M_OPC if you were running the CIM-IO
for OPC interface.)
o In the IO_DEVICE field, enter the logical device name of your CIM-IO server
(this will also be the name of the IODeviceRecDef record you will create).
Create the actual client tasks in the IP21 Manager
o Open the InfoPlus.21 Manager
o In the Task Name field, enter TSK_M_<X>
o In the subsystem drop-down box, select BASE
o Enter a check mark in the External Task box
o In the executable field, enter %SETCIMCODE%/cimio_c_client.exe
o Press ADD
o Once the task has been added, find it in the defined tasks window and select
RUN TASK (observe the task in the “Running Tasks” window.)

5
CREATE ASYNC EXTERNAL TASK AND EXTERNAL TASK RECORD
Store and Forward is an asynchronous method of data transfer. As such, you will need to
create an external task record and the corresponding asynchronous task.
Open the IP21 Administrator
Using the IOExternalTaskDef record, create a record named TSK_A_<X>. (The
<X> should be replaced with something to specify which CIM-IO server this task will
operate for. For better organization, it should usually match the naming convention
used for the main client task. (An example would be TSK_A_OPC if you were
running the CIM-IO for OPC interface.)
o In the IO_DEVICE field, enter the logical device name of your CIM-IO server
Open the IP21 Manager
Create an external task named TSK_A__<X>
o For the subsystem field, enter Base
o In the executable field, enter %SETCIMCODE%\cimio_c_async.exe
o Ensure the external task box has a check mark
o Click ADD to create the new task
In the Defined Tasks box of the IP21 Manager, locate TSK_A_<X> and press RUN
(observe the task in the “Running Tasks” window.)

6
STOP SCHEDULING OF ANY EXISTING TRANSFER RECORDS
If you have already been scanning data from the CIM-IO server without Store and Forward,
you will already have configured some ScheduledActDef records to activate any transfer
records going to that server. In the case of Store and Forward, we want the Cim-IO Server to
initiate the scanning of the data (not IP.21), so that it can continue scanning even if IP.21
goes down. Therefore, you must disable the any ScheduledActDef records that are
activating transfer records for this CIM-IO server.

MODIFY THE IO DEVICE RECORD


You should already have a record in the IP.21 database that has the exact same name as your
logical device. This record is defined by IODeviceRecDef. If this record hasn’t yet been
created, make one now.
Several fields in this record must be set in order to enable Store and Forward.
Verify that the specified fields contain the following entries:
IO_MAIN_TASK=TSK_M_<X>
IO_ASYNC? = Yes
IO_ASYNC_TASK = TSK_A_<X>
IO_STORE_ENABLE? = Yes

MODIFY THE TRANSFER RECORD


Modifications are needed to the transfer record(s) (defined by IOGetDef, IOGetHistDef,
IOLongTagGetDef or IOUnsolDef), in order to enable Store and Forward. The scan rate will
now be specified in the transfer record itself, as opposed to a scheduling record.
Verify that the specified fields of the transfer record(s) contain the following entries:
IO_MAIN_TASK=TSK_M_<X>
IO_ASYNC? = Yes
IO_FREQUENCY = <enter the rate you’d like the records in the repeat area to be
scanned>

NOTE: The repeat area of the transfer record should contain an occurrence for each tag
on this particular CIM-IO server that you would like to be scanned at the specified
frequency. A transfer record is affiliated with only one CIM-IO server (although you can
have several transfer records per CIM-IO server), and it provides the link between the
tag name on IP.21 and the tag name on your process equipment.

TURN ON PROCESSING
To start collecting data:
Turn on the IO_DEVICE_PROCESSING of the IODeviceRecDef record (it should
be named after your logical device)
Turn on the IO_RECORD_PROCESSING of the transfer record(s)
Activate the transfer record(s) by right-clicking on the tag in the left pane of the
Administrator, and selecting “activate” in the following dialog box.
Press F5 to refresh the Administrator
Check the IO_LAST_STATUS field of the transfer record for a status of the transfer.

7
IF THE STATUS INDICATES A PROBLEM:
Ensure that the CIM-IO server, and all 3 store and forward processes are still running
on the CIM-IO server node.
Ensure that the two machines can ping one another
Ensure that the TSK_M_<X> and TSK_A_<X> are still running in the IP.21
Manager
TEST THE CONNECTION
1. From the IP.21 machine, go to Start | Programs | Aspentech | Aspen
Manufacturing Suite – Information Management | Cim-io | Test API
2. Perform a Get request (9) to retrieve a value for a tag on the process
equipment.
3. (For more information on using this tool, contact support.
4. If the status of your Test API get request is GOOD, there is likely a
configuration problem on the client side. Double-check the entries in your
records against the above instructions.
If the status of your get request indicates a communication problem, trying running
this same Test API utility from the CIM-IO server node for more information.
If none of the above steps help, contact support.

Anda mungkin juga menyukai