Dick Hollenbeck <dick@softplc.com> work in progress
git-svn-id: svn://svn.berlios.de/openocd/trunk@1457 b42882b7-edfa-0310-969c-e2dbd0fdcd60__archive__
parent
ba4e2c43fb
commit
1552562b3a
|
@ -9,7 +9,7 @@
|
||||||
* peter.hettkamp@htp-tel.de *
|
* peter.hettkamp@htp-tel.de *
|
||||||
* *
|
* *
|
||||||
* Copyright (C) 2009 SoftPLC Corporation. http://softplc.com *
|
* Copyright (C) 2009 SoftPLC Corporation. http://softplc.com *
|
||||||
* dick@softplc.com *
|
* Dick Hollenbeck <dick@softplc.com> *
|
||||||
* *
|
* *
|
||||||
* This program is free software; you can redistribute it and/or modify *
|
* This program is free software; you can redistribute it and/or modify *
|
||||||
* it under the terms of the GNU General Public License as published by *
|
* it under the terms of the GNU General Public License as published by *
|
||||||
|
@ -480,7 +480,7 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
|
||||||
jtag_add_pathmove( sizeof(exception_path)/sizeof(exception_path[0]), exception_path);
|
jtag_add_pathmove( sizeof(exception_path)/sizeof(exception_path[0]), exception_path);
|
||||||
|
|
||||||
if (verbose)
|
if (verbose)
|
||||||
LOG_USER("%s %d retry %d", op_name, xsdrsize, attempt);
|
LOG_USER("%s mismatch, xsdrsize=%d retry=%d", op_name, xsdrsize, attempt);
|
||||||
}
|
}
|
||||||
|
|
||||||
field.tap = tap;
|
field.tap = tap;
|
||||||
|
@ -619,8 +619,6 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case XENDIR:
|
case XENDIR:
|
||||||
{
|
|
||||||
tap_state_t mystate;
|
|
||||||
|
|
||||||
if (read(xsvf_fd, &uc, 1) < 0)
|
if (read(xsvf_fd, &uc, 1) < 0)
|
||||||
{
|
{
|
||||||
|
@ -629,26 +627,21 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
|
||||||
}
|
}
|
||||||
|
|
||||||
/* see page 22 of XSVF spec */
|
/* see page 22 of XSVF spec */
|
||||||
mystate = uc == 1 ? TAP_IRPAUSE : TAP_IDLE;
|
if( uc == 0 )
|
||||||
|
xendir = TAP_IDLE;
|
||||||
LOG_DEBUG("XENDIR 0x%02X %s", uc, tap_state_name(mystate));
|
else if( uc == 1 )
|
||||||
|
xendir = TAP_IRPAUSE;
|
||||||
/* assuming that the XRUNTEST comes from SVF RUNTEST, then only these states
|
else
|
||||||
* should come here because the SVF spec only allows these with a RUNTEST
|
|
||||||
*/
|
|
||||||
if (mystate != TAP_IRPAUSE && mystate != TAP_DRPAUSE && mystate != TAP_RESET && mystate != TAP_IDLE )
|
|
||||||
{
|
{
|
||||||
LOG_ERROR("illegal XENDIR endstate: \"%s\"", tap_state_name(mystate));
|
LOG_ERROR("illegial XENDIR argument: 0x%02X", uc);
|
||||||
unsupported = 1;
|
unsupported = 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
xendir = mystate;
|
|
||||||
}
|
LOG_DEBUG("XENDIR 0x%02X %s", uc, tap_state_name(xendir));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case XENDDR:
|
case XENDDR:
|
||||||
{
|
|
||||||
tap_state_t mystate;
|
|
||||||
|
|
||||||
if (read(xsvf_fd, &uc, 1) < 0)
|
if (read(xsvf_fd, &uc, 1) < 0)
|
||||||
{
|
{
|
||||||
|
@ -657,18 +650,18 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
|
||||||
}
|
}
|
||||||
|
|
||||||
/* see page 22 of XSVF spec */
|
/* see page 22 of XSVF spec */
|
||||||
mystate = uc == 1 ? TAP_DRPAUSE : TAP_IDLE;
|
if( uc == 0 )
|
||||||
|
xenddr = TAP_IDLE;
|
||||||
LOG_DEBUG("XENDDR %02X %s", uc, tap_state_name(mystate));
|
else if( uc == 1 )
|
||||||
|
xenddr = TAP_DRPAUSE;
|
||||||
if (mystate != TAP_IRPAUSE && mystate != TAP_DRPAUSE && mystate != TAP_RESET && mystate != TAP_IDLE )
|
else
|
||||||
{
|
{
|
||||||
LOG_ERROR("illegal XENDDR endstate: \"%s\"", tap_state_name( mystate ));
|
LOG_ERROR("illegial XENDDR argument: 0x%02X", uc);
|
||||||
unsupported = 1;
|
unsupported = 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
xenddr = mystate;
|
|
||||||
}
|
LOG_DEBUG("XENDDR %02X %s", uc, tap_state_name(xenddr));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case XSIR:
|
case XSIR:
|
||||||
|
@ -1058,7 +1051,9 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* PSUEDO-Code from Xilinx Appnote XAPP067.pdf:
|
#if 0 /* this comment style used to try and keep uncrustify from adding * at begin of line */
|
||||||
|
|
||||||
|
PSUEDO-Code from Xilinx Appnote XAPP067.pdf:
|
||||||
|
|
||||||
the following pseudo code clarifies the intent of the xrepeat support. The
|
the following pseudo code clarifies the intent of the xrepeat support. The
|
||||||
flow given is for the entire processing of an SVF file, not an XSVF file.
|
flow given is for the entire processing of an SVF file, not an XSVF file.
|
||||||
|
@ -1106,4 +1101,4 @@ else if RUNTEST record then
|
||||||
store <TCK value> as <current pause time>
|
store <TCK value> as <current pause time>
|
||||||
end if
|
end if
|
||||||
|
|
||||||
*/
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue