LIMITED WARRANTY. AMX Corporation warrants that the SOFTWARE will perform substantially in accordance with
the accompanying written materials for a period of ninety (90) days from the date of receipt. Any implied warranties on
the SOFTWARE and hardware are limited to ninety (90) days and one (1) year, respectively. Some states/countries do
not allow limitations on duration of an implied warranty, so the above limitation may not apply to you.
CUSTOMER REMEDIES. AMX Corporation’s entire liability and your exclusive remedy shall be, at AMX Corporation's
option, either (a) return of the price paid, or (b) repair or replacement of the SOFTWARE that does not meet AMX Corporation's Limited Warranty and which is returned to AMX Corporation. This Limited Warranty is void if failure of the
SOFTWARE or hardware has resulted from accident, abuse, or misapplication. Any replacement SOFTWARE will be
warranted for the remainder of the original warranty period or thirty (30) days, whichever is longer.
NO OTHER WARRANTIES.
not limited to implied warranties of merchantability and fitness for a particular purpose, with regard to the SOFTWARE,
the accompanying written materials, and any accompanying hardware. This limited warranty gives you specific legal
rights. You may have others which vary from state/country to state/country.
NO LIABILITY FOR CONSEQUENTIAL DAMAGES
whatsoever (including, without limitation, damages for loss of business profits, business interruption, loss of business
information, or any other pecuniary loss) arising out of the use of or inability to use this AMX Corporation product, even
if AMX Corporation has been advised of the possibility of such damages. Because some states/countries do not allow
the exclusion or limitation of liability for consequential or incidental damages, the above limitation may not apply to you.
U.S. GOVERNMENT RESTRICTED RIGHTS
The SOFTWARE and documentation are provided with RESTRICTED RIGHTS. Use, duplication, or disclosure by the
Government is subject to restrictions as set forth in subparagraph (c)(1)(ii) of The Rights in Technical Data and Computer Software clause at DFARS 252.227-7013 or subparagraphs (c)(1) and (2) of the Commercial Computer Software--Restricted Rights at 48 CFR 52.227-19, as applicable. Manufacturer is AMX Corporation, 3000 Research Drive,
Richardson, TX 75082.
If you acquired this product in the United States, this Agreement is governed by the laws of the State of Texas.
Should you have any questions concerning this Agreement, or if you desire to contact AMX for any reason, please
write: AMX Corporation, 3000 Research Drive, Richardson, TX 75082.
AMX Corporation disclaims all other warranties, either expressed or implied, including, but
. In no event shall AMX Corporation be liable for any damages
0,"'Attachments:',Itoa(sPop3EmailMessage[nLoop].nAttachCount)"
For (nLoop1=1;nLoop1<=sPop3EmailMessage[nLoop].nAttachCount;nLoop1++)
SEND_STRING 0,"'Attachment ',Itoa(nLoop1),':',
sPop3EmailMessage[nLoop].cAttachments[nLoop1]"
SEND_STRING 0,' '
}
}
}
Once the emails are processed, you can delete any emails you like by calling
Pop3ClearEmailMessage () or Pop3ClearAllEmailMessages ().
Pop3ClearEmailMessage allows you to delete one email at a time;
Pop3ClearAllEmailMessages () allows you to delete all the emails at once.
Configuring for Timezone
The i!-EquipmentMonitorOut.axi file can read the time zone information from i!-TimeManager and
includes this information in email and notifications. Simply include the i!-TimeManager moodule
and make sure to name the i!-TimeManager virtual device '
'i!-EquipmentMonitorTest with i!-TimeManager.axs' provides an example of using these two
applications together.
Using i!-TimeManager is recommended for use with i!-EquipmentMonitor since some email
clients may improperly display the time when the email or notification was sent. i!-TimeManager
provides i!-EquipmentMonitor with a universal time reference, including any Daylight Savings
time offsets, and includes this information in the email or notification.
The i!-TimeManager Module is not included with i!-EquipmentMonitor. To obtain the
i!-TimeManager Module (i!-TimeManager.tko), please download the i!-TimeManager
install from our web site.
vdvTmEvents'. The file
6
i!-EquipmentMonitor
Running i!-EquipmentMonitor
i!-EquipmentMonitorOut.axi
Constants
The following table lists i!-EquipmentMonitorOut.axi constants.
i!-EquipmentMonitorOut.axi Constants
dvSmtpSocketThe IP device number for sending e-mails (default = 0:10:0}.
SMTP_VERSIONThe version number of the include file.
SMTP_PORTIP Port that the SMTP server is listening on (default = 25).
SMTP_SERVER_TOTimeout in 1/10 for contacting the SMTP server (default = 1200).
SMTP_URL_MAXMaximum length for e-mail server name (default = 1000).
SMTP_USER_MAXMaximum length for e-mail addresses (default = 500).
SMTP_LINE_MAXMaximum length for date, subject and attached file (default = 256).
SMTP_MAX_EMAILS Maximum length for number of queued e-mails (default = 10).
SMTP_MSG_MAXMaximum length for e-mail message (default = 2000).
i!-EquipmentMonitor
Continued
7
Running i!-EquipmentMonitor
Structures
The following defines an i!-EquipmentMonitorOut.axi structure:
SmtpQueMessage should be called if you want to send a message. The To parameter can contain multiple addresses separated by a ";". The file parameter is the path
and file of an ASCII (text) only file contained on the master's file systems. This file is
transmitted as an attachment.
8
i!-EquipmentMonitor
i!-EquipmentMonitorOut.axi Functions (Cont.)
SmtpSetTimeOffset(CHAR Offset[])
Call this to configure
the local timezone
SmtpSetServer
Sets your SMTP
Server Name for your
use.
SmtpSetTimeOffset has these arguments:
Offset String containing the local timezone offset. This string is formatted as "+/HHMM" where "+/=" is "+" or "-" depending on your timezone relative to GMT, "HH" is
the offset in hours relative to GMT and "MM" is the offset in minutes relative to GMT.
Some Common Offsets are:
-0500 : Eastern time (UTC - 5:00)
-0600 : Central time (UTC - 6:00)
-0700 : Mountain time (UTC - 7:00)
-0800 : Pacific time (UTC - 8:00)
-0900 : Alaska (UTC - 9:00)
-1000 : Hawaii (UTC - 10:00)
+0000 : Greenwich Mean Time (same as UTC)
+0000 : Dublin, Edinburgh, Lisbon, London (UTC + 0:00)
+0100 : Brussels, Copenhagen, Madrid, Paris, Vilnius (UTC + 1:00)
SmtpSetTimeOffset should be called to configure i!-EquipmentMonitor to send emails
with the correct time. Some SPAM detectors may mark an e-mail as spam if the
timezone is not correctly reported.
i!-EquipmentMonitor is designed to work with i!-TimeManager to obtain timezone
information. If you have included i!-TimeManager in your program and the virtual
device for i!-TimeManager is defined as "vdvTmEvents", the timezone will be configured correctly.
Syntax:
SmtpSetServer(CHAR Server[])
SmtpSetServer has these arguments:
Server:String containing the name or IP of your e-mail (SMTP) server.
SmtpSetServer does not return a value.
Example:
SmtpSetServer('mail.amx.com')
Remarks:
SmtpsetServer should be called in DEFINE_START of your application.
Running i!-EquipmentMonitor
i!-EquipmentMonitor
9
Running i!-EquipmentMonitor
i!-EquipmentMonitorOut.axi Functions (Cont.)
SmtpSetUser
Call this to
configure the
username and
password for SMTP
server
authentication to send
outbound emails.
EncrBase64Encode
This function is used
internally to encrypt the
username and
password for SMTP
server
authentication.
ConfigNotify
Sets your notification
paramaters for your
use.
SendNotify
Call this function to
send an equipment
notification.
SmtpSetUser(CHAR LogInName[],CHAR LogInPass[])
SmtpSetUser has these arguments:
LogInNameString containing the username for the SMTP server.
LogInPassString containing the password for them STMP server.
SmtpSetUser doe not return any values.
Example:
SmtpSetUser ('MyUserName','MyPassword')
Remarks:
SmtpSetUser should be called to configure i!-EquipmentMonitor to send emails to an
SMTP server that required authentication.
You should not have to call this function directly. To configure SMTP authentication,
please see the SmtpSetUser() function.
ConfigNotify should be called in DEFINE_START of your application. You must also
call the SmtpSetServer Function.
The To parameter can contain multiple addresses separated by a ";".
Syntax:
SLONG SendNotify(CHAR Message[],CHAR File[])
SendNotify has these arguments:
MessageString containing the message body of the email.
FileString containing the ASCII (text) only file name to attach to the email.
SendNotify returns these values:
-1If the message was not successfully queued for sending.
>0If the message was successfully queued for sending.
Example:
SendNotify('The VCR needs to be cleaned.','')
Remarks:
SendNotify should be called if you want to send a notification. The To, From and
Subject used in the ConfigNotify function is included in the notification.
The file parameter is the path and file of an ASCII (text) only file contained on the
Master's file systems. This file is transmitted as an attachment.
Continued
10
i!-EquipmentMonitor
Running i!-EquipmentMonitor
i!-EquipmentMonitorIn.axi
Constants
The following table lists the i!-EquipmentMonitorIn.axi constants.
i!-EquipmentMonitorIn.axi Constants
dvPop3SocketThe IP device number for sending e-mails (default = 0:11:0}.
POP3_VERSIONVersion number of the include file.
POP3_PORTIP Port that the POP3 server is listening on (default = 110).
POP3_BUFFER_MAX Maximum size of buffer for IP socket (default = 2048).
POP3_SERVER_TOTimeout in 1/10 for contacting the POP3 server (default = 1200).
POP3_URL_MAXMaximum length for e-mail server name (default = 1000).
POP3_USER_MAXMaximum length for e-mail addresses (default = 500).
POP3_PASS_MAXMaximum length for e-mail password (default = 100).
POP3_LINE_MAXMaximum length for date, subject and attached file (default = 256).
POP3_MAX_EMAILS Maximum number of e-mails to be retrieved (default = 20).
POP3_MSG_MAXMaximum size of message body (default = 2000).
POP3_ATTACH_MAX Maximum number of attachment file names stored (default = 5).
Structures
The following describes an i!-EquipmentMonitorIn.axi structure:
The following are a list of i!-EquipmentMonitorIn.axi variables:
VOLATILE
_sEmailMessage
sEmailMessage[POP3_MAX_EMAILS] Emails retrieved from server
VOLATILE
Integer
nPop3QtyMail; Number of message retrieved from server
i!-EquipmentMonitor
VOLATILE
Integer
nPop3TotalMail; Number of total messages on server
VOLATILE
CHAR
bPop3Debug Set to 1 to debug
11
Running i!-EquipmentMonitor
Functions
The following table lists i!EmailIn.axi functions.
i!-EquipmentMonitorIn.axi Functions
Pop3ClearAllEmail
Messages
Deletes all e-mails
from the internally
stored email list.
Pop3ClearEmail
Message
Deletes an e-mail
from the internally
stored e-mail list.
Pop3Ge tEmail
Retrieves e-mail
from the server.
Syntax:
Pop3ClearAllEmailMessages()
Pop3ClearAllEmailMessages has no arguments.
Example:
Pop3ClearAllEmailMessages()
Remarks:
Pop3ClearAllEmailMessages should be called when you want to delete all
messages from the internally stored e-mail list. Pop3ClearAllEmailMessages
updates nPop3QtyMail and nPop3TotalMail accordingly. This function does not
delete e-mails from the server.
Syntax:
SLONG Pop3ClearEmailMessage(Integer MsgNum)
Pop3ClearEmailMessage has these arguments:
MsgNum:The message number of the e-mail to be deleted.
Pop3ClearEmailMessage returns these values:
-1 and 0:If the MsgNum is invalid the e-mail was deleted successfully.
Example:
Pop3ClearEmailMessage(1)
Remarks:
Pop3ClearEmailMessage should be called when you want to delete a message from
the internally stored e-mail list. Deleting an e-mail from the internally stored list will most
likely affect message ordering. Pop3ClearEmailMessage updates nPop3QtyMail
and nPop3TotalMail accordingly. This function does not delete an e-mail from the
server.
Syntax:
Pop3GetEmail(CHAR Delete)
Pop3GetEmail has these arguments:
Delete:1 or 0. 1 will delete all e-mails from the server as they are retrieved; 0 will
leave all e-mails on the server.
Example:
Pop3GetEmail(1)
Remarks:
Pop3GetEmail should be called when you want to manually force the retrieval of e-mail
from the server. By default, it is not retrieved from the server automatically, and calling
Pop3GetEmail is the only way to retrieve e-mail. If you have called Pop3SetRefresh
to enable automatical e-mail retrieval, calling Pop3GetEmail also resets the timer so
e-mail will not be retrieved again until the current refresh time has expired.
12
i!-EquipmentMonitor
i!-EquipmentMonitorIn.axi Functions (Cont.)
Pop3SetRefresh
Sets the refresh
time the include file
checks for new
e-mails and
whether they should
be deleted form the
server.
Pop3SetServer
Sets Your POP3
Server Name for
your use.
Pop3SetUser
Sets your POP3
user name and
password for you
e-mail (POP3)
account.
Syntax:
Pop3SetRefresh(Integer Refresh, CHAR Delete)
Pop3SetRefresh has these arguments:
Refresh:Integer containing the refresh time in seconds. 0 disables automatic e-
mail retrieval.
Delete:1 or 0. 1 will delete all e-mails from the server as they are retrieved; 0 will
leave all e-mails on the server.
Example:
Pop3SetRefresh(120,1)
Remarks:
Pop3SetRefresh should be called if you want to adjust when and how e-mail is
automatically retrieved from the server. By default, e-mail is not retrieved from the server
automatically.
Syntax:
Pop3SetServer(CHAR Server[])
Pop3SetServer has these arguments:
ServerString containing the name or IP of your e-mail (POP3) server.
Example:
Pop3SetServer('mail.amx.com')
Remarks:
Pop3SetServer should be called in DEFINE_START of your application.
Syntax:
Pop3SetUser(CHAR User[], CHAR Pass[])
Pop3SetUser has these arguments:
UserString containing the user name of your e-mail (POP3) account.
PassString containing the user password of your e-mail (POP3) account.
Pop3SetUser does not return a value.
Example:
Pop3SetUser('vmorrison','GoldenAutumnDay')
Remarks:
Pop3SetUser should be called in DEFINE_START of your application.
Running i!-EquipmentMonitor
i!-EquipmentMonitor
13
AMX reserves the right to alter specifications without notice at any time.
2005 AMX Corporation. All rights reserved. AMX, the AMX logo, the building icon, the home icon, and the light bulb icon are all trademarks of AMX Corporation.