beautypg.com

Digilent Port Communications User Manual

Page 8

background image

Digilent, Inc

TM

DPCUTIL Programmer’s Manual

www.digilentinc.com

© Digilent, Inc.

Page

8 of 14

rgbSend[0]

TDI 8

TDI 7

TDI 6

TDI 5

TDI 4

TDI 3

TDI 2

TDI 1

rgbSend[1]

TDI 16

TDI 15

TDI 14

TDI 13

TDI 12

TDI 11

TDI 10

TDI 9

perc

-

pointer to store

error code
ptrid

-

pointer to store

transaction ID. If ptrid is NULL, this
function will be

blocking.

Return Values
Returns true if successful. Returns
false otherwise.

Description
Disables driving of JTAG signals. Must
be called before FCloseJtag is called.


BOOL DpcSetTmsTdiTck(HANDLE hif, BOOL
fTms, BOOL fTdi, BOOL fTck, ERC * perc,
TRID * ptrid)

Parameters
hif

-

handle to JTAG

interface
fTms

-

value of TMS pin

(true = 1, false = 0)
fTdi

-

value of TDI pin

(true = 1, false = 0)
fTck

-

value of TCK pin

(true = 1, false = 0)
perc

-

pointer to store

error code
ptrid

-

pointer to store

transaction ID. If ptrid is NULL, this
function will be

blocking.


Return Values
Returns true if successful. Returns
false otherwise.

Description
Sets the JTAG lines TMS, TDI, and
TCK to a specified state.



BOOL DpcPutTdiBits(HANDLE hif, int cbit,

BYTE * rgbSnd, BOOL bitTms, BOOL
fReturnTdo,
BYTE * rgbRcv, ERC * perc, TRID * ptrid)

Parameters
hif

-

handle to JTAG

interface
cbit

-

number of TDI

bits to clock into the JTAG TAP
controller
rgbSnd

-

buffer that holds

TDI values. Bits are shifted in
sequentially starting at the first element
in the BYTE array, from LSB to MSB.
bitTms

-

value the TMS

pin will be held at while the rgbSnd bits
are shifted in (true = 1, false = 0)
fReturnTdo

-

specifies if bits

from TDO should be returned
rgbRcv

-

(optional) holds

TDO bits. Only used if fReturnTdo is
true.
perc

-

pointer to store

error code


ptrid

-

pointer to store

transaction ID. If ptrid is NULL, this
function will be

blocking.


Return Values
Returns true if successful. Returns
false otherwise.

Description
Shifts a specified number of bits into
TDI and (optionally) returns bits shifted
out TDO. RgbSend holds TDI bits.
Each bit is shifted in sequentially,
starting at the first element in the array,
from least significant bit to most
significant bit Below is an example of
how the TDI bits are placed in each
byte of rgbSend.