GpibFindListener


Function

The partner apparatus connected is searched and an address is acquired.

Format

Ret = GpibFindListener ( Id, PrmAddr, ScdAddr, ArraySize, AddrArray )

Parameter

Id [ VB.NET: Short ][ C, C++: short ][ C#: short ]

Specifies DevID or EqpID.

Whichever it specifies, operation does not change.

 

PrmAddr [ VB.NET: Short ][ C, C++: short ][ C#: short ]

Specifies primary address to search.

 

-1

All primary address are searched.

0 to 30

The selected primary address is searched.

 

ScdAddr [ VB.NET: Short ][ C, C++: short ][ C#: short ]

Specifies secondary address to search.

 

-1

All secondary address are searched.

0

a secondary address is not searched.

96 to 126

The selected secondary address is searched.

 

ArraySize [ VB.NET: Short ][ C, C++: short * ][ C#: ref short ]

The size of AddrArray is specified and the number of elements is acquired.

 

IN

1 to

The size of AddrArray is specified

OUT

 

The detected number partner apparatus.

 

AddrArray [ VB.NET: Short() ][ C, C++: short * ][ C#: short[] ]

The address of the arrangement which stores the GPIB address of the detected apparatus is specified.

Return Value

Ret [ VB.NET: Integer ][ C, C++: long ][ C#: int ]

 

0

Normality completion

10001

Invalid ID was specified
Please use the ID retrieved by initialization in functions

10002

Driver can not be called
Please perform initialization at first

13202

The value of PrmAddr is outside the designated range

13203

The value of ScdAddr is outside the designated range

13214

Pointer to ArraySize is NULL

13215

Pointer to AddrArray is NULL

13240

Asynchronous function is running now

23243

Device beyond ArraySize is detected

 

Initial Value

None

Remarks

With this function, when GpibSendIFC is not being performed after initialization, IFC is outputted automatically.

The address of a self opportunity is not stored in arrangement.

Example

C

short PrmAddr, ScdAddr, ArraySize, AddrArray[30];

PrmAddr = -1;

ScdAddr = 0;

ArraySize = 30;

Ret = GpibFindListener ( Id, PrmAddr, ScdAddr, &ArraySize, AddrArray);

See Also