?? mylib.doc
字號:
MyLib
________________________________________________________________________________
Introduction:
This instrument driver provides programming support for MyLib.
It contains functions for opening, configuring, taking measurements from, and
closing the instrument.
________________________________________________________________________________
Assumptions:
To successfully use this module, the following conditions must be met:
For GPIB instrument drivers:
- the instrument is connected to the GPIB.
- the GPIB address supplied to the initialize function must match the
GPIB address of the instrument.
For VXI instrument drivers:
- the instrument is installed in the VXI mainframe and you are
using one of the following controller options:
Embedded controller
MXI
MXI2
GPIB-VXI
- the logical address supplied to the initialize function must
match the logical address of the instrument.
For RS-232 instrument drivers:
- the instrument is connected to the RS-232 interface.
- the COM port, baud rate, parity, and timeout supplied to the
initialize function must match the settings of the instrument.
________________________________________________________________________________
Error and Status Information:
Each function in this instrument driver returns a status code that
either indicates success or describes an error or warning condition.
Your program should examine the status code from each call to an
instrument driver function to determine if an error occurred.
The general meaning of the status code is as follows:
Value Meaning
-------------------------------
0 Success
Positive Values Warnings
Negative Values Errors
The description of each instrument driver function lists possible error
codes and their meanings
________________________________________________________________________________
How To Use This Document:
Use this document as a programming reference manual.
It describes each function in the
MyLib
instrument. The functions appear in alphabetical order, with a description
of the function and its C syntax, a description of each parameter, and a list
of possible error codes.
________________________________________________________________________________
Function Tree Layout:
MyLib Function Name:
Systen
Windows Logo SetLogo
Set Windows SHELL program SetStartProgram
Windows Shut off ShutWindows
Time
Set Windows Time and Day SetTime
________________________________________________________________________________
MyLib
功能函數(shù)庫,提供以下幾種功能:
1.改變Windows開機(jī)畫面
2.改變Windows SHELL程序
3.關(guān)閉計(jì)算機(jī)
4.設(shè)置系統(tǒng)時間和日期
________________________________________________________________________________
The following functions are in alphabetical order.
________________________________________________________________________________
SetLogo
int SetLogo (char newfile[], int *hasoldfile);
Parameter List
newfile
Variable Type char []
char[]類型
Windows開機(jī)畫面圖象的文件名,該文件為一個320X400的256色BMP位圖,
如果設(shè)置為空,則表示刪除設(shè)置的開機(jī)畫面,使用Windows本身的開機(jī)畫
面。該參數(shù)可以包括完全的路徑,也可以是相對路徑的文件名。
hasoldfile
Variable Type int (passed by reference)
int *類型
返回是否已經(jīng)設(shè)置過開機(jī)畫面
Return Value
返回值,int類型
0——設(shè)置成功
-1——文件不存在
________________________________________________________________________________
SetStartProgram
int SetStartProgram (char filename[], char oldprogram[]);
Parameter List
filename
Variable Type char []
char[]類型
輸入新的SHELL程序名,不能為空
oldprogram
Variable Type char []
char[]類型
返回舊的SHELL程序名
Return Value
int 類型
保留,始終返回0
________________________________________________________________________________
SetTime
int SetTime (int year, int month, int day, int hour, int minute, int second);
Purpose
Parameter List
year
Variable Type int
int 類型
設(shè)置年,范圍1980~2500
month
Variable Type int
int 類型
設(shè)置月,范圍1~12
day
Variable Type int
int 類型
設(shè)置日,范圍1~31
hour
Variable Type int
int 類型
設(shè)置小時,范圍0~23
minute
Variable Type int
int 類型
設(shè)置分鐘,范圍0~59
second
Variable Type int
int 類型
設(shè)置秒,范圍0~59
Return Value
int 類型
返回狀態(tài):
0——設(shè)置正確
-1——設(shè)置年月日錯誤
-2——設(shè)置時間錯誤
-3——時間和年月設(shè)置都錯誤
________________________________________________________________________________
ShutWindows
int ShutWindows (int shutStyle);
Parameter List
shutStyle
Variable Type int
int 類型
關(guān)機(jī)類型:
0——關(guān)閉電源
1——重新啟動
2——安全退出操作系統(tǒng)
Return Value
int 類型
返回關(guān)機(jī)操作狀態(tài):
0——操作失敗
其它——正確關(guān)機(jī)
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -