vision oplcs and modems - klinkmann - provider of...

107
Vision OPLCs and Modems 3/2010 www.klinkmann.com

Upload: phamlien

Post on 12-Mar-2018

242 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems 3/2010

www.klinkmann.com

Page 2: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 3: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

The information in this document reflects products at the date of printing. Unitronics reserves the right, subject to all applicable laws, at any time, at its sole discretion, and without notice, to discontinue or change the features, designs, materials and other specifications of its products, and to either permanently or temporarily withdraw any of the forgoing from the market.

All information in this document is provided "as is" without warranty of any kind, either expressed or implied, including but not limited to any implied warranties of merchantability, fitness for a particular purpose, or non-infringement. Unitronics assumes no responsibility for errors or omissions in the information presented in this document. In no event shall Unitronics be liable for any special, incidental, indirect or consequential damages of any kind, or any damages whatsoever arising out of or in connection with the use or performance of this information.

The tradenames, trademarks, logos and service marks presented in this document, including their design, are the property of Unitronics (1989) (R"G) Ltd. or other third parties and you are not permitted to use them without the prior written consent of Unitronics or such third party as may own them.

Page 4: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 5: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

v

Table of Contents About Modems and Unitronics OPLCs ................................................................ 7�

Before you begin: Modem Tips....................................................................... 7�Modem Connection and Pinouts ..................................................................... 9�Connecting a Controller to a Modem ............................................................... 9�Modem to Controller Interface (DCE to DTE) ................................................... 9�Using Modem Kits ...................................................................................... 10�Using a Unitronics Adapter .......................................................................... 11�Constructing Adapters ................................................................................ 11�

PC-Side Modems (Modem Services) ................................................................ 13�Initializing a PC-side Modem (Prepare Modem) .............................................. 13�Modem Service Options .............................................................................. 14�How to use the PC modem to access a PLC ................................................... 15�

PLC-side Modems ......................................................................................... 17�How to enable a controller to communicate via landline or GSM/GPRS modem .. 17�How to enable a PLC to dial a remote modem (Ladder) ................................... 20�

Landline modems ................................................................................... 20�How to terminate the link--Hang-up ............................................................. 21�

Last Call, CLIP: Identifying Callers .................................................................. 23�The process ............................................................................................... 23�The application .......................................................................................... 24�Preventing unauthorized calls ...................................................................... 24�

Dial & Hang-up ............................................................................................ 27�Dialing from the Controller's Keypad ............................................................... 29�

Initializing the COM port .......................................................................... 29�Building the Cursor ................................................................................. 30�Entering numbers: 'Convert' to ASCII ....................................................... 31�Placing entered numbers in the Phone Number vector ................................. 32�Dial and Hang-up ................................................................................... 33�

Accessing a Networked PLC via PC .................................................................. 35�Accessing a Networked Controller via Modem ................................................ 35�Modems: Setting Up ................................................................................... 35�

Online Test Mode & Remote Access........................................................... 37�COM Port/Modem Status, System Operands, & Error Messages .......................... 39�Modem Troubleshooting ................................................................................ 43�

Cable Pin-out ......................................................................................... 45�Data Flow Direction ................................................................................ 45�RS-232 signal information ....................................................................... 45�

Modem Troubleshooting Table ..................................................................... 46�Using Hyperterminal to check PC-PLC direct communications ............................. 49�Using Hyperterminal for COM Troubleshooting.................................................. 53�

Modem Connections ................................................................................... 53�

Page 6: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

vi

Cable Pin-out ......................................................................................... 53�Data Flow Direction ................................................................................ 53�RS-232 signal information ....................................................................... 53�

Using Hyperterminal ................................................................................... 53�Modem Commands..................................................................................... 56�Initializing the modem to SMS mode via Hyperterminal .................................. 57�When a controller sends an SMS text message .............................................. 57�'The Sniffer'--Viewing communication strings ................................................ 58�

GPRS ............................................................................................................ 1�Using GPRS ................................................................................................. 2�Downloading OS via GPRS............................................................................. 3�FB Operations .............................................................................................. 3�Examples .................................................................................................... 3�

GPRS Configuration ........................................................................................ 5�GPRS Register to Network ............................................................................... 7�GPRS Run ...................................................................................................... 9�Start Call, End Call ....................................................................................... 11�

Start Call .................................................................................................. 11�End Call .................................................................................................... 11�

Listen to Remote Device, Stop Listening to Remote Device ................................ 13�Listen ....................................................................................................... 13�Stop Listening ........................................................................................... 13�

Unregister from Network ............................................................................... 15�Check Signal Quality ..................................................................................... 17�GPRS Operands & Status Messages ................................................................ 19�Using SMS Messaging ..................................................................................... 1�

FB Operations .............................................................................................. 1�How to Configure, Receive, and Send Messages ............................................... 1�Examples .................................................................................................... 4�

SMS: Configuration ......................................................................................... 5�Creating SMS Messages & Variables ............................................................... 5�Message Properties ...................................................................................... 7�Phone Book ................................................................................................. 8�

SMS Configuration and the Program Scan ........................................................ 11�SMS: Scan ................................................................................................... 13�SMS: Send .................................................................................................. 15�SMS Variables .............................................................................................. 19�SMS: Check GSM Signal Quality ..................................................................... 21�Sending SMS messages from a GSM cell phone ................................................ 23�

Writing SMS messages in your cell phone ..................................................... 23�Sending the message to the PLC .................................................................. 23�Checking that the PLC has received the SMS message .................................... 23�

Index .......................................................................................................... 25�

Page 7: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

About Modems anUnitronics' controllers can bvia the RS232 COM port. Unbeen tested by Unitronics aPLCs.

You can link a Vision PLC to

MODBUS (serial) commaVisiLogic's Communicatiocommunicate data with mand frequency converterSMS messages. The SMSbe sent and received viae-mail via GPRS (EnhancGPRS cellular network, t

You can use a PC modem toperform any task, just as yoFor example, you can:

Dial a remote PLC modeDownload, upload, and eRun Online test mode.

Download an OS to the cUse OnLine test and Infocontrollers and applicatioRead and write data to/fcommunication .dll utilitiReceive and send SMS m

Before you can use Services to initializThis process is descr

Before you begin: ModeNotes � The PC-modem

between the conconnect the PC tmodem's pins.

� If calls are routemay interfere wprovider.

� If, within the moto permit the PLFor example, if tfor 3 seconds tomodem does noparameter is exc

nd Unitronics OPLCsbe hooked up to PSTN (landline), or GSMnitronics provides kits that comprise mond are supported for use with Vision, Ja

a modem and enable it to communicat

ands.on Protocol FB, which enables Vision comost external serial devices, such as bars, via their proprietary protocols.S FB enables text messages, including v

GSM modems.ced Vision only).o transmit IP packets of data.

o access a remote, modem-linked Unitrou would if the PLC were directly conne

m and receive calls from a PLC.edit the controller program via the mod

controller via modem.ormation Mode to troubleshoot problemons.from controllers via Remote Access or Uies.

messages via SMS options.

modems in your application, you musze both the PC and PLC-side modemribed beginning on page 13.

em Tipscable is not the same type of cable use

ntroller and the modem. Ensure that theto the modem provides connection poin

ed via a switchboard, note that the switith communications. Consult with your

odem initialization strings, the parametLC's modem to answer, an error will resthis parameter is set as S7=30, the PC receive an answer from the PLC's mod

t answer before the 3 seconds have elaceeded, and the PC modem returns the

7

M/GPRS modems odems that have azz, and M90/91

te data using:

ontrollers to ar-code readers

variable data, to

onics PLC and ected to your PC.

em connection.

ms in remote

Unitronics'

st use Modem ms.

ed to connect e cable used to nts for all of the

tchboard settings switchboard

ter S7 is too short sult.

modem will wait dem. If the PLC apsed, the S7=30 e No Carrier error.

Page 8: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

StandardControllercan conne184 TX Sutransmissto the moEnhanceControllerport. EachCOM1: SB188 and S

When workingSet the ba57600. Inthe baud Com Init:- Select Ig- Time Ou

� Known compatibUnitronics produModems:

Model GT4Model GM

Unitronics cannoSony Ericsson M

d Vision Divisionrs in this division can only support a sinect a modem to any COM port. Howeveuccess and SB 185 TX Failed indicate msion status regardless of the actual COodem.d Vision Divisionrs in this division can support a modemh port is linked to a Succeed and Fail SBB 184 and SB 185, COM2: SB186 and SSB 189.

g with V570 and V290 (color):aud rate in both Modem Services and inn addition, run the Prepare PLC Modem rate set to 57600.

gnore Breakut Reply: set to a minimum of 6 secondbility issue: Sony Ericsson Modems.ucts are compatible with the following S

47 R5xxxx and higherM29 R6xxxx and higherot guarantee compatibility with other m

Modem model GM29 R4xxxx.

8

ngle modem. You r, note that SB

message OM port connected

on each COM B:SB 187, COM3: SB

n COM Init to procedure with

s.

Sony Ericsson

models, such as

Page 9: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Modem Connection andThe following figure shows y

Note � The programmingVision all-in-one ki

Below is the pinout diagram

Connecting a Controlle

Unitronics' modem Use with a UnitronicsKits contain a modemrelated hardware. Thedescriptions and spec

Other modems -Use a Unitronics PLCadapter. You can orde-Construct your own programming cable toprovided below.

Modem to Controller InThe next figure shows the in(DCE; the modem) and the The arrows show the direct

Transmitted data (TXReceived data (RXD)

Modem Co

d Pinoutsyou how to connect a controller to a mo

cable is a 4-wire cable. The cable is its.

m for the PLC RS232 port.

er to a Modem

kitsPLC programming cable, as shown in t

m that is compatible with Unitronics cone Products section of the Unitronics wecifications.

C programming cable to connect the PLCer modem adapters from Unitronics.D-type to D-type connector cable to coo the modem's serial port, according to

terface (DCE to DTE)nterface between the Data CommunicatData Terminal Equipment (DTE; the co

tion of data flow. Note that:

XD) is input to the modem, output from is input to the PLC, but output from th

onnection and Pinouts

9

odem.

included with the

the figure above. ntrollers and b site contains kit

C to a modem

onnect the o the pin-outs

tions Equipment ontroller or PC).

the PLCe modem

Page 10: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

Note � Unitronics controlle� Modems must be i

procedure. This prTurns the DSets the appare: 19200

� Connecting DSR antransmit\receive d

Using Modem Kits Kits contain all of the elemethe appropriate PLC programbeginning of this section.

Note that you must removeadapter from the PLC progracable and replace it with theadapter supplied in the kit.

In order to work with Unitroprocedure detailed in the Pr

The following list shows moFor updated information, co

Standard Landline and Siemens GS

Modem Adapter MJ10-22-CS76Adapter signals D-Type 9DSR (out) + RTS (in)

6+7

GND 5RXD (out) 2TXD (in) 3GND 5DCD (out) 1

Note � The cable connect

ers do not support all the control lines.nitialized via the Modem Services> Pre

rocedure:SR signal ONpropriate PLC-modem communication pbps, 8 bit, no parity, 1 stop bitnd RTS signals causes the modem to beata.

ents you need to connect a controller tomming cable, as shown in the first figur

the PC amming e modem

onics controllers, you must initialize therepare PLC Modem topic.

dem adapters supplied with the kits anonsult your Unitronics distributor.

M/GPRS modems

6 PLC Serial Port /pin, male RJ11 RJ11

1 6

2 53 44 35 26 1

ts RJ11 pins 2,3,4,5 to pins 5,4,3,2 resp

10

epare Modem

parameters. These

e always ready to

o a modem usingre at the

e modem via the

d their pin-outs.

/ Port ModuleController signals DSR (in)

GND RXD (in) TXD (out) GND DTR (out)

pectively.

Page 11: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Modem Connection and Pinouts

11

Sony Ericsson GM29 and Enfora GSM/GPRS modems

Modem Adapter MJ10-22-CS72 PLC Serial Port / Port Module Adapter signals D-Type 9 pin, male RJ11 RJ11 Controller signals DSR (out) 6 1 6 DSR (in) GND 5 2 5 GND RXD (out) 2 3 4 RXD (in) TXD (in) 3 4 3 TXD (out) GND 5 5 2 GND DCD (out) + RTS (in)

1+7 6 1 DTR (out)

Note � The cable connects RJ11 pins 2,3,4,5 to pins 5,4,3,2 respectively.Wavecom GSM/GPRS modems

Modem Adapter MJ10-22-CS79 PLC Serial Port / Port Module Adapter signals D-Type 15 pin, male RJ11 RJ11 Controller signals DCD (out) 1 1 6 DSR (in) GND 9 2 5 GND RXD (out) 6 3 4 RXD (in) TXD (in) 2 4 3 TXD (out) GND 9 5 2 GND DSR (out) + RTS (in)

7+12 6 1 DTR (out)

Note � The cable connects RJ11 pins 2,3,4,5 to pins 5,4,3,2 respectively.� Wavecom modem kits do not contain the PC to modem cable, MJ10-22-

CS32, that is required for the Wavecom Prepare Modem procedure. This cable is available by separate order.

Using a Unitronics Adapter If you are using a modem from an independent source, you can order one of the modem adapters described in the preceding section from Unitronics, and use this adapter to connect your modem to the PLC via the PLC programming cable.

Constructing Adapters You can construct a D-type modem adapter yourself, using the appropriate pin-outs shown in the preceding section.

You can also construct a cable with 2 male D-type connectors, and then use it to connect a modem's serial port directly to the PC adapter on the PLC programming cable as shown in the next figure.

The tables below give the pin-outs of the programming cables, and show you an example of the pin connection you can use to construct a cable with 2 male D-type connectors to connect a PLC to a standard landline modem.

Page 12: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

12

Vision 4-wire Programming Cable

PC -side Adapter MJ10-22-CS25

PLC-side Programming port

PC signals

D-Type 9 pin, female

RJ11 RJ11 Controller signals

DTR (out) 4 1 6 DSR (in) Unused GND 5 2 5 GND TXD (out) 3 3 4 RXD (in) RXD (in) 2 4 3 TXD (out) GND 5 5 2 GND DSR (in) 6 6 1 DTR (out) Unused

Note � The 4-wire programming cable supplied with the controller connects RJ11 pins 2,3,4,5 to pins 5,4,3,2 respectively.

Example: D-type modem adapter cable to connect a Vision controller to a standard landline modem Modem-side (D-type 9-pin, male)

PLC-side (D-type 9-pin, male)

DSR (out) + RTS (in)

6+7

GND 5 5 GND RXD (out) 2 3 RXD (in) TXD (in) 3 2 TXD (out) GND 5 5 GND

Page 13: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

PC-Side Modems Modem Services enables yohave configured a PC-side mmodem-linked controller andirectly connected to your P

Download, upload, anconnection.

Run Online test modeDownload an OS to thUse OnLine test and Icontrollers and applicRead and write data tcommunication .dll ut

Before integrating modems Cautions.

Initializing a PC-side Mo1. Connect the modem t

pinout, either suppmanufacturer.

Note that using acause the process to

2. Open Modem Service

3. Select and enter the

a. At the top of Mbox shows the

b. Select the PC maccordingly. Sethat appear in

c. If required, you

Initialization commanCom Port, baud rate, boxes

PIN code: click to ent4. When all parameters

establishes communic

(Modem Services)u to initialize modems for both PC and

modem, you can use a PC modem to acd perform any task, just as you would

PC. For example, you can:

nd edit the controller program via the m

e.he controller via modem.Information Mode to troubleshoot probcations.to/from controllers via Remote Access otilities.into your applications, check the sectio

odem (Prepare Modem)to a PC, using a cable comprising the

plied in the modem kit or supplied b

a cable that does not comprise the full Rfail.

s from the Connection menu.

modem parameters:

Modem Services, select a tab; the Modeoptions.

modem type; the initialization strings chelecting TAPI displays the settings of teWindows>Control Panel>Phone and Mo

u can edit other parameters:

nds: click in the field and enter text. Time Out, and Time-Out Reply: use th

ter the number.are set, click the Initialize PC Modem bcation with the modem and initializes it

13

PLC. Once you ccess a remote, if the PLC were

modem

lems in remote

or Unitronics'

on Modems-Tips &

e full RS232 by the modem

RS232 pinout will

m Type selection

hange elephony devices odem Options.

he drop down

button; the PC t.

Page 14: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

14

Modem Service Options In addition to modem initialization, Modem Services offer other options:

Option Description

Dial & Hang-Up

To dial: � Click the Number to Dial field; the Favorites list opens. � Enter or highlight the desired number. � Close Favorites, and click Dial. � To break the data link, click Hang-Up.

Dial Mode Selecting Auto enables the modem to adapt to the signal provided by the telephony service operator.

SMS Options This option is available if you have selected a GSM modem. � Select the destination number. � Enter the SMS text, then click Send SMS. � Note that an SMS can be used to cause the PLC to call the PC.

Wait for Incoming Call

Places the PC modem in auto-answer mode.

Prepare PLC Modem

Use this option to initialize a PLC-side modem. Full instructions are in the topic PLC-side Modems.

Page 15: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

PC-Side Modems

15

How to use the PC modem to access a PLC 1. Prepare and connect the PLC-side modem as described in the topic PLC-side

Modems, in the section 'How to enable a controller to communicate via landline or GSM/GPRS modems.

2. Dial the PLC to establish the communication link:

a. Favorites (Telephony). You can keep a list of frequently-used numbers in Favorites.

b. Click a line to enter or select a number and description.

c. To access outside lines, enter the access number required, a comma, and then the phone number.

Click Dial to establish the data link, then enter OnLine mode.

You can now perform any task that can be performed via a direct PC-PLC connection. Note that when the modem is connected, the Modem Connected icon appears on screen.

Page 16: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 17: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

PLC-side ModemsBefore integrating modems Cautions.

How to enable a contromodem Preparing the modem as deUnitronics PLCs.

1. Connect the modem tpinout, either suppmanufacturer.

Note that using acause the process to

2. Prepare the PLC mod

a. Connect the mmanufacturer.

b. Open Connectirequired, you c

Com Port, Baud Rateboxes.

Enhanced Vision Recommended B

PIN code: click to ent

3. Click the Prepare PLC

4. If required, edit initiatext.

5. When all parameters communication with t

sinto your applications, check the sectio

oller to communicate via landline

escribed below initializes it so that it is c

to a PC, using a cable comprising theplied in the modem kit or supplied b

a cable that does not comprise the full Rfail.

em.

odem to a PC, using the cable supplied

on>Modem Services, and select the mocan edit other parameters:

, Time Out, and Time-Out Reply: use th

Division:Baud Rate is 57600.ter the number.

C-side Modem button; that dialog box o

alization commands by clicking in the fie

are set, click the Init Modem button; ththe modem and initializes it.

17

on Modems-Tips &

or GSM/GPRS

compatible with

e full RS232 by the modem

RS232 pinout will

by the modem

odem type. If

he drop down

pens.

eld and entering

he PC establishes

Page 18: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

18

6. Initialize the PLC port using a COM Init FB, located on the COM menu.

Page 19: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

PLC-side Modems

19

Parameter Name

Purpose

Com Port Select the physically linked Com Port.

Baud Rate Set the baud rate in COM Init to 57600:

When working with V570 and V290 (color) When working with V120/230/260/280/290 (monochrome) together with modems Enfora orTC65 In all other cases, 9600 is suitable.

RS232 Time Out

This is the time that the PLC will wait for the modem to reply.

Flow Control This is generally left OFF.

Ignore break When working with V570 and V290 (color), select Ignore Break

Modem Settings

Modem Type Click to select the desired modem.

Initialization strings

Click to edit if required.

Dial Type Set to Tone by default.

Time Out Reply When working with V570 and V290 (color), set a minimum of 6 seconds.

PIN Code If your provider requires a PIN code, enter a constant number or link to MI.

Clear SIM Select this to clear the SIM card when COM Init is activated.

Notes ♦ COM Init is generally performed once in a program. It is usually a power-up task, however a one-shot transitional contact may also be used.

♦ The initialization commands must match the commands used to initialize the PLC modem.

♦ You can cause the modem to delay between initialization commands by typing WAIT, followed by the number of seconds; up to nine seconds is supported.

Page 20: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

20

♦ Communications cannot flow through the port during initialization.♦ The PLC cannot answer incoming calls when it is in bootstrap mode.♦ The Answer Settings parameter, by default, enables the modem to answer

incoming calls. This enables you to download an OS to the PLC via modem. However, you can enable the PLC to answer instead. To do this, locate the initialization string ATS0=1 and enter 0( ATS0=0). When ATS0=0, an OS cannot be downloaded.

1. Build a Ladder program containing the correct conditions and elements.

Note � Communications cannot flow through the port during initialization. To avoid conflicts in your program, use COM Port initialization SBs 80-85.

♦ COM Init may take approximately a minute to complete.

2. Download the application to the PLC.

3. Connect the modem to the PLC.

After the modem is enabled and successfully initialized by the PLC (SBs 80, 82, 84 turn ON), the controller can either be accessed via modem or can dial a remote modem to establish a data link.

How to enable a PLC to dial a remote modem (Ladder) Landline modems

Note ♦ In the conditions used to activate the Dial function, include the appropriate Modem Initialized System Bit: SB 80, SB 82, or SB 84.

Page 21: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

PLC-side Modems

21

For more information regarding Ladder conditions and other details, refer to the topic Dial and Hang-up.

GSM modems

Note ♦ SMS operations can conflict with applications that use the modem for other data communication processes. To prevent conflicts, use the Modem Busy (GSM) MB, and use an MB to indicate when the modem is in use by another data communications process.

For more information on SMS messaging, refer to the SMS topics.

How to terminate the link--Hang-up This enables you to use Ladder conditions to break the connection.

Note ♦ Before activating Hang-up, check whether the connection exists, via the appropriate Modem Connection Status System Bit: SB 86, SB 87, or SB 88

Page 22: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 23: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Last Call, CLIP: IdThe Last Call Received functfunction enables a PLC to iduses the CLIP (Calling Line Imodems.

CLIP is supported by:Enhanced Vision: from O/S 42

Standard Vision: from O/S 500-19

VisiLogic versions 5.15 and later, which contain the CLIP command: AT + CLIP=1.

You can use CLIP to identify

Using the Last Call furegister

Creating a list of authUsing the Find Row fu

To see a working example, (CLIP).vlp.

The process The PLC must be connected

1. Device modem calls a2. PLC Modem sends the

PLC, containing the CType (local or interna

3. PLC retains the data, CLIP - Caller NumberNote that SB89 must

4. The Last Call functionnumber into a vectorapplication, a Data Tasearches for a matchTable. If no such numapplication can breakactivating COM Init.

entifying Callerstion is located on the COM> COM Port>

dentify the caller number of an incomingIdentification and Presentation) feature

y callers to a PLC modem by:

nction to write the number of an incom

horized numbers in a Data Tableunction to check if that number exists icheck the sample application GSM - Pre

d to a GSM modem.a PLC modem. e CLIP command to the

Caller Number and Call ational) to the PLC.

and turns ON SB89 r is here.

be reset by the user. n stores the caller . In the Ladder ables Find Row function ing number in the Data

mber exists, the k the connection by

23

> menu. This g call. Last Call e offered by GSM

ming call to a

n the Data Tableevent Illegal Calls

Page 24: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

The application Notes ♦ Last Call can st

V570/290V120/230connecte

♦ If the call numbor anonymous)most cases, Las

The ladder net that is shownmodem receives a call from

SB89 turns ON when The Last Call Receivestarting at MI10

Find Data Table Row If no such number exists, F

Reset SB 89 in the applicatiSB 89 is not reset, you will be able to write new CLIP dPreventing unauthorizeThe nets shown below guard

If the caller number i-1,

OR

If the call number is uanonymous), 0 will b

In either case, MB1 will turn

ore the number when:0 (Color): the modem begins to ring0/260/280/290 (monochrome): the cal

ed.

ber is unidentifiable (meaning set by th, no number will be stored in the Last Cst Call will identify such a call as Type =

n below causes the following events wha remote modem:

caller number is present ed element copies the caller number into

looks up that number in the Data TableFind Row returns a value of -1.

on. If not ata

ed callsd against unauthorized callers:

s not in the list, the Find Row output, M

unidentifiable (meaning set by the callee stored in the Last Call vector startingn OFF, breaking the connection by activ

24

ll is actually

e caller as private Call vector. In =128.

hen the PLC's

o a vector of MIs

e.

MI21, will contain

er as private or at MI 10

vating COM Init.

Page 25: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Last Call (CLIP): Identifying Callers

25

Page 26: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 27: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

27

Dial & Hang-upThese functions are located on the Com menu. Via the Ladder application, they enable a PLC connected to a modem to establish or terminate a data link to another remote modem.

Before you dial, you must enable the Vision controller to communicate via modem.

DialThis enables you to use Ladder conditions to dial a modem.

Notes ♦ In the conditions used to activate Dial, include the appropriate Modem Initialized SB: 80, 82, or 84

♦ SMS operations can conflict with applications that use the modem for other data communication processes. To prevent conflicts, use the Modem Busy (GSM) MB, and use an MB to indicate when the modem is in use by another data communications process.

Hang-upThis enables you to use Ladder conditions to break the connection.

Note ♦ Before activating Hang-up, check connection status via a Modem Connection SB: 86, 87, or 88.

Page 28: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 29: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Dialing from the CIf your controller is hooked controller's keypad. This exinstalled on your hard disk tthe Help menu, click Examp

About the Application

When downloaded, this app

Displays a blinking cunumber by pressing k'Converts' the entereentered, into a vectorvector. One ASCII chA Transpose function copies the low byteconsecutive bytes oVector. For example, 1011,1012, 1013 & 1Displays the numbersString, which displaysThe character Carriagthe final character in entering the number as the final characterFinally, the number ucontained in the vectvector.

Note ♦ In order to understanVector: Fill (Offset) an

Ladder

Initializing the COM port The application is based on connection is via COM 2.

The net shown below is the initialized, SB 82 Modem InDial function in the next sub

Controller's Keypadup to a modem, a phone number may planation is based on a sample applicattogether with VisiLogic. To open this apples, and then select Dialing via Vision

lication:

ursor on-screen. This aids the user in ekeys on the Vision keypad.d numbers to ASCII, then saves them, r of registers that starts at MI 1011, tharacter is entered into the low byte of eis linked to the vector starting at MI10of each register in that vector, and stor

of a vector that starts at MI 1001, the PTranspose can extract the low bytes fr

1013 and store all 4 bytes into MI 1001 s as they are entered, via the HMI varias the Phone Number vector starting at ge Return (ASCII value 13) is required the number to be dialed. When the useand presses Enter, the Carriage Return

r in the vector that provides the phone us dialed via a Dial FB. The FB dials the or of registers starting with MI 1001, P

nd how this application works, you must be fand Vector: Transpose functions.

the Wavecom GSM modem. The Vision

first net of the main program module. itialized: COM 2 turns ON; this conditiobroutine, Enter Phone Number.

29

be dialed from the tion that is pplication, open n Keypad.

entering a phone

as they are e Phone Entry each register.

011. Transpose res it into the hone Number

rom MI and 1002.

able Display ASCII MI 1001.by the modem as er has finished n value is stored number.number hone Number

amiliar with the

n-to-modem

When COM 2 is on activates the

Page 30: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

30

Building the Cursor The ASCII values for 'underscore' and 'blank space' are alternately stored into MI 1008 at .5 second intervals. The current value is copied into the Phone Entry vector starting at MI 1011, via a Vector: Fill Offset FB.

The offset value is provided by a counter that increments after every number entered. The offset values ensures that the cursor value is included as the last character in that vector.

Every time a value is entered, Vector: Transpose copies the low bytes of the Phone Entry vector, which contains the ASCII values, to the Phone Number vector starting at MI 1001.

Page 31: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Dialing from the controller's keypad

31

Entering numbers: 'Convert' to ASCII When a key is pressed, its value is automatically stored into SI 6. In this application, whenever keys 0 to 9 are pressed, the value stored in SI 6 is 'converted' to an ASCII value by adding the constant value 8. The ASCII value can then be displayed. For example, if Key#4 is pressed, the value in SI 6 will be 44 (HEX 2C). Adding 8 'converts' the value to 52 (HEX 34), which is the ASCII value for 4. 4 can then be displayed on the screen.

Note ♦ MI 1010 is incremented whenever a legal value is entered. The incrementing value acts as a pointer, correctly placing entered numbers in the Phone Number vector.

Page 32: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

32

Placing entered numbers in the Phone Number vector Using the incrementing value of MI 1010 as a pointer, the Fill Vector function places each 'converted' number into the correct register in the Phone Entry vector, starting at MI 1011.

Via the Transpose function, the low byte of each register in the Phone Entry is copied into the Phone Number vector as shown in the figure below.

Page 33: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Dialing from the controller's keypad

33

Dial and Hang-up The Dial function is linked to the Phone Number vector starting with MI1001. This vector is also displayed on the controller's screen.

Note ♦ Since the Enter key is pressed when the user has finished entering the number, SB 53 is used as one of the Dial conditions, as is SB 82 Modem Initialized.

SB 87 Modem connected is used to activate the Hangup function, and to display text on the controller screen.

HMI Display

This application contains 1 display with 3 variables.

Disconnected\Connected: Binary Text variable

Page 34: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

34

Show the phone number: Display ASCII String

This variable is refreshed in the Ladder via MB 1000 Display String on HMI.

Save, Dial, Hangup?

While the number is being entered, the text Save will be displayed. Once the number has been entered, the status of SB 87 Modem connected determines whether Dial or Hangup will be displayed.

Page 35: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

35

Accessing a Networked PLC via PCUse a PC to access controllers within a network either via a direct connection, TCP/IP connection, GSM or landline modem.

Accessing a Networked Controller via Modem

Note ♦ In order to ensure successful operations, it is recommended that you use

an external PC modem. Internal modems may not support communications.

♦ Both PC and controller must use the same type of modem: either landline or GSM. Internal PC modems must be used in conjunction with the driver provided by the modem's manufacturer.

Modems: Setting Up PLC-Modem Connection

The Unitronics� cable provided with modem kits does not provide a standard connection. This connection is adapted to support the fact that Unitronics controllers do not support the control lines. The cable shorts the DSR and the DTR together, which ensures that the terminal is always ready to receive data. For more information, refer to the topic Modem Connection and Pinouts.

Page 36: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

36

PC Modem Configuration

Open PC Modem Configuration from the Options menu.

Note ♦ If, within the modem initialization strings, the parameter S7 TimeOut, is to short to permit the PLC's modem to answer, an error will result.

Page 37: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Online Test Mode & Remote AYou can run Online Test monetworked controller on you

To do this, click the Online Tbutton.

The controller model that isConfiguration.

During a Remote Access ses

Use your cursor to opobjects (relevant modUse your PC keyboardfunction keys <F1> tPC keyboard, and thaEnter Information Mo

Accessing a N

Accessode and use Remote Access session to dur PC screen.

Test button on the toolbar, then click th

shown on the display is the one select

ssion, you can:

perate the controller keypad and activatdels).d to operate the controller keypad (numo <F8>). Note that the Vision <ESC> k

at <F9> is reserved for activating Onlinode by pressing the <i> key with your c

Networked PLC via PC

37

display the

he Remote Access

ed in Hardware

te touch-screen

meric keys, key is <E> on the

ne mode.cursor.

Page 38: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 39: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

39

COM Port/Modem Status, System Operands, & Error MessagesYou can check the status of the System Bits and Integers either via ON-line Test Mode or Information Mode.

COM Port/Modem initialization, SBs 80-85

Each port is linked to 2 SBs indicating COM Port/Modem initialization status following COM Init. Both SBs are initialized to OFF by the OS, at Power-up and at the beginning of COM Init process. When COM Init is complete, one is ON, the other OFF.

# Description

SB 80 Modem Initialized: COM Port 1 Example: COM Port 1

SB 81 COM Port/Modem Initialization Failed: COM Port 1 SB 80 SB

81

SB 82 Modem Initialized: COM Port 2 0 0 After Power-up, before COM Init

SB 83 COM Port/Modem Initialization Failed: COM Port 2

0 1 Modem Initialization attempt failed, Modem is not initialized

SB 84 Modem Initialized: COM Port 3 1 0 Modem Initialization attempt succeeded, Modem is initialized.

SB 85 COM Port/Modem Initialization Failed: COM Port 3 1 1 Not possible

Modem connection status, SB 86-88

Each port is linked to an SB indicating modem connection status. These can be used in conjunction with SBs 132-137, which indicate indicating whether incoming or outgoing data is flowing through the port, to troubleshoot problems as shown in the Help topic Modem Troubleshooting.

# Description Turns ON when: Turns OFF when: Reset by:

SB 86 Modem Connection Status: COM Port 1

PLC receives 'Connect' string from modem

Hang-up PLC receives string 'No Carrier' PLC receives break signal

OS, at Power-up

SB 87 Modem Connection Status: COM Port 2

SB 88 Modem Connection Status: COM Port 3

COM Ports, SBs 132-137

Each port is linked to 2 SBs indicating when incoming or outgoing data is flowing through the port. To troubleshoot problems, use these in conjunction with the Modem Connection Status SBs 86-88, as shown in the topic Modem Troubleshooting.

# Description Turns ON when: Turns OFF when: Reset by:

SB 132 COM Port 1, Data Transmission During data send When data is not being sent

OS

SB 133 COM Port 2, Data Transmission

SB 134 COM Port 3, Data Transmission

SB 135 COM Port 1, Data Receive During data reception

When data is not being received

OS

SB 136 COM Port 2, Data Receive

Page 40: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

40

SB 137 COM Port 3, Data Receive

SMS message transmission status, SBs 184-185

Operands that are linked by the user to SMS FBs may be found in the topic SMS Operands.

SB Description Turns ON when: Turns OFF when:

184 SMS: Transmission Succeeded Transmission succeeds Transmission begins

185 SMS: Transmission Failed Transmission fails Transmission begins

COM Port: Port/Modem Status, Error codes, SIs 80-85

Each COM Port is linked to 2 SIs; their values and messages are indicated below.

SI 80 Modem Status: COM 1 Error (SI 81,83,85,) Status ( SI 80, 82, 84)

Value Message Value Message

0 No error 0 Modem Idle

1 TimeOut exceeded: no reply 1 Initialization in Progress

2 Reply Error 2 Initialization OK

3 Wrong PIN number 3 Initialization Failed

4 Registration failed 4 Modem Connected

5 PUK number needed 5 Hang-up in progress

10 COM Busy 6 Dial in progress

11 Reply Busy

12 Reply No Dial

15 Attempted Initialization during active break signal. Note that a port cannot be initialized while the break signal is active

16 Error in reply to PIN number

17 Check: CREG failed

18 Check: CREG timeout

19 Check: slots timeout

20 Check: Format timeout

SI 81 Error Code: COM 1

SI 82 Modem Status: COM 2

SI 83 Error Code: COM 2

SI 84 Modem Status: COM 3

SI 85 Error Code: COM 3

Page 41: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

COM Port/Modem Status, System Operands, & Error Messages

41

GSM Cellular Modem, GSM Signal Quality, SI 185

SI Description Value

185 GSM Signal Quality The value is written during COM Init of the GSM modem. The value is updated whenever the user uses the GSM Signal Quality FB. A value of -1(FFFF)signifies a modem error. This may be due to a weak signal; try repositioning the antenna. If this has no effect, check the modem.

SDW: Last Received SMS

SDW Description

13 Phone number of last received SMS (last 9 digits)

Information on SMS messaging status and messages may be found in the topic SMS Operands.

Page 42: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 43: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

43

Modem TroubleshootingNote that Vision PLCs have a built-in communications 'sniffer'. This is accessible in Information Mode, under System.

Touch screen models: select Serial or Ethernet, then click Monitor. Note the button that allows you to toggle between Hex and ASCII.

Non-touch screen models: Select Communication, then select Serial or Ethernet> COM Buffer. Use F2 to toggle between Hex and ASCII. In addition, press Enter, and then the Down key to toggle between Tx and Rx.

Modem Commands

Note ♦ The modem must reply with either OK or READY to each command entered. If the modem fails to answer, the command has not been processed.

+++ Escape Sequence. This causes the modem to close connections and go back to command mode

AT This command means Attention; and is used to begin a session

AT&F Restores factory default settings

ATZ Resets the modem. This command may take time to implement, so the response from the modem may be delayed

ATE0 No Echo

V1 Enable Verbose (long) response

Q0 Respond

X4 Detailed answers

&D0 Ignore DTR

&S0 DSR always ON. Since the DSR can be permanently set to ON, connecting it to the RTS causes the terminal always be ready to transmit\receive data

&S1 DSR OFF in command and test modes

&C1 Give the user a signal for the DCD

ATS0=1 Auto-Answer after 1 ring

&W Burn the configuration into the modem�s non-volatile memory

PC-side modem, error messages

This deals with errors that may result from the PC's modem

Message Cause

COM Port not open, or modem does not exist

The PC was unable to access the PC port. The port may: -Already be in use. -Be damaged.

Modem not connected

The PC receives no reply from the modem following the 'AT' command. Check that: -The modem is connected to the same PC port you have defined in PC-modem Configuration. -The PC-modem cable is in proper order.

Modem not initialized

The modem was not successfully initialized, or The modem answered, but did not approve all strings.

Page 44: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

44

Check the topic: Using Hyperterminal for Modem Troubleshooting

The messages below describe the modem 's status if the PC dial attempt (ATD+ number) fails. Any one of these errors aborts the Dial process.

Modem Busy

Modem Error

No Dial Tone

No Carrier Note ♦ This can occur if, within the modem initialization strings, the parameter S7 TimeOut, is to short to permit the PLC's modem to answer. For example, if this parameter is set as S7=30, the PC modem will wait for 3 seconds to receive an answer from the PLC's modem. If, however, the PLC program's COM Init FB Answer Settings are set to 'Answer after 6 rings,' the PLC modem will not be able to answer before the 3 seconds have elapsed. In this case, the TimeOut parameter is exceeded, and the PC modem will return the No Carrier error.

Dial time-out exceeded

No reply was received from the modem within the defined time.

The messages below only relate to unsuccessful GSM modem initialization.

GSM SIM card blocked

GSM SIM card does not exist

Illegal GSM PIN code

GSM Network not found

CDMA Network not found

SMS message too long

A message containing only English characters may contain up to 160 characters. A message containing non-English characters may contain up to 70 characters.

Time-out exceeded

PLC modems

These errors may result from problems in the PLC-side modem

Message Possible cause Recommended action

Modem Busy Modem is engaged, or is being initialized

Check that the line is free. Use the SBs: Modem Initialization Status listed above to check the COM port status; communications cannot flow through the port during initialization. For more information check the topic COM Port Init.

Handshake between modems complete ('CONNECT'), PLC does not reply

Modem adapter cable

Check the PLC-to-modem connection and pin-out, particularly that the DSR is connected to the RTS on the modem side.

Problem SI Value (80, 82, 84)

Possible Cause & Recommended Action

Page 45: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Modem Troubleshooting

45

Modem fails to initialize (SB 81, 83, 85 ON)

3 PLC-to-modem cable: Make sure that the cable is securely connected. Check the modem connection and pin-out of the PLC-to-modem adapter cables. Note that if you use cables comprising this pin-out, you must set the parameter Flow Control to N (none) in the COM Port Init FB. Incompatible communication settings. Most modems automatically match the parameters of incoming data: baud rate, data bits, parity & stop bits. You may need to manually change your modem's communication settings.

0 You may have selected the wrong type of modem in the COM Port Init FB.

A complete list of error messages for SI 80, 92, 84, as well as other System Operands containing modem error is given in the topic COM Port/Modem Status, System Operands, & Error Messages.

Modem Connection

Cable Pin-out The Unitronics� cable provided with modem kits does not provide a standard connection. This connection is adapted to support the fact that Unitronics controllers do not support the control lines. The cable shorts the DSR and the DTR together, which ensures that the terminal is always ready to receive data. For more information, refer to the topic Modem Connection and Pinouts.

Data Flow Direction Generally, when you transmit data, you send it out. Note, however, that transmitted data (TXD) is input to the DCE. A Receive Data signal (RXD) is input to the DTE, but output from the DCE.

Therefore, the RXD and TXD signals are crossed within the majority of modems. This means that a straight through "one to one" cable is generally all that is necessary between a modem and a controller or PC serial port.

RS-232 signal information

RXD Receive Data

Input for DTE devices (Receive), output for DCE devices. This is the data channel from the DCE device to the DTE device.

TXD Transmit Data

Output for DTE devices (Send), input for DCE devices. This is the data channel from the DTE device to the DCE device.

GND Signal Ground

Signal return for all signal lines.

RTS Request To Send

Terminal is ready to receive data. When the DTE is ready to receive data, the DTE serial port RTS signal is ON.

CTS Clear To Send

Terminal is ready --not related to data transfer.

DTR Data Terminal Read

It is an output for DTE devices and an input for DCE devices. This signal is typically used to show that the port has been activated or "opened".

DSR Data Set Ready

Detects if the RS232 is actually connected.

Page 46: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

46

DCD Data Carrier Detect

Turns ON when the modems connect.

RING Turns ON when someone is calling the DTE.

GSM modems

Problem SI Value (81, 83, 85)

Possible Cause & Recommended Action

Wrong PIN number 3 Check the PIN number in the COM Port Init FB; leave it empty if your SIM card has no PIN number.

Failed Registration 4 GSM modem did not register successfully, for example if no network was found, or if the modem antenna is not functioning.

PUK number needed 5 The SIM card is locked due to too many attempts to enter an incorrect PIN number.

Problem Possible Cause & Recommended Action

Cell phone does not receive message

Check the cell phone's SIM card; it may be full. You can clear the SIM card using the Clear option in the COM Port Init FB.

PLC modem does not respond to cell phone call

GSM modems generally recognize whether the incoming call is voice or data. If the modem has been set to answer (via the ATS0=x command, where x is set to a value greater than 0), the modem will not answer an incoming cell phone call, since it will be recognized as a voice message.

Note ♦ The appropriate Modem: Initialized SBs [80 (COM 1), SB 82 (COM 2), SB 84 (COM 3)] must turn ON before activating an SMS Config FB using that COM port; ideally the SBs should be used as an activating condition.

Changing Baud Rate

Note that baud rates for PC and PLC modems can be edited during the Prepare Modem process.

Modem Troubleshooting Table Note that in many cases, checking System Operand status can help you in the troubleshooting process.

Problem Possible cause Recommended Action

PLC stays connected when

A modem which is reset, or to which the power supply

Modem Connection and COM Port Transmit/Receive SBs can be used in conjunction with a timer to

Page 47: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Modem Troubleshooting

47

modem connection fails

is interrupted, may lose the connection and may not send a 'No Carrier string to the PLC. In this case, the SB remains ON, as though the data link still exists. (Note that Modem Connected SBs, 86-88, turn ON when the relevant COM port receives the 'Connect' modem string. Receiving a 'No Carrier' string causes the SB to turn OFF.)

check if the line is inactive; the timer state is used to trigger Hang-up as shown below.

VisiLogic is not able to communicate with the PLC:PLC has initialized a modem. The modem is disconnected, and a PC is plugged into the COM port.

Once the modem is connected to the PLC, and the modem is initialized, the Modem Initialized SB turns ON. As long as this SB is ON, the COM port stays initialized to the baud rate required in order to work with the modem. If VisiLogic attempts to access the PLC via a different baud rate, the attempt will fail. The Synchronization process (using break signals) is disabled while the SB is ON.

Either: Reset the PLC, which will reset the Modem Initialized SB, -or- Via Vision Communication PC Settings, set VisiLogic's baud rate to match the baud rate to which the COM port was initialized to communication with the modem.

Page 48: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 49: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

49

Using Hyperterminal to check PC-PLC direct communicationsIf the PC port is defective or in use by another application, you may be unable to access a directly connected controller with your PC.

Via Hyperterminal, you can check the PLC-PC communication connection by sending a simple text command, Get ID. If the connection is in order, the controller replies with its ID; if the connection is faulty, the controller will not reply.

1. Open Hyperterminal.

2. Enter a name for the new connection and select an icon, and then click OK.

The Connect To box opens.

3. Select the PC COM port that connects the PC to the controller, and then click OK.

Page 50: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

50

4. The Port Settings box opens as shown below. To enable your PC to communicate with the modem, set the COM port parameters to a BPS of either 9600 or 19200, Data bits=8, Parity=N, Stop bits=1, Flow control=None, and then click OK.

5. Open the Properties box by clicking on the Properties button, then open ASCII

Setup.

6. Select the options shown below, and then click OK.

Page 51: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Using Hyperterminal to check PC-PLC direct communications

51

7. To synchronize the controller's communication settings, enter Info mode.

Navigate to System>RS232>Restore Defaults, and then press the Enter key.

8. Open Notepad, enter the text /00IDED, press Enter, and save the file. This is the Get ID command, where 00 is the 'placeholder' for the controller's Unit ID number. 00 enables any directly controller to answer, no matter what it's actual ID number is. ED is the command's checksum.

Note ♦ Pressing Enter places a Carriage Return command at the end of the text. Although the Carriage Return is not visible, the command will not be processed without it.

9. Select Send Text file from the Transfer menu, and open the text file

.

Page 52: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

52

10.If you have configured everything according to the instructions above, and the port is functioning properly, the controller with its ID number. If the port is out of order, the controller will not reply.

In the figure above, the characters in the string that is returned by the controller, /A00IDR1 B30000E5 may be interpreted as follows:

A 00 ID (PLC model)

B (Hardware Version) E5 CR (ETX)

Answer Requested number

M90-R1 OS V3.00 (00) Checksum Not visible

Page 53: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

53

Using Hyperterminal for COM TroubleshootingYou can use a standard Windows application called Hyperterminal to perform certain tasks, such as changing a modem�s communication rate.

Note ♦ The modem driver does not need to be installed in order to access the modem via Hyperterminal.

Modem Connections Cable Pin-out The Unitronics� cable provided with modem kits does not provide a standard connection. This connection is adapted to support the fact that Unitronics controllers do not support the control lines. The cable shorts the DSR and the DTR together, which ensures that the terminal is always ready to receive data. For more information, refer to the topic Modem Connection and Pinouts.

Data Flow Direction Generally, when you transmit data, you send it out. Note, however, that transmitted data (TXD) is input to the DCE. A Receive Data signal (RXD) is input to the DTE, but output from the DCE.

Therefore, the RXD and TXD signals are crossed within the majority of modems. This means that a straight through "one to one" cable is generally all that is necessary between a modem and a controller or PC serial port.

RS-232 signal information

RXD Receive Data

Input for DTE devices (Receive), output for DCE devices. This is the data channel from the DCE device to the DTE device.

TXD Transmit Data

Output for DTE devices (Send), input for DCE devices. This is the data channel from the DTE device to the DCE device.

GND Signal Ground

Signal return for all signal lines.

RTS Request To Send

Terminal is ready to receive data. When the DTE is ready to receive data, the DTE serial port RTS signal is ON.

CTS Clear To Send

Terminal is ready --not related to data transfer.

DTR Data Terminal Read

It is an output for DTE devices and an input for DCE devices. This signal is typically used in UNIX to show that the port has been activated or "opened".

DSR Data Set Ready

Detects if the RS232 is actually connected.

DCD Data Carrier Detect

Turns ON when the modems connect.

RING Turns ON when someone is calling the DTE.

Using Hyperterminal 1. Open Hyperterminal. The program can generally be located by clicking the

Start button in the lower left corner of your screen, then selecting

Page 54: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

54

Programs>Accessories>Communications>Hyperterminal. The New Connection window opens as shown below.

Note ♦ Hyperterminal generally starts by pointing to the internal modem, if one is installed on the PC.

2. Enter a name for the new connection and select an icon, and then click OK. The Connect To box opens.

3. Select a COM port for the modem, and then click OK.

4. The Port Settings box opens as shown below. To enable your PC to

communicate with the modem, set the COM port parameters to a BPS of either 9600 or 19200, Data bits=8, Parity=N, Stop bits=1, Flow control=None, and then click OK.

Page 55: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Using Hyperterminal for COM Troubleshooting

55

5. Open the modem�s Properties box by clicking on the Properties button, then

open ASCII Setup.

6. Select the options shown below, and then click OK.

Page 56: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

56

Hyperterminal is now connected to your PC via COM 1; the ASCII settings now enable you to enter commands via the PC keyboard and see the replies from the modem within the Hyperterminal window.

To test the connection, type AT; if the connection is valid the modem will respond 'OK'.

Typical initialization strings used with a Siemens M20-type modem are shown below.

Modem Commands Note ♦ The modem must reply with either OK or READY to each command entered. If the modem fails to answer, the command has not been processed.

+++ Escape Sequence. This causes the modem to close connections and go back to command mode

AT This command means Attention; and is used to begin a session

AT&F Restores factory default settings

ATZ Resets the modem. This command may take time to implement, so the response from the modem may be delayed

ATE0 No Echo

V1 Enable Verbose (long) response

Q0 Respond

X4 Detailed answers

&D0 Ignore DTR

&S0 DSR always ON. Since the DSR can be permanently set to ON, connecting it to the RTS causes the terminal always be ready to transmit\receive data

&S1 DSR OFF in command and test modes

&C1 Give the user a signal for the DCD

ATS0=1 Auto-Answer after 1 ring

&W Burn the configuration into the modem�s non-volatile memory

Page 57: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Initializing the modem tOnce the modem is successthe modem to SMS mode.

Command Description

at+cpin=? Is a pin numb

at+pin=�xxxx� xxxx

Is the pin numapplication?

at+creg? Has the SIM cregistered witprovider?

at+cmgf=1 Go to text mo

Notes ♦ Commands includingis not verified during

♦ If the SIM requestmodem and instal

♦ If the SIM is full, tinto a phone to en

♦ The modem must supported.

When a controller sendIt uses the Send com�phone number�.

The controller then wWhen the '>' is receivwith CTRL_Z

Using Hyperterminal for C

to SMS mode via Hyperterminalsfully initialized, you can use Hyperterm

Notes

ber required?

mber set in the

card been th the local cellular

Should return one of tw+CREG: 0,1 The SIM is registered w

+CREG: 0,5 The SIM is in roaming

ode

g question marks are run for verification twicthe second attempt, the attempts stop.

ts the PUK number, the SIM must be taled into a phone to enable the number the SIM must be taken out of the modenable the SIM to be cleared.be able to support Text mode. P.D.U. m

ds an SMS text messagemmand, containing the number to be ca

waits for the reply '>'.ved, the controller sends the message,

COM Troubleshooting

57

minal to initialize

wo answers:

with its local provider.

mode.

ce. If the command

ken out of the to be entered.

em and installed

mode is not

lled: AT+CMGS=

ending the line

Page 58: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

If the message is succonfirmation,+CMGS184 turns ON. The coIf : the message of confirthe '>' is not received

When the controller receive

It receives the commcontroller's memory, When the message isthe command AT+CMThe modem replies wand concluding with O

Note ♦ When a COM port ON: SB 80 , 82, 83If initialization fails

'The Sniffer'--Viewing cThe instructions below showdevice enables you to use Hbetween a PLC and an exter

�Sniffer� is connected to the external device.

The completed Sniffer is connected to a PLC communication port, PC and external device. Note that communication cables are the programming cable provided by Unitronics.

To make a Sniffer, you need

An adapter.

ccessfully sent, the controller will receiv:xx. When this message is received byonfirmation message is acknowledged b

rmation is not received within 15 second within 3 seconds, SB 185 turns ON.s an SMS text message:

and: +CMTI: �SM� ,xx. Xx is a numbe1 to 20.

s received, the controller asks the modeMGR=xxwith +CMGR, including the phone numbeOK.

has been successfully initialized, the re3 or 84.s, SB 81, 83, 85, or 87 will turn ON.

communication stringsw you how to construct a communicatioHyperterminal to view communication strnal, connected device such as a bar co

�COM�the PL

d:

58

ve a message of y the controller, SB by OK.

nds, or

r in the

em for the text via

er, status, text,

elevant bit turns

ns 'Sniffer'. This trings flowing

ode reader.

� is connected to LC.

Page 59: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Two 1N4148 or 1N91

1. Open the adapter carefully via the 4 snaps in its sides.

2. Cut the red and green wibelow.

3. Solder one diode to the rone diode to the green wThe soldered point provid

4. Put isolating material on points.

Using Hyperterminal for C

4 diodes.

ires as shown

red wire, and wire.des the anode.

the soldered

COM Troubleshooting

59

Page 60: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Vision OPLCs and Modems

60

5. Solder both diodes� cathodes to the red wire.

6. Put isolating material on the solder.7. Close the Sniffer. 8. Label the connectors as shown.

Note ♦ In order to run view the strings in Hyperterminal, you must set the program to display ASCII strings as described above in Using Hyperterminal.

Page 61: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

1

GPRSGPRS is a wireless data transmission service offered by some cellular providers. When a Unitronics' PLC is connected to a GPRS modem, the PLC can establish a data connection with a remote PC connected to the Internet and transmit IP packets of data over the GPRS cellular network.

You can then use your PC to access the PLC via VisiLogic, Remote Access or other communication .dll, as well as log PLC data via the DataXport utility.

The figure below shows GPRS communication elements.

Notes ♦ The PLC must be connected to a GPRS modem. GPRS service must be

supplied by the user's cellular service provider. ♦ To enable any GPRS operations to run, the PLC application must include

GPRS Configuration and GPRS Run FBs. ♦ You must prepare both the PLC and PC side modems by carrying out

the Prepare PLC-side Modem procedure detailed in the topic PLC-side modems, and the Initialize PC Modem detailed in the topic PC-side modems.

♦ The PLC must initiate the GPRS data link by calling the PC. A sample application showing how to establish PC-PLC communications is available for both Sony Ericsson and Wavecom modems. This application is intended to be used as a template, for you to simply copy and adapt to your own requirements. Sample applications are located under Help>Examples.

♦ Wavecom modems do not support the End Call function. In order to end a call, use the Unregister from Network function, and then re-register if required.

The Sony Ericsson GT47 GPRS modem must be used in conjunction with an appropriate cable and 5 pin connector.

♦ Not supported by the V120-12 series.

Page 62: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

GPRS

2

Using GPRS The PLC's Ladder application must contain the conditions and elements shown below.

FB Name Purpose

COM Port Init FB Configure this FB to initialize the PLC COM Port connected to the GPRS-modem. Within the COM Init FB, select the GSM modem type, and then the actual GPRS modem type, such as the Sony Ericsson GT47. COM Port Init is usually a Power-up task. Note ♦ To learn how to prepare the modem for PLC use, check the topic PLC-side Modems.

GPRS Configuration The Configuration is linked to the serial port initialized via the COM Port Init FB. Note ♦ The activating conditions should include the appropriate Modem Initialized SB for the COM Port.

GPRS

Register to Network

Register must follow the GPRS Configuration. Connect provides the parameters that enable the PLC to connect to the Internet via the cellular network.

GPRS Run This element enables data communications via GPRS. Note ♦ The activating conditions should include the appropriate Modem Initialized SB for the COM Port.

Page 63: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

GPRS

3

Downloading OS via GPRS Enhanced Vision controllers using Boot 2.00 and higher support OS download via GPRS modem.

Notes ♦ The TC65 does not support OS download.

The modem must be connected to COM2.

Once the download begins, the controller enters Boot mode. Any interruption in communication may result in the controller being 'stuck' in boot mode, without an installed OS. For this reason, it is it is recommended that someone be next to the PLC during the OS download in order to attend to any potential problems.

FB Operations GPRS Operations are located on the FBs menu.

G P R S C o n f i g u r a t i o n

G P R S R e g i s t e r t o N e t w o r k

G P R S R u n

S t a r t C a l l

L i s t e n / S t o p L i s t e n i n g R e m o t e D ev i c e

U n r e g i s t e r ( D i s c o n n e c t ) f r o m N e t w o r k

C h e c k S i g n a l Q u a l i t y

G P R S O p e r a n d s & S t a t u s M e s s a g e s

Examples Sample applications may be found in the VisiLogic Examples folder. This folder contains field-tested VisiLogic (.vlp) sample applications. You can open this folder via the Help Menu.

The folder is typically located at: C:\ProgramFiles\Unitronics\VisiLogic\Examples\Verx.xx, where x.xx indicates the version of VisiLogic.

Page 64: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 65: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

5

GPRS ConfigurationThe GPRS Configuration must be included in all GPRS Ladder applications.

The Configuration is linked to the serial port connected to the GPRS modem and initialized via the COM Port Init FB.

Note ♦ The activating conditions should include the appropriate Modem Initialized SB for the COM Port.

Parameter Type Function

Name The name of the Configuration.

Port Number Constant Click the drop-down arrows to view available ports; click the port you want to use.

Status Messages

MI The value of the linked MI indicates GPRS status messages.

Call Status MB This bit turns ON when the remote device has been accessed and the GPRS connection is established.

Page 66: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 67: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

7

GPRS Register to NetworkThis FB provides the parameters that enable the PLC to connect to the Internet via the GPRS cellular network.

Parameter Type Function

Name Select the name of the GPRS Configuration that Connect will use to connect to the GPRS network.

Registration Status

MB Turns ON when the PLC is assigned an IP address and registered by the GPRS network.

IP Address MI When the PLC registers on the GPRS network, it is assigned a dynamic IP address. This is the start of a vector that contains the IP address that is assigned to the modem when the modem registers with the GPRS network. The vector is 4 MIs long. The low byte of each MI provides the number for an octet within the IP address. If, for example, the IP address is linked to MI 0, and the low bytes of MI 0 to MI 3 contain the values 192, 198, 192, 45, the IP address will be 192.198.192. 45.

APN Server Constant or MI

The name of the APN (Access Point Name) Server given by your GPRS service provider.

Dial Number (optional)

Constant or MI

These parameters are required by some GPRS service providers and GPRS modem manufacturers.

User Name (optional)

Constant or MI

Password (optional)

Constant or MI

Page 68: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 69: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

9

GPRS RunThis element enables data communications via GPRS and must be included in all GPRS applications. The activating conditions should include the appropriate Modem Initialized SB for the COM Port.

Page 70: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 71: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

11

Start Call, End CallStart Call

This FB provides the Port and IP address of the remote device, enabling the PLC to call the remote device and establish a data communications link.

Parameter Type Function

Name Select the name of the GPRS Configuration that Connect will use to connect to the GPRS network.

Remote TCP/IP Port

Constant or MI

The access port of the remote device.

IP Address Constant or MI

The address of the remote device.

End Call This FB ends the current data communications sessions with a remote device, but does not terminate the connection to the GPRS network.

Note ♦ Wavecom modems do not support the End Call function. In order to end a call, use the Unregister from Network FB, and then re-register to the network if required.

Page 72: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 73: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

13

Listen to Remote Device, Stop Listening to Remote DeviceListen

This FB provides the Port and IP address of the remote device, enabling the PLC to call the remote device and establish a data communications link.

Parameter Type Function

Name Select the name of the GPRS Configuration that Connect will use to connect to the GPRS network.

Remote TCP/IP Port

Constant or MI

The port the PLC uses to listen to the remote device.

Stop Listening This FB ends the current data communications sessions with a remote device, but does not terminate the connection to the GPRS network.

Parameter Type Function

Name Select the name of the GPRS Configuration that Connect will use to connect to the GPRS network.

Note ♦ Wavecom modems do not support the End Call function. In order to end a call, use the Unregister from Network FB, and then re-register to the network if required.

Page 74: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 75: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

15

Unregister from NetworkUse this to disconnect the PLC from the GPRS network, including a delay of a second or two to allow the socket time to close when de-registering.

Page 76: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 77: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

17

Check Signal QualityThe signal quality value is placed in SI 185 GSM Signal Quality.

A value of -1(FFFF)signifies a modem error. This may be due to a weak signal; try repositioning the antenna. If this has no effect, check the modem.

Page 78: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 79: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

19

GPRS Operands & Status MessagesOperands linked to GPRS FBs should be assigned Power-up Values; bits should be reset, and registers initialized to 0.

GPRS: Configuration FB

Call Status GPRS MB Turns ON when:

� Call successfully made

Turns OFF when

� Call is terminated

Status Messages

Initialized to 0 when GPRS: Configuration is activated.

MI Value Message

0 No message

1 GPRS network registration is in progress

2 Registration Complete: the modem successfully registered with and received an IP address from the GPRS network

3 Connected to GPRS network

4 Listen Mode: Initialization Begins

5 Listen Mode: Initialized

6 Listen Mode: Initialization Re-started

10 Start Call: Begins

11 Start Call: Complete

15 End call: Begins

16 End call: Complete

20 Unregistration Begins (Not during Call)

21 Unregistration Begins (During Call)

22 Unregistration Complete: the modem has successfully disconnected from the GPRS network

23 Listen Mode: Close process begins

24 Listen Mode: Closed

30 Check Signal Quality: Start

31 Check Signal Quality: End

40 Command not supported (When End Call is activated in an application using a Wavecom modem)

50 Modem reply error

51 Modem Timeout error

52 Network Registration: failled

Page 80: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

GPRS

20

GPRS: Register to Network

Registration Status MB Turns ON when:

� The modem successfully registers with and received an IP address from the GPRS network

Turns OFF when

� The modem disconnects from the network

IP Address MI This is the start of a vector that contains the IP address that is assigned to the modem when the modem registers with the GPRS network. The vector is 4 MIs long. The low byte of each MI provides the number for an octet within the IP address. If, for example, the IP address is linked to MI 0, and the low bytes of MI 0 to MI 3 contain the values 192, 198, 192, 45, the IP address will be 192.198.192. 45.

GPRS System Operands

SI Description Value

185 GSM Signal Quality � The value is written during COM Init of the GSM modem. The value is updated whenever the user uses the GSM Signal Quality FB.

� A value of -1 (FFFF)signifies a modem error. This may be due to a weak signal; try repositioning the antenna. If this has no effect, check the modem.

SBs 120-125 register the signals that each port receives from the DTR and DSR pins of a serial communication cable. The DTR SBs 120, 122, and 124 are also used by the OS to control the DTR signal during RS485 serial communications, and during GPRS communications using the Sony Ericsson GPRS modem.

SB# Description Turns ON when: Turns OFF when: Reset by:

SB100 GPRS modem connected

� Call Remote device begins

� GPRS incoming call is answered

� End Session succeeds

� Disconnect from Network succeeds

OS

SB 120 DTR COM Port 1 (signal output from PLC)

DTR signal present DTR signal absent OS, may also be reset by user

SB 121 DSR COM Port 1 (signal input to PLC)

DSR signal present DSR signal absent OS

SB 122 DTR COM Port 2 (signal output from PLC)

DTR signal present DTR signal absent OS, may also be reset by user

SB 123 DSR COM Port 2 (signal input to PLC)

DSR signal present DSR signal absent OS

SB 124 DTR COM Port 3 (signal output from PLC)

DTR signal present DTR signal absent OS, may also be reset by user

SB 125 DSR COM Port 3 (signal input to PLC)

DSR signal present DSR signal absent OS

Page 81: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Check Signal Quality

21

Page 82: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 83: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

1

Using SMS Messaging To enable a controller to use SMS messaging, connect it to a modem that supports connection to a cellular network with SMS messaging service. SMS messaging operations are located on the FBs menu.

To send or receive SMS messages:

1. Initialize one of the controller's communications ports using a COM Init FB.

Note ♦ Communications cannot flow through the port during initialization. To avoid conflicts in your program, use the Modem Initialization Status SBs.

♦ Before using a modem, prepare it as described in the help topic PLC-side Modems.

2. Place an SMS Configuration FB into your application. Link it to the port initialized via the COM Init FB. The SMS Configuration will use this port to receive and send messages.

The SMS Configuration contains a list of SMS messages and phone numbers.

Note ♦ COM Init and SMS Configuration must appear in the application and be activated before any SMS operations are activated. If this is not done, the application will not work.

To enable the controller to receive messages, place an SMS Scan FB in your application and link it to a Configuration. When activated, this causes the controller to scan the GSM modem's SIM card for incoming SMS messages

To enable the controller to send SMS messages, place an SMS Send FB in your application and link it to a Configuration. You can then either send one of the messages in that Configuration or create one for that specific Send FB.

In either case, the port defined in the Configuration will be used to send the message.

FB Operations S M S : Co n f i g u r a t i o n

S M S : S c a n

S M S : S e n d

S M S : C h e c k G S M S i g n a l Q u a l i t y

How to Configure, Receive, and Send Messages 1. Initialize a COM Port. The initialization status of each port is indicated in

Modem Initialization Status SBs. These SBs can be used to activate an SMS configuration.

Page 84: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

2

2. Select SMS Configuration from the FBs menu and place the function in your application.

Note

♦The condition that activates the SMS Configuration must turn ON for a single program scan (positive transition recommended).

♦ Once an SMS Configuration is activated, it can process SMS messages. However, messages are sent or received only when the MB linked to Modem Busy (GSM) is OFF.This MB turns ON when the modem is processing a message, or is communicating data to another application such as VisiLogic.

♦ The appropriate Modem: Initialized SBs [80 (COM 1), SB 82 (COM 2), SB 84 (COM 3)] must turn ON before activating an SMS Configuration using that COM port; the SBs should be used as an activating condition.

The SMS configuration must be scanned during every program cycle--after the Configuration is activated. One way to ensure this is by placing the configuration in the first subroutine of the main module.

3. To receive messages, place a Scan FB in your application.

Note ♦ An SMS Scan generally uses a direct contact as an activating

condition. This enables the configuration to continually 'listen' for incoming messages. When the controller registers that a Scan has been activated, the MB linked to Modem Busy (GSM) turns ON, turning OFF only after the Scan is complete.

Page 85: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Using SMS Messaging

3

You can also write incoming messages to an operand vector, including messages that are not in the Configuration.

1. Turn SB 199.

2. Enter the Start of Vector address (MI) in SI 199. You can write to an XI vector by entering a negative value.

If SB 199 is ON, SB 198 will be SET when an SMS message is received, and the message will be stored in operand vector. The length of the message, in bytes, will be stored in SI 198.

4. To send messages, place a Send FB in your application.

Note

♦When the positive transition contact used to activate the Send FB rises, the MB linked to Modem Busy (GSM) turns ON.

The rest of the logic in the net is processed whether or not the Send operation is completed.

♦ Operands linked to SMS FBs, such as Modem Busy (GSM), should be assigned Power-up Values; bits should be reset, and registers initialized to 0.

♦ When an SMS message is sent, the Modem Busy (GSM) MB remains ON until the message has cleared the SIM card.

♦ Be careful when using positive transition contacts to activate a Send operation.

When a Send operation is in progress, the modem is busy. If another Send operation is activated while the modem is busy, the second Send operation will not be activated and the message will not be

Page 86: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

4

sent--even after the modem is no longer busy.

Examples Sample applications may be found in the VisiLogic Examples folder. This folder contains field-tested VisiLogic (.vlp) sample applications. You can open this folder via the Help Menu.

The folder is typically located at: C:\ProgramFiles\Unitronics\VisiLogic\Examples\Verx.xx, where x.xx indicates the version of VisiLogic.

Page 87: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

5

SMS: ConfigurationAn SMS Configuration contains a list of SMS messages with attached variables and a phone book that is unique to that configuration. SMS Configuration is also where you define Message Properties.

Note ♦ The appropriate

Modem: Initialized SB [80 (COM 1), SB 82 (COM 2), SB 84 (COM 3)] must turn ON before the application can activate an SMS Config FB using that COM port. A Modem Initialized SB should be used as an activating condition.

Creating SMS Messages & Variables A single SMS message can contain both fixed text and up to 10 variables. A message containing only English characters may contain up to 160 characters. A message containing non-English characters may contain up to 70 characters.

Note ♦ When you create messages in a Configuration, VisiLogic does not allow you to begin a message with a fixed text character that is not a numeral (0-9) or a number sign (#). These limitations do not apply to messages that you compose in an SMS Send FB, or to Indirect Messages. These may begin with variables or with any alphanumeric character.

♦ Although the PLC can send Binary Text, Numeric, and List of Texts variables, it can only receive Numeric variables..

Page 88: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

Binary Variable

This type of variable dispto the status of a bit ope

Number Variable

A Number Variable enab

Show any numeric vControl the format of a decimal point aUse Linearization totemperature conver

plays different text in the SMS variableerand.

bles you to:

value within a message.in which that value is shown, including and leading zeros.o show a converted value, such as an arted to degrees Celsius.

6

field according

the placement

nalog

Page 89: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS: Configuration

7

List of Texts: by Pointer

This type of variable contains numbered lines of text. You link the Variable to an operand. The value within that operand 'points' to the number of a line within the list. When the operand value is equal to a particular line number, the text of that line is shown in the Display.

Message Properties This defines how the PLC deals with a specific SMS message that is received by the system. Note that a SMS Scan FB must be placed in the Ladder to enable the PLC to check a specific SMS Configuration for received messages.

Page 90: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

Phone Book Click on a line to either:

Directly enter a phoUse a vector of regiVariables can then number from the co

Indirect Vector

Each register byte contathe ASCII value of the d049.

one number in the phone book, oristers to indirectly dial a number. HMIbe linked to this vector, enabling a useontroller keypad via HMI Entry Variable

ains 1 character. Note that the byte actudesired numeral. For example, the ASC

8

Keypad Entry r to dial a s.

ually contains CII value of 1 is

Page 91: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS: Configuration

9

International Cell Phone Number Format

To work with international phone numbers, use the full GSM format, including the '+' in front of the country code.

Message Index Numbers

The messages in the Configuration are numbered consecutively. Inserting and deleting messages causes the index numbers to increment and decrement.

If your application contains Send functions that send messages from the Configuration, you must edit the message index number accordingly.

Example

In the following figure, the Send function is set to send the message with Index # 2.

In the next figure, the user inserted a line, causing the index number to increment. However, the user did not edit the Send function, and message Index # is now blank.

Page 92: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

10

Page 93: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS ConfiguratioThe condition that activaprogram scan. (positiveHowever, the SMS conprogram cycle--after tensure this is by placimain module.

The net containing the c

Be in a subroutine tapplication.

Be in a net that is nThis SMS Configuration win every program scan t

Unlike the example abovrises), and is then not in

on and the Program Scanates the Configuration must be turn ONe transition is recommended) nfiguration must be scanned duringthe Configuration is activated. Oneing the configuration in the first sub

configuration must:

that is called during every program sca

never skipped over by a Jump to Label.will be activated once (SB82 rises), andhat follows.

ve, this Configuration is scanned only oncluded in the following program scan

11

N for a single

g every e way to broutine of the

n of the

d then included

once (SB 82 s.

Page 94: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 95: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

13

SMS: ScanTo enable the controller to receive messages, place an SMS Scan FB in your application and link it to a Configuration. When activated, this causes the controller to scan the GSM modem's SIM card for incoming SMS messages.

Before you can receive an SMS, you must initialize a COM port to use a GSM modem, create an SMS Configuration, and set conditions as explained in Using SMS Messaging.

Note ♦ Communications cannot flow through the port during initialization. To avoid conflicts in your program, use the Modem Initialization Status SBs.

♦ Although the PLC can send Binary Text, Numeric, and List of Texts variables, it can only receive Numeric variables.

♦ Use an MB activated by the SMS Configuration FB to activate the Scan, as shown in Using SMS Messaging

When the PLC receives a message, the Message Properties defined in the SMS configuration for that message define how it will be processed.

Page 96: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

14

Page 97: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

15

SMS: SendTo send an SMS, place an SMS Send operation in your Ladder application. Before you can send an SMS, you must initialize a COM port to use a GSM modem, create an SMS Configuration, and set conditions as explained in Using SMS Messaging.

Note ♦ Communications cannot flow through the port during initialization. To avoid conflicts in your program, use the Modem Initialization Status SBs.

♦ Before using a modem, prepare it as described in the help topic PLC-side Modems.

♦ If the SMS Configuration is busy, messages cannot be received. Avoid conflicts by using a negative contact, linked to the Configuration's Modem is Busy MB, as an activating condition for SMS: Send.

Note ♦ You can send only one SMS message at a time, but you may send it to multiple phone numbers.

♦ The Send Status MB turns on if there are more than one Send operations, and the PLC has not finished processing the first Send before the second Send is activated. In this case, Modem Busy MB of the SMS: Configuration bit will be ON, causing the Send Fail Bitmap to contain a value of -1.

Page 98: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

16

Compose Message

Opens a blank message field. Create a message by typing characters and attaching variables.

Select from Configuration

Opens the list of messages contained in the linked Configuration. To select a message to send, click it; the message will be highlighted.

Indirect Message

Enables a vector of register values to be sent as ASCII characters. Note ♦ Each register byte contains one character.

Note ♦ When you create messages in a Configuration, VisiLogic does not allow you to begin a message with a fixed text character that is not a numeral (0-9) or a number sign (#). These limitations do not apply to messages that you compose in an SMS Send FB, or to Indirect Messages. These may begin with variables or with any alphanumeric character.

♦ A message containing only English characters may contain up to 160 characters. A message containing non-English characters may contain up to 70

Page 99: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS: Send

17

characters.

♦ Phone Indexes is based on the Phone Book in the linked SMS configuration. Index numbers are 0 to 8, note that 0 is the index of the last number called.

♦ SB 184 SMS: Transmission Succeeded and 185 SMS: Transmission Failed are both reset when any message is sent to any phone number. After the message has been processed, the Relevant SB will turn ON.

♦ You can send messages in ASCII text format by turning ON SB 279: ASCII Text message format,

♦ If forced display messages are supported by the cell phone receiving the SMS, you can send a forced display message by turning ON SB 280: Force Message Display on Cell Phone.

Page 100: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 101: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS VariablesVariables can be includemessage can contain bovariables are not related

Although the PLC can secan only receive Numer

Binary Variable

This type of variable dispto the status of a bit ope

Numeric Variable

A Number Variable enab

Show any numeric vControl the format of a decimal point aUse Linearization totemperature conver

ed in Configuration or Send FB messageth fixed text and up to 10 variables. No

d to HMI variables.

end Binary Text, Numeric, and List of Teric variables.

plays different text in the SMS variableerand. The value currently visible is the

bles you to:

value within a message. in which that value is shown, including and leading zeros.o show a converted value, such as an arted to degrees Celsius.

19

es. A single SMS ote that SMS

exts variables, it

field according e last value sent.

the placement

nalog

Page 102: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

20

List of Texts: by Pointer

This type of variable contains numbered lines of text. You link the Variable to an operand. The value within that operand 'points' to the number of a line within the list. When the operand value is equal to a particular line number, the text of that line is shown in the Display.

Page 103: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

21

SMS: Check GSM Signal QualityThe signal quality may be checked at any point after SMS Configuration.

The signal quality value is placed in SI 185 GSM Signal Quality.

A value of -1(FFFF)signifies a modem error. This may be due to a weak signal; try repositioning the antenna. If this has no effect, check the modem.

Page 104: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands
Page 105: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Sending SMS mesTo send SMS messages fr

Create and downloadConfiguration, set Methe topic Using SMS MWrite an SMS messagSend the message to

Note ♦ You can only sendConfiguration in th

♦ If the Limit to Autconfiguration, the

Writing SMS messagesYou write an SMS messag

The fixed text in yourConfiguration in everare case-sensitive.

You bracket variable signs '#' do not counThe variable field in t

The figure below shows thdisplay, and as it appears

When you send this messainto the variable in the PL

Sending the message t1. Enter the number of t

GSM cell phone numbChecking that the PLC

You can check if the PLC rfeature:

ssages from a GSM cell phom your cell phone to your PLC, you m

a project to your PLC that includes an essage Properties, and define conditionsMessaging.ge in your cell phone.the PLC's GSM modem

d messages that are already part of an he PLC.

thorized Phone Numbers option is seleccell phone number must be in the list.

s in your cell phonee using your cell phone keypad. Make s

r cell phone is identical to the message ry detail: spaces, characters--and note

values with number signs (#) as shownnt as spaces.the SMS message is big enough to hold he same SMS message: as it appears onin the PLC's SMS Configuration.

age from your cell phone, the value 11C.

o the PLCthe PLC's GSM modem exactly as you wber, then send the message.has received the SMS messagereceived your message by using the Ack

23

honemust:

SMS s as described in

SMS

ted in the SMS

sure that:

in the PLC's SMS e that characters

n below. These

the value.n a cell phone

0 will be written

would enter any

knowledge

Page 106: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

SMS Messaging

1. Select 'Acknowledge' shown below.

2. Use your cell phone tto the PLC.

3. The PLC receives thisimmediately return the mesvariable value.

4. You can now view thichanges in the variable valu

Note that although the PLand List variables, the PLC

in Message Properties, the ACK box is

to send the message "Holding Temper

s SMS message; AutoAcknowledge causssage to your cell phone, together with

s SMS message on your cell phone dispue.

C can send SMS messages that includeC can only receive Numeric variables.

24

checked as

rature:#110#"

ses the PLC tothe current

play, together with

e Numeric, Binary,

Page 107: Vision OPLCs and Modems - Klinkmann - provider of ...media.klinkmann.fi/catalogue/en/Unitronics/Unitronics_Manuals... · Vision OPLCs and Modems vi Cable Pin-out ... Modem Commands

Index

Bridge ......................................... 37 CCANbus ....................................... 37 COM port ..................................... 45 Communications ............. 9, 29, 41, 45

Initialize COM port ..................... 29 Modem ................. 9, 19, 29, 41, 55 Troubleshooting ......................... 41

Controller .................................... 37 Controller network ........................ 37 DDial ............................................ 31 Download via network ................... 37 EEdit programs-via network ............ 37 Errors ......................................... 41 GGSM ...................................... 19, 21

HHMI ............................................ 31 MModem .................... 9, 15, 19, 45, 55 Modem Error Messages ................. 41 NNetwork ...................................... 37 PPC .............................................. 37 Phone book .................................... 5 Phone numbers .............................. 5 Programming cable ....................... 37 RRemote Access ............................... 9 SSMS ........................ 1, 13, 15, 21, 23 TTroubleshooting ........... 41, 45, 55, 13 WWiring ......................................... 19

Unitronics_Manuals_Vision_OPLCs-Modems_en_0511.pdf

Samaratel. +7 846 273 95 [email protected]

Yekaterinburgtel. +7 343 376 [email protected]

St. Petersburgtel. +7 812 327 [email protected]

Moscowtel. +7 495 641 [email protected]

Helsinkitel. +358 9 540 [email protected]

Vilniustel. +370 5 215 [email protected]

Rigatel. +371 6738 [email protected]

Мinsktel. +375 17 200 [email protected]

Tallinntel. +372 668 [email protected]

Кievtel. +38 044 495 33 [email protected]

www.klinkmann.com