Amanda Work Place Instructions Manual
Have a look at the manual Amanda Work Place Instructions Manual online for free. It’s possible to download the document as PDF or print. UserManuals.tech offer 32 Amanda manuals and user’s guides for free. Share the user manual or guide on Facebook, Twitter or Google+.
Chapter 11: Programming Amanda 113 O( time) Command that makes Amanda go on-hook for the specified amount of time. Depending upon the value used, you can cause a hookflash or a hang-up. This is particularly useful for generating an intermediate hang-up condition during token processing without ter- minating the actual continued token processing. See also the H() command. timeA number in tenths of seconds or a variable containing that number. Example: O(20) causes Amanda to go on-hook for two seconds. Failure: Does not fail %PSystem variable that contains the previous mailbox, that is, the last mailbox accessed be- fore the current mailbox. Each port has its own %P. See also %U (current mailbox). Example: While accessing mailbox 990, %U is 990. Then a caller enters 222 and is transferred to that extension. As mailbox 222 is accessed, %U becomes 222, and %P becomes 990. P [ repetition] ( date,D) Command that tells Amanda to say the specified number as a date. repetitionThe number of times to repeat the date. The default is 1. dateA number in either of the following formats: MMDDYY (which assumes the year 19YY,) or MMDDYYYY. For dates after 1999, you must use MMDDYYYY. Despite this format, the date is read in the order that most speakers of the prompt lan- guage (specified using the Setup utility) expect to hear it. If the year is the current year, Amanda does not read the year. Example:P(06261994,D) causes Amanda to say June twenty-sixth, nineteen ninety-four Failure: Does not fail P [ repetition] ( amount, currency) Command that tells Amanda to say the specified number as an amount of money. repetitionThe number of times to repeat amount. The default is 1. amountA number from 0 to 999 million. currencyUse one of the following: $For dollars and cents. FFor francs and centimes. PFor pesos and centavos. Example: P(06261994,$) cause Amanda to say Sixty-two thousand six hundred nineteen dollars and ninety-four cents Usually when using F or P, the system language is French or Spanish. However, the monetary terms are always available, regardless of the system language. Failure: Does not fail Alphabetical Token Reference (Continued) Token SyntaxDescription
114 Installing [email protected] P [ repetition] ( number,N) Command that tells Amanda to say the absolute value of the number. repetitionThe number of times to repeat absolute value. The default is 1. numberA number or variable representing a number from 0 to 999 million. N OTE: Use a condition to test whether the number is positive or negative. Use a greeting that says “negative” or “minus” to handle negative numbers. Examples: Suppose that %S1 contains -1234 and G1 contains the recording “negative,” then I(%S1,>,0,1001)P(G1)P(%S1,N) causes Amanda to say “negative one thousand two hundred thirty-four”. (mailbox 1001’s Extension field would not include the greeting—just the command, P(%S1,N)) P(06261994,N) causes Amanda to say “Six million two hundred sixty-one thousand nine hundred nine- ty-four.” Failure: Does not fail P [ repetition] ( time,T) Command that tells Amanda to say the specified number as a time of day. repetitionThe number of times to repeat the contents of the port variable. The default is 1. timeA number or variable containing a number that specifies a time in the 24-hour HHMM format. However, Amanda says the time in a 12-hour format, followed by A.M. or P.M. Example:P(1826,T) causes Amanda to say “Six, twenty-six P.M.” Failure: Does not fail P [ repetition] (A, string) Command that tells Amanda to say the characters in the specified string. For a space, Amanda says the word “space”. repetitionThe number of times to repeat the contents of the string. The default is 1. stringA string of letters from the alphabet and spaces. Example:P(A,GEORGE BEST) causes Amanda to say “G,” “E,” “O,” “R,” “G,” “E,” “space,” “B,” “E,” “S,” “T.” Failure: Does not fail P [ repetition] (D) Command that tells Amanda to say the percentage of remaining disk space. repetitionThe number of times to repeat the percentage of disk space. The default is 1. Examples: P(D) causes Amanda to say “The percentage of free disk space is” followed by the percentage as a number, e.g., forty-two. Failure: Does not fail P [ repetition] ( greeting [, mailbox]) Command that tells Amanda to play the specified greeting for the specified or current mailbox. repetitionThe number of times to repeat the greeting. The default is 1. greetingOne of the seven mailbox greetings (G1–G7). mailboxOptional. Any valid mailbox or a variable containing a mailbox. The default is the current mailbox. Example:P(G1) causes Amanda to play Greeting 1 for the current mailbox. Failure: Invalid mailbox Alphabetical Token Reference (Continued) Token SyntaxDescription
Chapter 11: Programming Amanda 115 P [ repetition] (M [, mailbox]) Command that tells Amanda to say the total number of messages for the specified or cur- rent mailbox. Using this command cancels any pending Notify actions for the specified message auto- matically. When this command plays a message that is marked with Receipt Verification, the veri- fication message’s From field contains the mailbox which executed this command. repetitionThe number of times to repeat the number of messages. The default is 1. mailboxOptional. Any valid mailbox or a variable containing a mailbox. The default is the current mailbox. Example:P(M,212) causes Amanda to say the total number of messages for mailbox 212. Failure: Invalid mailbox P [ repetition] (M n[, mailbox]) Command that tells Amanda to play the message with the specified number for the spec- ified or current mailbox. repetitionThe number of times to repeat the message. The default is 1. nThe number of the message to be played. mailboxOptional. Any valid mailbox or a variable containing a mailbox. The default is the current mailbox. Example:P3(M1,212) causes Amanda to play message 1 for mailbox 212 three times. Failure: Invalid mailbox P [ repetition] (N [, mailbox]) Command that tells Amanda to play the Name/Extension recording of the specified or current mailbox. If there is no recording, nothing is played. See also P[repeti- tion](U[,mailbox]). repetitionThe number of times to repeat the Name/Extension recording. The default is 1. mailboxOptional. Any valid mailbox or a variable containing a mailbox. The default is the current mailbox. Example:P(N) causes Amanda to play the Name/Extension recording for the current mailbox. Failure: Invalid mailbox P [ repetition] ( DTMF) Command that tells Amanda to say a number as DTMF digits. This is usually used for repeating the number corresponding to the DTMF tones entered by a caller. repetitionThe number of times to repeat the DTMF digits. The default is 1. DTMFA number or variable containing a series of DTMF digits. Example:P(%S5) causes Amanda to say the DTMF digits in %S5. For example, if %S5 contains the num- ber 411, Amanda says 4–1–1 instead of four hundred eleven. Failure: Does not fail Alphabetical Token Reference (Continued) Token SyntaxDescription
116 Installing [email protected] P [ repetition] ( prompt_no,V) Command that tells Amanda to look for the specified prompt number in the current sys- tem language file. Then Amanda plays the prompt associated with that number. repetitionThe number of times to repeat the prompt. The default is 1. prompt_noThe number or variable containing the number for the prompt. The current range is from 1 to 477. (For some languages, some of the prompt numbers reference blank messages.) Example:P2(15,V) causes Amanda to play prompt number 15 twice. Failure: Does not fail P [ repetition] (R) Command that tells Amanda to say the DTMF digits entered by a caller who requested relay paging notification. (These digits are stored in %R.) This command can be used in either field, but makes the most sense when used in a No- tify Method field. repetitionThe number of times to repeat the DTMF digits. The default is 1. Example:P(R) causes Amanda to say the DTMF digits stored in the system variable %R. You can also use: P(%R) Failure: Does not fail P [ repetition] (U [, mailbox]) Command that tells Amanda to play the Name/Extension recording of the specified or current mailbox. If there is no recording, Amanda says “mailbox,” followed by the dig- its for the mailbox. See also P[repetition](N[,mailbox]). repetitionThe number of times to repeat the Name/Extension recording. The default is 1. mailboxOptional. Any valid mailbox or a variable containing a mailbox. The default is the current mailbox. Example:P(U) causes Amanda to play the Name/Extension recording for the current mailbox. If it doesn’t exist, Amanda says the digits for the mailbox. Failure: Invalid mailbox P [ repetition] (V) Command that tells Amanda to say the digits in the Variable field of the Notification record. repetitionThe number of times to repeat the contents of the Variable field. The default is 1. Example:P2(V) causes Amanda to say the digits in the Variable field twice. The following also works: P2(%V) Failure: Does not fail P [ repetition] (X, file) Command that tells Amanda to play a voice file. repetitionThe number of times to repeat the contents of the file. The default is 1. fileA string or variable containing the name of a voice file. Use the complete path to the file unless the file is in C:\AMANDA. The file can be one recorded using the KR() command, an Amanda message file, or a voice file copied to the Amanda system. However, the copied file must have the same sampling rate as Amanda voice files. The sampling rate is the value of the adpcm_nq system configuration option. This op- tion’s default is 32 kilobytes. Example:P(X,C:\\SAMPLE.VOX) retrieves SAMPLE VOX from the root directory, and plays it. Failure: Does not fail Alphabetical Token Reference (Continued) Token SyntaxDescription
Chapter 11: Programming Amanda 117 Q( { greeting [# mailbox] [,E ]}) Command that allows you to ask a caller a series of questions and store all the caller’s responses as a single message for the current mailbox. Each question is recorded as a greeting which Amanda plays back with a tone. Then Amanda records a response and goes on to the next question. Up to 20 questions are allowed. To ask more than 7 ques- tions (after using Greetings 1 to 7 for the current mailbox) you can use greetings from other mailboxes by specifying which mailbox’s greeting to access with a # sign fol- lowed by the mailbox, e.g., G7#123 would use greeting 7 from mailbox 123. You use the Q() command to create voice forms or implement some IVR applications. This command is used only in Extension fields. greetingOne of the seven mailbox greetings (G1–G7). mailboxOptional. Any valid mailbox. The default is the current mailbox. E Gives the caller the opportunity to edit (review, rerecord, append, or cancel) the previous group of answers. If additional token language processing is required after the caller has hung up, use the H token as part of the token string. Examples: Q(G1,G2,G3,G4,G5,G6,G7,G1#9000,G2#9000) causes Amanda to ask 9 questions recorded in the specified greetings, record 9 respons- es, and store the responses as one message for the current mailbox, regardless of what mailbox’s provide the greetings. Q(G1,G2,G3,E) records three answers from the caller and then gives the caller an opportunity to review those answers as if they were one message. When editing, a menu gives the caller the options of re-recording, appending to or canceling the answers of that group. Q(G1,G2,E,G3,G4,E) asks the caller two questions and then allows the caller to edit those answers. Once the caller presses 9 to save, Amanda asks the next two questions and then allows the caller to edit the second group of answers. NOTE: While editing, pressing 4 to cancel erases all the previous answers (not just those in the group being edited) and restarts the Q() command. Failure: Invalid mailbox Invalid greeting Alphabetical Token Reference (Continued) Token SyntaxDescription
118 Installing [email protected] %RSystem variable (the relay variable) that contains the DTMF digits entered by the caller who requested relay paging notification. Each port has its own %R. See the notification chapter in Administering [email protected]. This is primarily used to send up to 16 digits of information to a user’s pager/beeper. This token is used only in Notify Method fields. Example: 9,%VW(9,V)P(U)P(R) causes Amanda to call someone at home and say the telephone number and other infor- mation in the relay variable. R( greeting [# mailbox], variable [, timeout]) Command that plays a greeting from the current or specified mailbox and stores the call- er’s DTMF entry as a number in the specified variable. The greeting is interrupted as soon as the first DTMF tone is entered. If there is no DTMF entry or if the timeout oc- curs, the variable is set to the empty string. greetingOne of the seven mailbox greetings (G1–G7). mailboxOptional. Any valid mailbox. The default is the current mailbox. variableOne of the port or global variables. timeoutA number from 0 to 99 that represents the time in tenths of seconds to wait for a DTMF entry after playing the greeting. The default is 1.2 seconds. Example:R(G1,%S6,20) stores a telephone number entered by a caller for later use. Greeting 1 is “Enter your telephone number, finish by pressing the # sign.” The caller’s entry is stored as a number in the port variable %S6. Amanda waits two seconds after the greeting before deciding that the caller is not going to enter a telephone number. R(G1#111,%S1) plays Greeting 1 of mailbox 111. The DTMF digits entered by the caller become the val- ue of %S1. Failure: Invalid mailbox Invalid greeting %S0 %S1 %S2 %S3 %S4 %S5 %S6 %S7 %S8 %S9 %S10 %S11 %S12 %S13 %S14 %S15 %S16 %S17 %S18 %S19Each telephone port has its own set of 20 %S variables where you can store, modify, or retrieve information. One port’s %S1 is not the same as another port’s %S1. If Port 1 changes %S1, it does not change the value of Port 2’s %S1. Initially, each variable is equal to the empty string. Each variable can contain a string of up to 143 characters. See also %G0–%G9. NOTE: The [(), ](), and |() commands can be used only with %S0 through %S9. The variables %S10 through %S19 cannot be read from, written to, or appended to any DOS file. Example: +(%S0,5) adds five to the current value of %S0. =(%S12,714) assigns the area code 714 to %S12. I(%S12=714,555) causes Amanda to go to the Extension field for mailbox 555 because the condition is true (%S12 does equal 714). Failure: Invalid variable name (such as %S52) Alphabetical Token Reference (Continued) Token SyntaxDescription
Chapter 11: Programming Amanda 119 S( port, [ string], [ variable], [ termination], [ length], [ timeout]) Command that gives Amanda access to other computers via the serial ports. Amanda can send a string to and/or receive a string from the remote computer. When receiving, Amanda terminates the connection when the first of the following occurs: Amanda receives the specified termination string She receives the maximum number of characters A timeout occurs When sending, Amanda terminates the connection after the string is sent. Before using this command, make sure the configuration settings for the physical serial port have been defined. portThe number for or a variable containing the number for the logical serial port (1,2,3,4) mapped onto a physical COM port by the configuration option serial_port1, serial_port2, serial_port3, or serial_port4. stringOptional. A string or variable containing the characters to send to the specified serial port. It can contain alphanumeric characters as wells as variables and the following special characters: \A Attention, which is a bell sound (Ctrl+G) \N Newline (Ctrl+J) \R Return (Ctrl+M) \T T AB (Ctrl+I) \\ Backslash, the actual \ character. The default is to send no string to the serial port. variableOptional. The port or global variable that stores the response. The default is not to store a response. terminationOptional. A string or variable that defines the characters that, when read, stop Aman- da from reading the serial port. This can use the same special characters as string. The default is \R\N, the carriage return/linefeed pair that usually end a line in a text file. The terminating character, if any, does not become part of variable. lengthOptional. A number or a variable containing a number. Its absolute value defines the maximum number of characters to receive over the serial port. The default is -143. Use a positive value for length when you are receiving a packet of characters, you know its exact size, and you want the command to fail if fewer characters are re- ceived. Use a negative number otherwise. timeoutOptional. A number or variable that defines the maximum time, in seconds, that Amanda should wait for the first character and also between characters being received on the serial port. The default is the setting for the configuration option tmo_serial. Example: S(2,%S3,%S4,,,50) both sends and receives. The command uses COM port 2. %S3 stores the string to be sent. %S4 stores the string that is received. Amanda waits a half second for the first character and between characters. S(2,%S3) only sends. The command uses COM port 2. %S3 stores the string to be sent. This com- mand has non-standard syntax. Because all the parameters after the string to be sent are not being used, this command does not need the additional commas. S(2,,%S4,,,50) only receives. The command uses COM port 2. %S4 stores the string that is received. Amanda waits a half second for the first character and between characters. Failure: Physical port not available Logical port not configured properly If a timeout stops Amanda from receiving information before the maximum number of characters is received and the length is a positive number, Amanda considers the com- mand a failure. Alphabetical Token Reference (Continued) Token SyntaxDescription
120 Installing [email protected] %TSystem variable that contains the current connect time, the number of seconds that the current port/call has been active. Each port has its own %T. Examples: P(% T,N) causes Amanda to say the amount of connect time as a number. See the P() command for more information. T( file, phone_no [, tokens]) Command that sends faxes to either a specified telephone number or to a connected call. Before using this command, be sure at least one fax modem is installed and configured on Amanda. Before using this command, make sure the configuration settings for the physical serial port have been defined. fileThe file name of the fax you wish to transmit. It can be any valid DOS file name. Use the complete path to the file unless the file is in C:\AMANDA. phone_noThe telephone number (or a variable containing that number) for the fax device that ac- cepts the transmission. Use the empty string to make Amanda wait for a call to ring into the fax port. tokensOptional. A string or variable that defines the actions Amanda takes to connect the call to the fax port. For more information, please see the example for the J() command. This command is used only in Extension fields. Examples: T(C:/FAXES/NEWINFO.FAX,%G6) allows the user to request a fax and have the supplier of that fax send it to the provided telephone number. This is commonly called a “two-call fax back”. NEWINFO.FAX is the name of the file, and %G6 contains the fax telephone number. T(C:/FAXES/NEWINFO.FAX,,%S5) allows the user to request a fax and have it sent as part of the current call. This is com- monly called a “one-call fax on demand”. NEWINFO.FAX is the name of the file, and %S5 provides the tokens that connect the call to the FAX port. Failure: Fax modem not configured properly Physical port not available Logical port not configured properly %USystem variable that contains the current mailbox number. Each port has its own %U. See also %P. U- ext_noCommand that performs partially supervised transfers. Amanda does not transfer the call if she detects a busy signal. To use the U token, the setting for Maximum Rings for the mailbox must be set to 1. ext_noSeries of DTMF digits that indicate an extension number. This command is used only in Extension fields. Example: U-144 causes Amanda to call extension 144 (if Amanda is processing a call). If the extension rings, she transfers the call and hangs up. If the extension is busy, Amanda lets the caller know that. Failure: Does not fail %VSystem variable that contains the value of the Variable field in the current Notification record. Each port has its own %V. This token is used only in Notify Method fields. Example: If the only difference in a Notification template for mailboxes is the pager/beeper tele- phone number that Amanda should call, %V can store that number. 9,%VW(3,P)%U*%M*%N# causes Amanda to call the user and play the number of messages. Alphabetical Token Reference (Continued) Token SyntaxDescription
Chapter 11: Programming Amanda 121 V( file, field, value{, field, variable})Command that searches the specified file for the first record that has the specified value in the specified field. It retrieves values from up to 8 other fields in that record, putting the retrieved values in the specified variables. See also the N() command. fileA string or variable containing a valid DOS file name for the text or .DBF file. Use the complete path to the file unless the file is in C:\AMANDA. No line in the file should ex- ceed 143 characters. There is no limit to the number of lines in the file. fieldA number, string, or variable that indicates the number or name of a field. The first field indicates what field to compare with value; the additional (up to 8) fields indicate what fields to copy into the corresponding variables. (.DBF files have field names; text files have field numbers.) valueA string or variable that contains the data to be compared with the contents of the spec- ified field. variableOne of port or global variables. Example:V(C:\\LISTS\\PHONE.LST,1,JOHN,3,%S1,2,%S2) searches the file PHONE.LST for the value JOHN in field 1. If the search is successful, the value in field 3 of that record is stored in %S1 and the value in field 2 is stored in %S2. Failure: If no record is found %WSystem variable that contains the day of the week (1 is Sunday, and 7 is Saturday). W( n, [ event [, mailbox]]) Command that tells Amanda to: Wait a number of tenths of a second Wait for an event, such as a dial tone or another appropriate answer. If the event does not occur, Amanda goes to the specified mailbox. nWithout an event parameter (P, V, or T), a number of tenths of a second. For dial tone (T), the number of seconds. For pager (P) and voice (V), the number of rings to wait before continuing. If n is 0 for pager or voice, the 0 is replaced with the value of rmt_rna, a configuration option that you define using the Setup utility. eventThe event that Amanda waits for: P A pager answer V A voice answer T The dial tone mailboxAny valid mailbox or a variable containing a mailbox. Specifies the mailbox to which control should be transferred if the event does not occur. Examples:W(3) makes Amanda pause for 3 tenths of a secondW(3,P) makes Amanda wait up to three rings for a paging/beeping system to answer. Use this to confirm that the paging company answered before playing the DTMF digits to be dis- played on the pager. W(4,V,111) makes Amanda wait up to four rings for a voice. If a voice is detected, processing con- tinues with the next token. Otherwise, control is transferred to mailbox 111. Failure: Invalid mailbox Event does not occur and no mailbox is specified %XSystem variable that contains the codes needed to get the transfer dial tone on the current port. Each port has its own %X. This is the setting of the dl-dtwait configuration option (usually F-). Alphabetical Token Reference (Continued) Token SyntaxDescription
122 Installing [email protected] X [( file) ] Command that creates the specified file or LIGHT.ON. Used in conjunction with the Y() and Z() commands, this command can control Amanda’s processing of tokens. fileA string or variable containing a valid DOS file name for a text file. The default is to create the file LIGHT.ON in the mailbox’s directory. Example: A user’s message waiting indicator toggles on and off. For the first message, Amanda should turn the indicator on. The indicator should be left on for the second and later messages (until they are all listened to). So you use: Z() to check whether the indicator is on or not (if LIGHT.ON exists, the indicator is on). X() to create the LIGHT.ON file when a message arrives and the indicator is not on. Y() to delete LIGHT.ON when the indicator is turned off because the user has listened to all the messages. Failure: Does not fail %YSystem variable that contains the current date in American format: MMDDYYYY. Example: P(%Y,D) causes Amanda to say the current date (contained in %Y) as a date. See the P() command for more information. Y [( file) ] Command that deletes the specified file or LIGHT.ON. fileA string or variable containing a valid DOS file name for a text file. The default is to delete the file LIGHT.ON in the mailbox’s directory. Example: Y(C:\\AMANDA\\FOOBAR.TXT) causes Amanda to delete FOOBAR.TXT. See also the X() command. Failure: Does not fail %ZSystem variable that contains the current time in 24-hour format: HHMM. Example: P(%Z,T) causes Amanda to say the current time (contained in %Z) as a time. See the P() command for more information. Z [( file) ] Command that tests for the existence of the specified file or LIGHT.ON. If the file is there, Amanda immediately stops processing the rest of the tokens for this mailbox. Otherwise, the next token is executed. fileA string or variable containing a valid DOS file name for a text file. The default is to delete the file LIGHT.ON in the mailbox’s directory. Example: Z()X() causes Amanda to check for LIGHT.ON. If it is not there, the X() command causes Amanda to create it. See also the X() command. Failure: Does not fail Alphabetical Token Reference (Continued) Token SyntaxDescription