Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Labview Code Interface Reference Manual.pdf
Скачиваний:
33
Добавлен:
29.05.2015
Размер:
1.13 Mб
Скачать

Chapter 4 External Subroutines

subroutine files. If it finds the subroutines, LabVIEW performs the appropriate linking. If a file is not found, LabVIEW displays a dialog box prompting you to find it. If you dismiss the dialog box without selecting the file, the VI loads into memory with a broken run arrow, indicating that the VI is not executable.

One way to ensure that LabVIEW can find external subroutines is to place them in the directories that you defined in the search path section of the LabVIEW defaults file. See the Configuring LabVIEW section of Chapter 8, Customizing Your LabVIEW Environment, of your

LabVIEW User Manual for more information on setting path preferences.

Macintosh

THINK C Compiler

The THINK C project must have an extra file named glue.c that specifies each external subroutine. Each reference to the external subroutine should have an entry as follows in the glue.c file:

long gLVSB<external subroutine name> = 'LVSB'; void <external subroutine name>(void);

void <external subroutine name>(void) {

asm {

move.l gLVSB<external subroutine name>, a0

jmp

(a0)

}

}

CodeWarrior 68K Compiler

The CodeWarrior project must have an extra file called glue.c, which specifies each external subroutine. Each reference to the external subroutine should have an entry as follows in the glue.c file:

long gLVSB<external subroutine name> = 'LVSB'; void <external subroutine name>(void);

asm void <external subroutine name>(void) {

move.l gLVSB<external subroutine name>, a0

jmp

(a0)

}

 

© National Instruments Corporation

4-5

LabVIEW Code Interface Reference Manual

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]