General HydroStatics
Ship Stability Software
Command of the Week
(New or interesting aspects of GHS that you may not know about)

DB Sync
(Requires GHS version 17.00 or later)

(Use the command DB Update to get the latest version of the Data Base software.)

This humble COW is about to introduce an exception to the rule that two GHS sessions must exercise caution if they use DB commands addressing the same Ship (identified by Geometry File name) at the same time.

DB Sync links two or more GHS sessions such that loads are synchronized. That means if you change a tank load in session A, it will show up as the same load in session B -- and any other session using DB Sync on the same vessel.

This command is simple to use, and its theory of operation is not difficult to understand. DB Sync sends out the current load settings (fixed-weights as well as tank loads) via a special Sync file in the Data Base if there has been a change since the last DB Sync was issued. Otherwise, it checks to see if the Sync loads are any different, and if so it updates its loads from the Data Base Sync file.

To make this more convenient, DB Sync macroname creates a macro that you can use from then on instead of issuing the DB Sync command. This may seem like trivial help, which it is unless the macro name is IDLE. The IDLE macro in GHS executes repeatedly, so your loads can become synchronized between two sessions without further issuing of DB Sync commands directly.

For a quick demonstration (if you have the Load Editor module), try doing LOAD (*) EDIT after DB Sync IDLE. Then bring up another GHS session, read in the same Geometry file and issue the same commands.

To make this more practical, the synchronization can be limited to sending or receiving. A session that has done DB Sync IDLE SEND is a master, and one that has done DB Sync IDLE RECEIVE is a slave.

There is no limit to the number of GHS sessions that can be synchronized in this manner, though we do not know why more than two would ever need to be linked. In fact, we're not sure why two would need to be linked. Maybe you have an idea.

Questions, comments, or requests?
Contact Creative Systems, Inc.

support@ghsport.com

USA phone: 360-385-6212 Fax: 360-385-6213
Office hours: 7:00 am - 4:00 pm Pacific Time, Monday - Friday

Mailing address:
PO Box 1910
Port Townsend, WA 98368 USA

www.ghsport.com

Click here for an index to this and previous COWs