Examples Of  Using  RS-485/SDI-12 Instructions

The following examples show how to undertake the various tasks needed to setup and make readings across the RS-485 and SDI-12 networks.

The SDI-12 networks only supports up to 10 instruments with address range: 0 to 9

Changing the ID Number (address)

The following example demonstrates how to change the instrument ID number from the default factory setting 0 to 5.

Use the command ‘aAb’    where a = Start ID  b = Final ID

master sends:  ‘0A5’   Instrument responds 5\r\n    Return New Line   (5 representing new ID number)


ID Number Query
  
This command has been included to remain compatible with the SDI-12 and should be used for used with single instrument operations only. Useful command when identifying ID numbers for instruments to be deployed on a multi-instrument network.

The example below is to show the ID number of a single instrument

Use the command  ‘?!’ .

master sends::  ‘?!’    Instrument responds 3\r\n   Return New Line   (3 is the ID number)

Start Measurements On Distributed Instruments Upon A Network

The following example shows how to start measurements on instruments with ID numbers 2, 7, and 9 respectively.  

For this example the instruments are instructed to start readings one at a time and the network is not freed up until each instrument responds that the readings are being undertaken.

The instruments will start their measurement operations but will not send data across the network until instructed to do so.

Use the command ‘aM!’    where a = Instrument ID Number  

Examples of use.

The following example is based upon a simple application of 3 x VibWire-108 units connected together on a local network.  Unit 1 with address 2 has 4 vibrating wire sensors, Unit 2 with address 7 has 6 sensors connected and finally Unit 3 has only 2 sensors connected.

master sends:  ‘2M!’   Instrument responds          ‘20144\r\n’      indicated readings available after 14 secs
                                                       followed by         ‘2\r\n’                when the measurement is completed

                          7M!                                                    ‘70206\r\n
                                                                                     ‘7\r\n’                 when measurement completed

                           9M!                                                   ‘90082\r\n
                                                                                     ‘9\r\n’                  when measurement completed

Note. For this command the RS-485 network will not become available until each instrument completes its measurement cycle.