106BTeleservice communication (SMTP e-mail)
13.1 TM_Mail transfer e-mail instruction
If the CPU is changed to STOP mode while TM_MAIL is active, then the communication
connection to the mail server is terminated. The communication connection to the mail
server is also lost if problems occur in CPU communication on the Industrial Ethernet bus. In
these cases, the send process is suspended and the e-mail does not reach the recipient.
CAUTION
Modifiying user programs
Only change the parts of your user program that directly affect the TM_MAIL calls in the
following cases:
The CPU in the STOP mode
No mail is sent (REQ and BUSY = 0)
This refers, in particular, to the deletion and replacement of program blocks, the calls to
TM_MAIL, or calls to the instance DBs of TM_MAIL.
If you fail to maintain linked program blocks, then the TPC / IP communication functions
can enter an undefined state. After transferring a modified program block, you must perform
a CPU restart (warm) or cold start.
Data consistency
The input parameter ADDR_MAIL_SERVER is read when the operation is started. A new
value does not take effect until the current operation is complete and a new TM_MAIL
operation is initiated.
In contrast, the parameters WATCH_DOG_TIME, TO_S, CC, FROM, SUBJECT, TEXT,
ATTACHMENT, USERNAME and PASSWORD are read during the execution of TM_MAIL
and may be changed only when the job is finished (BUSY = 0)
Configuring the TS Adapter IE parameters
You must configure the Teleservice adapter IE parameters for outgoing calls to connect with
the dial-up server of your Internet Service Provider. If you set the call "on demand" attribute,
then the connection is established only when an e-mail will be sent. For an analog modem
connection, more time is required for the connection process (approx. a minute longer). You
must include the extra time, in the WATCH_DOG_TIME value.
Table 13- 3
Data types for the parameters
Parameter and type
REQ
ID
TO_S
628
Data types
IN
Bool
IN
Int
IN
String
Description
A low to high (positive edge) signal starts the operation.
Connection identifier: See the ID parameter of the
instructions TCON, TDISCON, TSEND and TRCV.
A number that is not used for any additional instances of this
instruction in the user program must be entered here.
Recipient addresses: STRING data with a maximum length
of 240 characters
System Manual, 11/2011, A5E02486680-05
S7-1200 Programmable controller