Configuring digitisers and digital sensors for dialup access

This “how-to” explains the different ways to connect to a DM24 digitiser (or a sensor incorporating a digitiser module) with modem, as shown in the diagram below.

It does not cover installations including Guralp DCMs, which are much more flexible units with a wide range of possible configurations.

There are two ways to communicate with a DM24 over a modem link:

You can dial in to the waiting sensor and download data, or

the sensor can control its own modem to dial out to your computer.

In either case, while the link is active, you can receive and download data, configure the digitiser and update its firmware, just as if it were directly connected to your computer.

Connecting the modem

The serial cable supplied with Guralp digital instruments is suitable for connecting direct to a PC, and cannot be used to attach the instrument to a modem. You will need to obtain a null modem adapter for the modem’s serial port, which crosses the RS232 receive and transmit lines. These adapters are readily available from electronics suppliers.

Alternatively, you can make up your own adapter with the following pin arrangement:

We recommend that you leave the cable supplied with the instrument as it is, so that you can still attach the instrument directly to a PC.

Dial-in installations

The easiest way to connect a remote installation over a dialup link is to attach a modem to it and dial in when you want to receive data.

To be able to dial in to a digital installation, you need to set up the link so that the call will be answered automatically. Most modems have an auto-answer setting for this purpose. With this setting active, you can dial in to the modem and communications will be forwarded as if over a normal serial link.

Digitiser settings for dial-up links

In addition to the normal output configuration of the digitiser, you will need to choose suitable filing and buffering modes for the dial-up link.

Most installations with intermittent communications use the FIFO, ADAPTIVE, or DUAL filing modes.

In FIFO (first-in first-out) mode, the digitiser will place all the data it produces in Flash memory. Meanwhile, it will attempt to send data from Flash over the modem link in chronological order.Most of the time, this will fail because you are not dialled in. However, when you activate the modem link, Scream! will acknowledge the block as it is sent, and the digitiser will move on to sending the next block until it is up to date.

In ADAPTIVE mode, the digitiser will send the most recent data preferentially, and backfill older data whenever it can. For this to work, the modem link must be fast enough to allow old blocks to be transmitted in addition to all the continuous data that the digitiser produces.

In DUAL mode, continuous streams are sent over the serial link but triggered streams are saved into Flash memory. You could configure a digitiser to output continuous streams at a slow rate (e.g. 4 samples/sec) whilst saving triggered streams at a higher rate (100 samples/sec or more.) Then, when you dial in, you will be able to see current data and check that the instrument is still active, as well as retrieving information about the triggers that have been saved.

Autonomous installations should use Recycle for the buffering mode so that the installation carries on working even if the Flash memory becomes full. You will lose the oldest data, but can carry on downloading as normal afterwards. If you use the Write-once buffering mode and the Flash memory becomes full, the station will stop recording to the Flash memory entirely, and you will need to reset it manually.

To set the filing mode options from Scream!:

Choose File → Setup from the menu bar, and click on the Com Ports tab.
Each row of the table in this window corresponds to one of your PC’s serial ports.

Check that, for the serial port connected to the digitiser, the Baud Rate is set to the correct value, and all four boxes are checked. Click OK.

If the digitiser is shown in Scream!’s main window, right-click on it and select Terminal….
Otherwise, choose File → Terminal from the menu bar, and select the relevant Com Port. Click OK.A terminal window should open.A blank window will appear waiting for you to type in modem commands.

Type

atdt your-digitiser-phone-number

and press ENTER.

If the connection is successful, the modem will reply with a line like

CONNECT 14400 V42
BIS

You are now connected to the instrument, and will shortly see data blocks appearing.

Close the terminal window, to allow Scream! to process the data. An icon for the digitiser should shortly appear beneath the COM port attached to your modem.

Right-click on this, and select Control….

Click on the Data Flow tab to display the window shown above.Select the Transmission Mode and Buffering type you want to use. If you want to change any other control or configuration options, do this now.Alternatively, prepare a text file containing a list of configuration commands you want to execute. An example file is given below. In FORTH, words in brackets are treated as comments, and have no effect on the action of the digitiser.

Copy and paste the text file into the Terminal window. After every command, the digitiser should report the change it has made, and finish with ok. If there are any problems, the digitiser will report them.

Assuming the configuration was successfully uploaded, reboot the instrument by entering the command re-boot Press y to confirm. The digitiser will print out a status message, then close the session.

Right-click on the digitiser’s icon and select Terminal….Type +++ to escape from the digitiser terminal and communicate with your modem.

Type ath followed by ENTER to disconnect the modem and finish the call.

The installation is now set up and active.

Managing dial-in modem links with Scream!

If you have several installations using dial-in links, you can use Scream! version 4 or newer to manage data transfer using modems attached to your local PC.

Click File → Setup… on Scream’s menu bar. Select the Com Ports tab.
You will see a list of all the serial ports available on your computer. This computer has a single serial port, COM3, which is attached to a modem.

Make sure the baud rate and other flags are set up correctly for the modem, and click Dialup. (Scream! detects which ports are connected to modems, and provides a Dialup button only for these ports.)

Enter the telephone number of the remote modem. If you want to contact several remote installations in turn, list their numbers, one per line.

In the right-hand panel, check Every (12) hours, and set the value to 12.

Check the Limit each call to… box, and enter a suitable call length. This is advisable in our example, because the 5TD is configured to output some streams continuously. Scream! will only hang up if it fails to receive any data for a specified length of time.Ensure that you allow enough time in each call to download all the new data given the sample rates and baud rate that you have chosen. For example, if the modem connection can achieve 19200 baud, then a station outputting continuous 200 samples/s data for 3 components would require a continuous connection to collect all the data. If the data rate were only 20sps, then the modem would only need to be connected for 10% of the time (e.g. a 6-minute call every hour.)

If the local modem needs extra commands, you can add these under Additional Modem Settings. Some useful commands are Q1 to enter “quiet mode”; E0 to turn off local echo, and S0=1 to turn on the auto-answering facility. Modem commands normally start with the attention sequence AT; Scream! adds this sequence automatically, so you do not need to enter it in this box.

When all the settings are correct, check the Active box and click Apply to start polling. The Active box is provided so you can temporarily disable polling without losing your settings.

If you have more than one modem attached to your computer, you can set each one up with a different set of numbers and polling times. You might want to do this if

you want to collect data from several stations simultaneously, or

using several modems allows you to reduce call charges (e.g. you might use a cellular modem to contact installations on GSM networks, and a standard modem to contact those on land lines).

You can have up to 99 modems collecting data simultaneously, each with an unlimited number of scheduled dialup times and telephone numbers. Scream! will remember all the settings when you exit.

Viewing data in Scream!

As long as Scream! is running on your computer, it will now dial in to each station in turn at the times you have specified.

Once Scream! has connected to a digitiser, it will download any data that is saved in Flash memory, and display it in its main window.

You can now view these streams or analyse them as normal.

Installations without auto-answer

In some cases, you may decide not to configure the modem to answer calls automatically. The digitiser will then need to listen for and answer incoming calls itself. To tell the digitiser to do this, enter modem mode with the +MODEM command.

If you do not also want to dial out from the installation, you can either

to provide a dummy phone number (so that outgoing calls do not succeed) and set the heartbeat interval to a very large value, or

switch to a filing mode other than FIFO or ADAPTIVE after enabling +MODEM.

See below for more details.

Setting up US Robotics Courier modems

Guralp Systems recommend this model of modem, because you can completely configure its behaviour using dip switches on the underside of the case. Using other modem types, you may have to set the modem link up using AT commands before you will be able to communicate with the digitiser.

The factory-set positions of the dip switches are:

OFF

OFF

OFF

OFF

OFF

OFF

OFF

ON

ON

ON

1

2

3

4

5

6

7

8

9

10

DTR normal

Verbal Result Codes

Display Result Codes

Echo offline commands

Suppress Auto Answer

Normal CD

Display all result codes

Enable AT Commands

Disconnect with +++

Load NVRAM settings

To configure the Courier for use with GSL digital instruments, set the switches as below:

OFF

OFF

OFF

ON

ON

ON

ON

1

2

3

4

5

6

7

8

9

10

DTR Always on

Not significant

Suppress Result Codes

No Echo, offline commands

Auto Answer

Not significant

Not significant

Disable AT Commands

No Disconnect with +++

Load &F0 settings

Dial-out installations

The Guralp DM24 mk3 digitiser can also control its own modem and dial out to a waiting computer. This is done using a special mode. To enter modem mode from the digitiser terminal:

Set the heartbeat interval of the digitiser. When you are in modem mode, the digitiser will dial out at intervals equal to the heartbeat interval. Use HEARTBEAT to set the interval in units of 30 ms, or HOUR HEARTBEAT to set it in units of hours. For example:

If you have not already set up a telephone number to call, the digitiser will ask Phone# is not set Enter phone#. Enter the telephone number in a format that the modem will be able to use to contact your computer. Depending on your location, you may need to use regional or international dialling codes.If the digitiser already has a telephone number configured, it will ask Phone# old-telephone-number New number? y/n. If you want to change the setting, answer with y and provide the new number.The digitiser will automatically switch to the FIFO data mode, so that data will be saved to the Flash memory whilst the modem link is inactive.If you want, you can switch to ADAPTIVE mode at this point. If you enter any of the other filing modes, the DM24 will not dial out. However, you can still dial in, and the digitiser will automatically answer calls if the modem has not already done so (see above.)

Configure your local modem to answer calls automatically.

Start Scream!, and set up the serial port on your local modem with the correct baud rate. Check all four checkboxes.

When the heartbeat interval passes, or when the digitiser triggers, it will dial the number you have configured, and your modem will answer. The digitiser will then immediately send a heartbeat message with status information.

After this, the digitiser will start sending all the data it has saved to Flash memory whilst the link was inactive. If it is in FIFO mode, it will send this data in the order it was generated; if in ADAPTIVE mode, the data will be sent in addition to continuous (new) data as bandwidth permits.

When there is no more data waiting to be transmitted, the digitiser will close the connection. If you close the connection or it is interrupted, the digitiser will automatically attempt to redial.