Raritan Computer SX48 用户手册

下载
页码 172
A
PPENDIX 
H:
 
TCL
 
P
ROGRAMMING 
G
UIDE 
 145 
 
 
ampgetsubscription 
Returns a string listing all user-defined subscriptions.  
ampaddsubscription <event> <url> 
Creates a subscription for the URL to the event specified. The URL encapsulates the service to be used for 
notification, and any parameters required by that service.  
 
% ampgetsubscription 
 
 
 
 
% ampaddsubscription event.user.statusupdate mailto://jsmith@Raritan.com 
subscription added 
 
% ampgetsubscription  
 
% ampsave 
save complete 
 
% ampgetsubscription 
event.user.statusupdate;mailto://jsmith@Raritan.com 
 
amprmsubscription <event> <url> 
Deletes the subscription. 
 
ampping <ip_address> 
Returns true (1) if a response from the IP address is received within the ping timeout, false (0) if not. 
 
ampread <timeout> <terminator> <port> 
Returns a string representing the next chunk of console data up to and including the terminator or the end of 
the data stream when a timeout occurs (in seconds), whichever comes first.   
Note: Issue an ampclear command to clear old data before starting any new operations. The terminator 
can be a multi-character (up to 32) string specified in quotes. 
 
ampwrite <string> <port> 
Writes the string to the console (the script must first lock the write access using amplock). 
  
ampclear <port> 
Clears the buffer from which ampread and ampexec read. 
 
ampexec <string> <timeout> <terminator> <port>_<number> 
A convenience routine: writes the string to the console and then reads the response until the terminator OR 
timeout occurs. A typical terminator can be the system prompt to indicate the completion of an execution. 
The response is returned as a string. 
Has returned NULL 
because there are no 
user-defined 
subscriptions 
Has returned NULL 
because ampsave 
command has not 
yet been executed