FLUKE 190 Family Remote Control & Programming Reference 电路图.pdf

上传人:cc518 文档编号:200782 上传时间:2025-03-08 格式:PDF 页数:120 大小:356.38KB
下载 相关 举报
FLUKE 190 Family Remote Control & Programming Reference 电路图.pdf_第1页
第1页 / 共120页
FLUKE 190 Family Remote Control & Programming Reference 电路图.pdf_第2页
第2页 / 共120页
FLUKE 190 Family Remote Control & Programming Reference 电路图.pdf_第3页
第3页 / 共120页
亲,该文档总共120页,到这儿已超出免费预览范围,如果喜欢就下载吧!
资源描述

《FLUKE 190 Family Remote Control & Programming Reference 电路图.pdf》由会员分享,可在线阅读,更多相关《FLUKE 190 Family Remote Control & Programming Reference 电路图.pdf(120页珍藏版)》请在收音机爱好者资料库上搜索。

1、 REMOTE CONTROL AND PROGRAMMING REFERENCE for the FLUKE 190 family of ScopeMeter test tools = This file contains remote control and programming information for the above-mentioned models with use of the PM9080 Optically Isolated RS232 Adapter/Cable. It consists of the following chapters: 1. INSTALLI

2、NG THE PM9080 2. INTRODUCTION TO PROGRAMMING 3. COMMAND REFERENCE APPENDIXES APPENDIX A ACKNOWLEDGE DATA APPENDIX B STATUS DATA APPENDIX C WAVEFORM DATA APPENDIX D ASCII CODES RadioFans.CN 收音机爱 好者资料库 Page 1.1 = 1. INSTALLING THE PM9080 - Connect the PM9080 to the RS232 port of the computer. If neces

3、sary, use a 9-pin to 25-pin adapter and 25-pin gender changer. - Hook the PM9080 cable to the ScopeMeter. - Turn on the computer and the ScopeMeter. - Make sure that the communication settings match for the RS232 port of the computer and the ScopeMeter. After power-on, the default settings of the Sc

4、opeMeter are as follows: 1200 baud, No parity, 8 data bits, 1 stop bit You can modify the baud rate with the PC (Program Communication) command. See chapter 3 COMMAND REFERENCE. Other settings are fixed. You can modify the computer RS232 port settings to match the above ScopeMeter settings with the

5、following DOS command: MODE COM1:1200,N,8,1 This command assumes that COM1 is the RS232 port used on the computer. Replace COM1 in the above command with COM2, COM3, or COM4 if one of these ports is used. You can place this command in the computer startup file AUTOEXEC.BAT so that the default settin

6、gs for the computer are the same as for the ScopeMeter. If you want to use a higher data transfer speed (baud rate), let your QBASIC program change the settings for both the computer and the ScopeMeter. See the example under the PC (Program Communication) command in chapter 3 COMMAND REFERENCE. Radi

7、oFans.CN 收音机爱 好者资料库 Page 2.1 = 2. INTRODUCTION TO PROGRAMMING * Basic Programming Information * When you have installed the PM9080 as described in the previous chapter, you can control the ScopeMeter from the computer with simple communication facilities, such as GWBASIC, QuickBASIC and QBASIC (prog

8、ramming languages from Microsoft Corporation). All examples given in this manual are in the QBASIC language but will also run in QuickBASIC. QuickBASIC allows you to make executable files from programs so you can start such programs directly from DOS. It is assumed that you have knowledge of these p

9、rogramming languages. QBASIC is supplied with Microsoft MS-DOS 5.0 and higher and Windows 95, 98, and NT, including on-line Help. Features of the syntax and protocol for the ScopeMeter are as follows: - Easy input format with a forgiving syntax: All commands consist of two characters that can be UPP

10、ER or lower case. Parameters that sometimes follow the command may be separated from it by one or more separation characters. - Strict and consistent output format: Alpha character responses are always in UPPERCASE. Parameters are always separated by a comma (, = ASCII 44, see Appendix D). Responses

11、 always end with the carriage return code (ASCII 13). Because the carriage return code is a non-visible character (not visible on the screen or on paper), this character is represented as in the command syntax. - Synchronization between input and output: After receipt of every command, the ScopeMete

12、r returns an acknowledge character (digit) followed by the carriage return code (ASCII 13). This indicates that the command has been successfully received and executed. The computer program must always read this acknowledge response before sending the next command to the ScopeMeter. RadioFans.CN 收音机

13、爱 好者资料库 Page 2.2 * Commands sent to the ScopeMeter * All commands for the ScopeMeter consist of a header made up of two alpha characters sometimes followed by parameters. Example: RI This is the Reset Instrument command. It resets the ScopeMeter. Some of the commands are followed by one or more para

14、meters to give the ScopeMeter more information. Example: SS 8 This is the Save Setup command. It saves the present acquisition settings in memory. The SS header is followed by a separator (space), then followed by the parameter 8 to indicate where to store the settings. The meaning of this parameter

15、 is described in Chapter 3 COMMAND REFERENCE. Some commands require several parameters. Example: WT 9,50,30 This is the Write Time command. This command requires three parameters. The parameters are separated by a comma, which is called the Program Data Separator. You may use only one comma between

16、the parameters. Also refer to the section Data Separators. A code at the end of each command tells the ScopeMeter that the command is ended. This is the carriage return code (ASCII 13) and is called the Program Message Terminator. This code is needed to indicate to the ScopeMeter that the command is

17、 completed so it can start executing the command. Also refer to the section Command and Response Terminators. Page 2.3 * Responses received from the ScopeMeter * After each command sent to the ScopeMeter there is an automatic response from it, indicated as (which you MUST input), to let the computer

18、 know whether or not the received command has been successfully executed. Refer to the Acknowledge section below. There are several commands that ask the ScopeMeter for response data. Such commands are called Queries. Example: ID This is the IDentification query, which asks for the model number and

19、the software version of the ScopeMeter. When the ScopeMeter has received a query, it sends the reply as it does after any command, but now it is followed by the queried response data. The format of the response data depends upon which query is sent. When a response consists of different response dat

20、a portions, these are separated with commas (ASCII code 44). Also refer to the section Data Separators. All response data, as well as following (queried) response data are terminated with the carriage return code ( = ASCII 13). Also refer to the section Command and Response Terminators. Page 2.4 * A

21、cknowledge * After receiving of a command, the ScopeMeter automatically returns the response to let the computer know whether or not the received command has been successfully executed. This response is a one-digit number followed by as response terminator. If is 0, it indicates that the ScopeMeter

22、has successfully executed the command. If the command was a query, the response is immediately followed by the queried response data terminated with . If is 1 or higher, it indicates that the ScopeMeter has not executed the command successfully. In that case, if the command was a query, the response

23、 is NOT followed by any further response data. There can be several reasons for a non-zero response. For more information see Appendix A. In case of an error you can obtain more detailed status information by using the ST (STATUS) query. Note: YOU MUST ALWAYS INPUT , EVEN WHEN THE COMMAND WAS NOT A

24、QUERY. Page 2.5 * Data Separators * Data Separators are used between parameters sent to the ScopeMeter and between values and strings received from the ScopeMeter. Comma (,) is used as program data separator as well as response data separator: - Program Data Separator Name Character ASCII Value Comm

25、ents Decimal - comma , 44 Single comma allowed - Response Data Separator Name Character ASCII Value Comments Decimal - comma , 44 Page 2.6 * Command and Response Terminators * (Message Terminators) - Command (Program Message) Terminators A code is needed at the end of each command to tell the ScopeM

26、eter that the command is ended, and that it can start executing the command. This code is called the Program Message Terminator. The code needed for the ScopeMeter is carriage return (ASCII code 13 decimal). Notes: 1. The carriage return code is a non-visible ASCII character. Therefore this code is

27、represented as in the Command Syntax and Response Syntax lines given for each command. 2. The QBASIC programming language, which is used for all program examples, automatically adds a carriage return to the end of the command output. (In the QBASIC language, this is the PRINT #. statement.) After is

28、 recognized by the ScopeMeter, the entered command is executed. After EACH command the ScopeMeter returns to the computer to signal the end of the command processing (also see the section Acknowledge.) - Response (Message) Terminators The response from the ScopeMeter ends with a carriage return (ASC

29、II 13). This is indicated as in the Response Syntax for each command. Page 2.7 * Typical program sequence * An example A typical program sequence consists of the following user actions: 1. Set the communication parameters for the RS232 port of the computer to match the ScopeMeter settings. 2. Output

30、 a command or query to the ScopeMeter. 3. Input the acknowledge response from the ScopeMeter. If the response value is zero, go to step 4. If the response value is non-zero, the ScopeMeter did not execute the previous command. Read the error message from the following acknowledge subroutine, recover

31、 the error, and repeat the command or query. (This is not shown in the following program example.) 4. If a query was output to the ScopeMeter, input its response. 5. The sequence of points 2, 3, and 4 may be repeated for different commands or queries. 6. Close the communication channel. Refer to the

32、 program example on the next page. Page 2.8 Example of a typical program sequence: * Begin example program * OPEN COM1:1200,N,8,1,CS,DS,RB2048 FOR RANDOM AS #1 This QBASIC program line sets the parameters for the RS232 port (COM1 on the Computer) to match the ScopeMeter power-on default settings. It

33、 also opens a communication channel (assigned #1) for input or output through the COM1 port. Your ScopeMeter must be connected to this port. RB2048 sets the size of the computer receive buffer to 2048 bytes to prevent buffer overflow during communication with the ScopeMeter. PRINT #1, ID Outputs the

34、 IDENTITY command (query) to the ScopeMeter. GOSUB Acknowledge This subroutine inputs the acknowledge response from the ScopeMeter and displays an error message if the acknowledge value is non-zero. INPUT #1, Response$ This inputs the response data from the IDENTITY query. PRINT Response$ Displays t

35、he queried data. CLOSE #1 This closes the communication channel. END This ends the program. Page 2.9 * Acknowledge subroutine * Use this subroutine after each command or query sent to the ScopeMeter. This routine inputs the acknowledge response from the ScopeMeter. If the response is non-zero, the p

36、revious command was not correct or was not correctly received by the ScopeMeter. Then an error message is displayed and the program is aborted. Acknowledge: INPUT #1, ACK Reads acknowledge from ScopeMeter. IF ACK 0 THEN PRINT Error ; ACK; : ; SELECT CASE ACK CASE 1 PRINT Syntax Error CASE 2 PRINT Ex

37、ecution Error CASE 3 PRINT Synchronization Error CASE 4 PRINT Communication Error CASE IS 4 PRINT Unknown Acknowledge END SELECT PRINT Program aborted. END END IF RETURN * End example program * Page 3.1 = 3. COMMAND REFERENCE CONVENTIONS * Page layout used for each command * - Header Each command de

38、scription starts on a new page with a header for quickly finding the command. This header indicates the command name and the two-character header used for the command syntax. Example: = AUTO SETUP AS - Where AUTO SETUP is a descriptive name for the command (this is no syntax!), and AS are the first

39、two characters used for the command syntax (not the complete syntax). - Purpose: Explains what the command does or what it is used for. - Command Syntax: Shows the syntax for the command. Parameters are separated by commas. Commands are terminated by (carriage return). - Response Syntax: Shows the f

40、ormat of the response from the ScopeMeter. Responses are terminated by (carriage return). Each Response Syntax starts with the response, followed by the query response if the syntax relates to a query. - Example: This is an example QBASIC program which shows how you can use the command. The example

41、may also include some other commands to show the relation with these commands. The following two comment lines (start with ) successively indicate the beginning and the end of an example program. * Begin example program * * End example program * Page 3.2 Use an MS-DOS Editor and copy the complete pr

42、ogram between these two lines to a file name with the .BAS extension. Start QBASIC and open this file from the FILE menu. Long programs (longer than 55 lines) include page breaks. Such page breaks are preceded by the (remark) character to prevent the QBASIC interpreter from interpreting them as an i

43、ncorrect statement. When you have connected the ScopeMeter, you can start the program from the RUN menu. Page 3.3 * Syntax conventions * The Command Syntax and the Response Syntax may contain the following meta symbols and data elements: UPPERCASE These characters are part of the syntax. For commands, lower case is also allowed.

展开阅读全文
相关资源
猜你喜欢
相关搜索
资源标签

当前位置:首页 > 仪器仪表 > Fluke

copyright@ 2008-2025 收音机爱好者资料库 版权所有
备案编号:鄂ICP备16009402-5号