Re: [foxboro] AM on third monitor at boot

  • From: "Lowell, Timothy" <TLowell@xxxxxxxxxxx>
  • To: <foxboro@xxxxxxxxxxxxx>
  • Date: Fri, 13 Mar 2009 15:44:30 -0500

Thanks to Alex and Terrence for their help.

I was able to get this working after they put me on the right track.  It
wasn't intuitively obvious, so I thought I would share the solution.

Once again, the problem statement is that we have a P92 with a Matrix
Quad Head video card.  This particular P92 only has 3 monitors attached.
We want to have a 2nd FoxView boot up on the second monitor (to the
right of the first) and we want an Alarm Manager that is associated with
the two FoxViews to boot up on the third monitor, which is directly
above the first.

First, you have to configure the dmcfg file to dedicate multiple
FoxViews to the P92.  I knew how to do that already, and you can figure
that out pretty easily from the dmcfg.init file.

From reading B0700AM, I discovered that you can associate more than one
FoxView with an Alarm Manager.  I guess I knew that was possible, but I
had never done it.  This is really helpful in this case.  This allows us
to hit the "Process" button on either FoxView on the P92 to activate the
Alarm Manager, and the button flashes green or red on both FoxViews
based on the status of the Alarm Manager.

Next, create a script in D:/usr/fox/wp/data called 2nd_fv.  It should
look like this:

if [ $DMNAME = $GCLBUG ]
        then
        /opt/fox/wp/FoxView/foxview.exe
        else
        exit
fi

Then you need to edit the fv_cmds file.  At the end of the file, you
need to add a command like this:

dmcmd wp_applic "/usr/fox/wp/data/2nd_fv"

This will allow the second FoxView to boot up.  You can manually
position the FoxView in the second monitor, and under the "View" menu,
you can save its location and size.  So far this is pretty standard for
any multiple monitor system.  The next part is the part I had to
improvise.

After you get the two FoxViews running, you'll need to get the Alarm
Manager running and positioned in the right place.  To do that, create
another script called start_am in D:/usr/fox/wp/data.  It should look
like this:

/usr/local/pref -<dmName> DMCMD "dmcmd rcntalms"
sleep 2
/usr/fox/wp/bin/tools/pos_win "Alarm Manager" -size (your standard
resolution, i.e. 1280x1024) -position 0x-(your standard vertical
resolution, i.e 1024)

where <dmName> is the primary FoxView name.  The minus sign before the
vertical resolution tells pos_win to put the Alarm Manager above the
primary monitor.  You would use a positive number there to go below the
primary monitor, and you would use a number other than 0 for the
horizontal resolution to go left or right of the primary monitor.  If
you had a 4th monitor that was above and to the right of the primary,
and your standard resolution was 1280x1024, you would use 

-position 1280x-1024

I put the "sleep 2" in there just to make sure the Alarm Manager was
running before pos_win tried to position it.  It may or may not be
necessary.

Finally, you add the line

dmcmd wp_applic "/usr/fox/wp/data/start_am"

to the end of fv_cmds, and then reboot, and it should work.

BTW, I tried putting all the commands (open the second FoxView, then
open the Alarm Manager, then position it) in one script, but for some
reason it didn't work, so I split it up into two scripts and it worked
fine.

Tim Lowell
Tesoro Corporation

-----Original Message-----
From: foxboro-bounce@xxxxxxxxxxxxx [mailto:foxboro-bounce@xxxxxxxxxxxxx]
On Behalf Of Johnson, Alex P (IPS)
Sent: Thursday, March 12, 2009 3:23 PM
To: foxboro@xxxxxxxxxxxxx
Subject: Re: [foxboro] AM on third monitor at boot

Tim,

Re: I want the Alarm Manager associated with the primary FoxView to
automatically start at bootup and pop up on the third monitor, which is
positioned directly above the primary monitor.  Can it be done?  If so,
how?

You might play with pos_win. It does what show_win and move_win did
under Solaris. That is it can move and resize windows.

pos_win [-h[elp]] | [-file [filename]] | [title-match-text] [[hostname]
| [-size[WxH]] | [-position[XxY]]]

        - with no args, list windows.

As for a different approach, I think that AMs open on the same screen as
the FV instance to which they are assigned. If that is correct, you
should be able to send the same command that the 'Process' button uses
to the appropriate FV using pref.

/usr/local/pref -<dmName> DMCMD "dmcmd rcntalms"

In either case, you could run the command at reboot.


Regards,
 
Alex Johnson
Invensys Process Systems
10900 Equity Drive
Houston, TX 77041
713 329 8472 (desk)
713 329 1600 (operator)
713 329 1944 (SSC Fax)
713 329 1700 (Central Fax)
alex.johnson@xxxxxxxxxxxxxxxx

 
 
_______________________________________________________________________
This mailing list is neither sponsored nor endorsed by Invensys Process
Systems (formerly The Foxboro Company). Use the info you obtain here at
your own risks. Read http://www.thecassandraproject.org/disclaimer.html
 
foxboro mailing list:             //www.freelists.org/list/foxboro
to subscribe:         mailto:foxboro-request@xxxxxxxxxxxxx?subject=join
to unsubscribe:      mailto:foxboro-request@xxxxxxxxxxxxx?subject=leave
 

Other related posts: