beautypg.com

Digilent Port Communications User Manual

Page 6

background image

Digilent, Inc

TM

DPCUTIL Programmer’s Manual

www.digilentinc.com

© Digilent, Inc.

Page

6 of 14


Description
Used to check a specified transaction’s
status. If the transaction is complete, it
will be removed from the status queue
and subsequent calls to
DpcQueryConfigStatus with the same
trid will fail. If the transaction is not
complete, its information will be
returned by reference in a TRS
structure.


BOOL DpcAbortConfigTransaction(HANDLE
hif, TRID trid, ERC * perc)

Parameters
hif

-

handle to JTAG

interface
trid

-

transaction ID to

abort. If 0, then abort ALL transactions
perc

-

pointer to store

error code

Return Values
Returns true if successful. Returns
false otherwise.

Description
Aborts a specified transaction or all
transactions. After a transaction is
aborted, it will remain in the status
queue until read out with
DpcQueryConfigStatus or
DpcClearConfigStatus. Not all
transactions will abort immediately, so
DpcQuery ConfigStatus should be
called afterward to make sure that the
transaction has been terminated.


BOOL DpcClearConfigStatus(HANDLE hif,
TRID trid, ERC * perc)

Parameters
hif

-

handle to JTAG

interface
trid

-

transaction ID to

clear from status queue. If 0, then clear
all completed

transactions.

perc

-

pointer to store

error code

Return Values
Returns true if successful. Returns
false otherwise.

Description
Clears completed transactions from the
status queue. If the trid of a specific
transaction is sent, then that
transaction will be cleared if completed.
If the trid is set as 0, then all completed
transactions will be cleared.


BOOL DpcWaitForTransaction(HANDLE hif,
TRID trid, ERC * perc)

Parameters
hif

-

handle to JTAG

interface
trid

-

transaction ID to

wait on. If 0, then wait for all
transactions to complete.
perc

-

pointer to store

error code

Return Values
Returns true if successful. Returns
false otherwise.

Description
Wait indefinitely on a transaction if its
trid is specified. Wait for all
transactions to complete if trid is 0.
This indefinite block can be broken if
the transaction being waited on is
aborted.



ERC DpcGetFirstError(HANDLE hif)

Parameters
hif

-

handle to JTAG

interface

Return Values
Returns the first error code
encountered in the status queue.

Description
Searches through the status queue for
the first transaction with an error code
set. Returns the error code ercNoError
if no error codes are found.