beautypg.com

Sendcmds, Sendcmds -19 – Measurement Computing GPIB-488 User Manual

Page 87

background image

Chapter 4

GPIB 488.2 Library Reference

GPIB-488

4-19

Programming Reference Manual

SendCmds

Send GPIB commands.

Syntax

C

SendCmds (int board, char commands[],

unsigned long count)

Parameters

board

is an integer which identifies the GPIB board to be used for this operation. In most

applications, this value is 0.

commands

is a string containing the GPIB command bytes to be sent.

count

specifies the maximum number of command bytes which are to be sent.

Returns

ibsta

will contain a 16-bit status word as described in Appendix B,

IBSTA

.

iberr

will contain an error code, if an error occurred.

Usage Notes

This routine is useful in situations where specialized GPIB command sequences are called for.

Example

The GPIB board (at 0) simultaneously triggers the GPIB devices at addresses 8 and 9 and
quickly puts them in local mode.

C

SendCmds0, "\x3F\x40\x28\x29\x04\x01",6);