#
# $Id: xc2c256-tq144,v 1.2 2003/08/13 09:24:36 telka Exp $
#
# JTAG declarations for XC2C256-VQ100
# 
# Based on the declarations for XC2C256-TQ144,
# Written by Alessandro Zummo <azummo@towertech.it>, 2003.
# Copyright (C) 2003 Tower Technologies s.r.l.,
# and bsdl2jtag output with Xilinx file [2] as input.
#
# 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 the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
#
# Documentation:
# [1] Xilinx Inc., "CoolRunner-II CPLD Family Advance Product Specification",
#     DS090 (v1.3) September 24, 2002
# [2] Xilinx Inc., "BSDL file for device XC2C256, package VQ144
#     Revision: 1.11", 2006-10-17
# [3] Xilinx Inc., "XC2C256 CoolRunner-II CPLD Advance Product Specification",
#     DS094 (v1.2) November 20, 2002

# mandatory data registers
register	BSR	552	# see [2]
register	BR	1

# optional data registers
register	DIR	32

# user-defined registers
register	ISPSR	274	# ISP (In-System Programming) Shift Register, see [2]

# instructions - see [2]
instruction length 8

# mandatory instructions - see [2]
instruction EXTEST		00000000	BSR
instruction SAMPLE/PRELOAD	00000011	BSR
instruction BYPASS		11111111	BR
instruction INTEST		00000010	BSR
instruction IDCODE		00000001	DIR
instruction USERCODE		11111101	DIR
instruction HIGHZ		11111100	BR
instruction CLAMP		11111010	BR

# user-defined instructions - see [2]
instruction ISC_ENABLE_CLAMP	11101001	BR
instruction ISC_ENABLEOTF	11100100	ISPSR
instruction ISC_ENABLE		11101000	ISPSR
instruction ISC_SRAM_READ	11100111	ISPSR
instruction ISC_SRAM_WRITE	11100110	ISPSR
instruction ISC_ERASE		11101101	ISPSR
instruction ISC_PROGRAM		11101010	ISPSR
instruction ISC_READ		11101110	ISPSR
instruction ISC_INIT		11110000	ISPSR
instruction ISC_DISABLE		11000000	ISPSR
instruction TEST_ENABLE		00010001	ISPSR
instruction BULKPROG		00010010	ISPSR
instruction ERASE_ALL		00010100	ISPSR
instruction MVERIFY		00010011	ISPSR
instruction TEST_DISABLE	00010101	ISPSR
instruction ISC_NOOP		11100000	BR

# signals - derived from [2] using bsdl2jtag
signal tdi
signal tck
signal tms
signal tdo
signal IO_2
signal IO_5
signal IO_6
signal IO_7
signal IO_8
signal IO_11
signal IO_13
signal IO_15
signal IO_17
signal IO_19
signal IO_20
signal IO_26
signal IO_28
signal IO_30
signal IO_32
signal IO_33
signal IO_34
signal IO_35
signal IO_37
signal IO_38
signal IO_40
signal IO_47
signal IO_49
signal IO_56
signal IO_58
signal IO_61
signal IO_63
signal IO_65
signal IO_70
signal IO_71
signal IO_72
signal IO_73
signal IO_74
signal IO_75
signal IO_83
signal IO_84
signal IO_85
signal IO_86
signal IO_87
signal IO_88
signal IO_90
signal IO_91
signal IO_93
signal IO_95
signal IO_97
signal IO_102
signal IO_103
signal IO_104
signal IO_105
signal IO_106
signal IO_107
signal IO_109
signal IO_120
signal IO_121
signal IO_122
signal IO_123
signal IO_132
signal IO_134
signal IO_135
signal IO_136
signal IO_139
signal IO_141
signal IO_143
signal IO_145
signal IO_149
signal IO_151
signal IO_153
signal IO_157
signal IO_158
signal IO_166
signal IO_167
signal IO_168
signal IO_169
signal IO_170
signal IO_171
signal IO_176
signal IO_177
signal IO_178
signal IO_179
signal IO_180
signal vdd1
signal vdd2
signal vdd3
signal vdd4
signal vdd5
signal vdd6
signal vdd7
signal gnd1
signal gnd2
signal gnd3
signal gnd4
signal gnd5
signal gnd6
signal gnd7

# bits - derived from [2] using bsdl2jtag
bit 551 O 1 *
bit 550 O 1 *
bit 549 O 1 *
bit 548 O 1 *
bit 547 O 1 *
bit 546 O 1 *
bit 545 I 1 IO_2
bit 544 O 1 IO_2 543 0 Z
bit 543 C 0 *
bit 542 O 1 *
bit 541 O 1 *
bit 540 O 1 *
bit 539 O 1 *
bit 538 O 1 *
bit 537 O 1 *
bit 536 I 1 IO_5
bit 535 O 1 IO_5 534 0 Z
bit 534 C 0 *
bit 533 I 1 IO_6
bit 532 O 1 IO_6 531 0 Z
bit 531 C 0 *
bit 530 I 1 IO_7
bit 529 O 1 IO_7 528 0 Z
bit 528 C 0 *
bit 527 I 1 IO_8
bit 526 O 1 IO_8 525 0 Z
bit 525 C 0 *
bit 524 O 1 *
bit 523 O 1 *
bit 522 O 1 *
bit 521 O 1 *
bit 520 O 1 *
bit 519 O 1 *
bit 518 O 1 *
bit 517 O 1 *
bit 516 O 1 *
bit 515 O 1 *
bit 514 O 1 *
bit 513 O 1 *
bit 512 O 1 *
bit 511 O 1 *
bit 510 O 1 *
bit 509 O 1 *
bit 508 O 1 *
bit 507 O 1 *
bit 506 I 1 IO_26
bit 505 O 1 IO_26 504 0 Z
bit 504 C 0 *
bit 503 O 1 *
bit 502 O 1 *
bit 501 O 1 *
bit 500 I 1 IO_28
bit 499 O 1 IO_28 498 0 Z
bit 498 C 0 *
bit 497 O 1 *
bit 496 O 1 *
bit 495 O 1 *
bit 494 I 1 IO_30
bit 493 O 1 IO_30 492 0 Z
bit 492 C 0 *
bit 491 O 1 *
bit 490 O 1 *
bit 489 O 1 *
bit 488 I 1 IO_32
bit 487 O 1 IO_32 486 0 Z
bit 486 C 0 *
bit 485 I 1 IO_11
bit 484 O 1 IO_11 483 0 Z
bit 483 C 0 *
bit 482 O 1 *
bit 481 O 1 *
bit 480 O 1 *
bit 479 I 1 IO_13
bit 478 O 1 IO_13 477 0 Z
bit 477 C 0 *
bit 476 O 1 *
bit 475 O 1 *
bit 474 O 1 *
bit 473 I 1 IO_15
bit 472 O 1 IO_15 471 0 Z
bit 471 C 0 *
bit 470 O 1 *
bit 469 O 1 *
bit 468 O 1 *
bit 467 I 1 IO_17
bit 466 O 1 IO_17 465 0 Z
bit 465 C 0 *
bit 464 O 1 *
bit 463 O 1 *
bit 462 O 1 *
bit 461 I 1 IO_19
bit 460 O 1 IO_19 459 0 Z
bit 459 C 0 *
bit 458 I 1 IO_20
bit 457 O 1 IO_20 456 0 Z
bit 456 C 0 *
bit 455 O 1 *
bit 454 O 1 *
bit 453 O 1 *
bit 452 I 1 IO_33
bit 451 O 1 IO_33 450 0 Z
bit 450 C 0 *
bit 449 I 1 IO_34
bit 448 O 1 IO_34 447 0 Z
bit 447 C 0 *
bit 446 I 1 IO_35
bit 445 O 1 IO_35 444 0 Z
bit 444 C 0 *
bit 443 O 1 *
bit 442 O 1 *
bit 441 O 1 *
bit 440 I 1 IO_37
bit 439 O 1 IO_37 438 0 Z
bit 438 C 0 *
bit 437 I 1 IO_38
bit 436 O 1 IO_38 435 0 Z
bit 435 C 0 *
bit 434 O 1 *
bit 433 O 1 *
bit 432 O 1 *
bit 431 I 1 IO_40
bit 430 O 1 IO_40 429 0 Z
bit 429 C 0 *
bit 428 O 1 *
bit 427 O 1 *
bit 426 O 1 *
bit 425 O 1 *
bit 424 O 1 *
bit 423 O 1 *
bit 422 O 1 *
bit 421 O 1 *
bit 420 O 1 *
bit 419 O 1 *
bit 418 O 1 *
bit 417 O 1 *
bit 416 O 1 *
bit 415 O 1 *
bit 414 O 1 *
bit 413 O 1 *
bit 412 O 1 *
bit 411 O 1 *
bit 410 I 1 IO_47
bit 409 O 1 IO_47 408 0 Z
bit 408 C 0 *
bit 407 O 1 *
bit 406 O 1 *
bit 405 O 1 *
bit 404 I 1 IO_49
bit 403 O 1 IO_49 402 0 Z
bit 402 C 0 *
bit 401 O 1 *
bit 400 O 1 *
bit 399 O 1 *
bit 398 O 1 *
bit 397 O 1 *
bit 396 O 1 *
bit 395 O 1 *
bit 394 O 1 *
bit 393 O 1 *
bit 392 O 1 *
bit 391 O 1 *
bit 390 O 1 *
bit 389 O 1 *
bit 388 O 1 *
bit 387 O 1 *
bit 386 O 1 *
bit 385 O 1 *
bit 384 O 1 *
bit 383 O 1 *
bit 382 O 1 *
bit 381 O 1 *
bit 380 O 1 *
bit 379 O 1 *
bit 378 O 1 *
bit 377 O 1 *
bit 376 O 1 *
bit 375 O 1 *
bit 374 I 1 IO_70
bit 373 O 1 IO_70 372 0 Z
bit 372 C 0 *
bit 371 I 1 IO_71
bit 370 O 1 IO_71 369 0 Z
bit 369 C 0 *
bit 368 I 1 IO_72
bit 367 O 1 IO_72 366 0 Z
bit 366 C 0 *
bit 365 I 1 IO_73
bit 364 O 1 IO_73 363 0 Z
bit 363 C 0 *
bit 362 I 1 IO_74
bit 361 O 1 IO_74 360 0 Z
bit 360 C 0 *
bit 359 I 1 IO_75
bit 358 O 1 IO_75 357 0 Z
bit 357 C 0 *
bit 356 O 1 *
bit 355 O 1 *
bit 354 O 1 *
bit 353 O 1 *
bit 352 O 1 *
bit 351 O 1 *
bit 350 O 1 *
bit 349 O 1 *
bit 348 O 1 *
bit 347 I 1 IO_56
bit 346 O 1 IO_56 345 0 Z
bit 345 C 0 *
bit 344 O 1 *
bit 343 O 1 *
bit 342 O 1 *
bit 341 I 1 IO_58
bit 340 O 1 IO_58 339 0 Z
bit 339 C 0 *
bit 338 O 1 *
bit 337 O 1 *
bit 336 O 1 *
bit 335 O 1 *
bit 334 O 1 *
bit 333 O 1 *
bit 332 I 1 IO_61
bit 331 O 1 IO_61 330 0 Z
bit 330 C 0 *
bit 329 O 1 *
bit 328 O 1 *
bit 327 O 1 *
bit 326 I 1 IO_63
bit 325 O 1 IO_63 324 0 Z
bit 324 C 0 *
bit 323 O 1 *
bit 322 O 1 *
bit 321 O 1 *
bit 320 I 1 IO_65
bit 319 O 1 IO_65 318 0 Z
bit 318 C 0 *
bit 317 O 1 *
bit 316 O 1 *
bit 315 O 1 *
bit 314 O 1 *
bit 313 O 1 *
bit 312 O 1 *
bit 311 O 1 *
bit 310 O 1 *
bit 309 O 1 *
bit 308 O 1 *
bit 307 O 1 *
bit 306 O 1 *
bit 305 O 1 *
bit 304 O 1 *
bit 303 O 1 *
bit 302 I 1 IO_83
bit 301 O 1 IO_83 300 0 Z
bit 300 C 0 *
bit 299 I 1 IO_84
bit 298 O 1 IO_84 297 0 Z
bit 297 C 0 *
bit 296 I 1 IO_85
bit 295 O 1 IO_85 294 0 Z
bit 294 C 0 *
bit 293 I 1 IO_86
bit 292 O 1 IO_86 291 0 Z
bit 291 C 0 *
bit 290 I 1 IO_87
bit 289 O 1 IO_87 288 0 Z
bit 288 C 0 *
bit 287 I 1 IO_88
bit 286 O 1 IO_88 285 0 Z
bit 285 C 0 *
bit 284 O 1 *
bit 283 O 1 *
bit 282 O 1 *
bit 281 I 1 IO_90
bit 280 O 1 IO_90 279 0 Z
bit 279 C 0 *
bit 278 I 1 IO_91
bit 277 O 1 IO_91 276 0 Z
bit 276 C 0 *
bit 275 O 1 *
bit 274 O 1 *
bit 273 O 1 *
bit 272 I 1 IO_93
bit 271 O 1 IO_93 270 0 Z
bit 270 C 0 *
bit 269 O 1 *
bit 268 O 1 *
bit 267 O 1 *
bit 266 I 1 IO_95
bit 265 O 1 IO_95 264 0 Z
bit 264 C 0 *
bit 263 O 1 *
bit 262 O 1 *
bit 261 O 1 *
bit 260 I 1 IO_97
bit 259 O 1 IO_97 258 0 Z
bit 258 C 0 *
bit 257 O 1 *
bit 256 O 1 *
bit 255 O 1 *
bit 254 O 1 *
bit 253 O 1 *
bit 252 O 1 *
bit 251 O 1 *
bit 250 O 1 *
bit 249 O 1 *
bit 248 O 1 *
bit 247 O 1 *
bit 246 O 1 *
bit 245 O 1 *
bit 244 O 1 *
bit 243 O 1 *
bit 242 O 1 *
bit 241 O 1 *
bit 240 O 1 *
bit 239 O 1 *
bit 238 O 1 *
bit 237 O 1 *
bit 236 O 1 *
bit 235 O 1 *
bit 234 O 1 *
bit 233 O 1 *
bit 232 O 1 *
bit 231 O 1 *
bit 230 O 1 *
bit 229 O 1 *
bit 228 O 1 *
bit 227 I 1 IO_120
bit 226 O 1 IO_120 225 0 Z
bit 225 C 0 *
bit 224 I 1 IO_121
bit 223 O 1 IO_121 222 0 Z
bit 222 C 0 *
bit 221 I 1 IO_122
bit 220 O 1 IO_122 219 0 Z
bit 219 C 0 *
bit 218 I 1 IO_123
bit 217 O 1 IO_123 216 0 Z
bit 216 C 0 *
bit 215 O 1 *
bit 214 O 1 *
bit 213 O 1 *
bit 212 O 1 *
bit 211 O 1 *
bit 210 O 1 *
bit 209 I 1 IO_102
bit 208 O 1 IO_102 207 0 Z
bit 207 C 0 *
bit 206 I 1 IO_103
bit 205 O 1 IO_103 204 0 Z
bit 204 C 0 *
bit 203 I 1 IO_104
bit 202 O 1 IO_104 201 0 Z
bit 201 C 0 *
bit 200 I 1 IO_105
bit 199 O 1 IO_105 198 0 Z
bit 198 C 0 *
bit 197 I 1 IO_106
bit 196 O 1 IO_106 195 0 Z
bit 195 C 0 *
bit 194 I 1 IO_107
bit 193 O 1 IO_107 192 0 Z
bit 192 C 0 *
bit 191 O 1 *
bit 190 O 1 *
bit 189 O 1 *
bit 188 I 1 IO_109
bit 187 O 1 IO_109 186 0 Z
bit 186 C 0 *
bit 185 O 1 *
bit 184 O 1 *
bit 183 O 1 *
bit 182 O 1 *
bit 181 O 1 *
bit 180 O 1 *
bit 179 O 1 *
bit 178 O 1 *
bit 177 O 1 *
bit 176 O 1 *
bit 175 O 1 *
bit 174 O 1 *
bit 173 O 1 *
bit 172 O 1 *
bit 171 O 1 *
bit 170 O 1 *
bit 169 O 1 *
bit 168 O 1 *
bit 167 O 1 *
bit 166 O 1 *
bit 165 O 1 *
bit 164 O 1 *
bit 163 O 1 *
bit 162 O 1 *
bit 161 O 1 *
bit 160 O 1 *
bit 159 O 1 *
bit 158 O 1 *
bit 157 O 1 *
bit 156 O 1 *
bit 155 I 1 IO_132
bit 154 O 1 IO_132 153 0 Z
bit 153 C 0 *
bit 152 O 1 *
bit 151 O 1 *
bit 150 O 1 *
bit 149 I 1 IO_134
bit 148 O 1 IO_134 147 0 Z
bit 147 C 0 *
bit 146 I 1 IO_135
bit 145 O 1 IO_135 144 0 Z
bit 144 C 0 *
bit 143 I 1 IO_136
bit 142 O 1 IO_136 141 0 Z
bit 141 C 0 *
bit 140 O 1 *
bit 139 O 1 *
bit 138 O 1 *
bit 137 O 1 *
bit 136 O 1 *
bit 135 O 1 *
bit 134 I 1 IO_139
bit 133 O 1 IO_139 132 0 Z
bit 132 C 0 *
bit 131 O 1 *
bit 130 O 1 *
bit 129 O 1 *
bit 128 I 1 IO_141
bit 127 O 1 IO_141 126 0 Z
bit 126 C 0 *
bit 125 O 1 *
bit 124 O 1 *
bit 123 O 1 *
bit 122 I 1 IO_143
bit 121 O 1 IO_143 120 0 Z
bit 120 C 0 *
bit 119 O 1 *
bit 118 O 1 *
bit 117 O 1 *
bit 116 I 1 IO_145
bit 115 O 1 IO_145 114 0 Z
bit 114 C 0 *
bit 113 O 1 *
bit 112 O 1 *
bit 111 O 1 *
bit 110 O 1 *
bit 109 O 1 *
bit 108 O 1 *
bit 107 O 1 *
bit 106 O 1 *
bit 105 O 1 *
bit 104 O 1 *
bit 103 O 1 *
bit 102 O 1 *
bit 101 O 1 *
bit 100 O 1 *
bit 99 O 1 *
bit 98 O 1 *
bit 97 O 1 *
bit 96 O 1 *
bit 95 O 1 *
bit 94 O 1 *
bit 93 O 1 *
bit 92 O 1 *
bit 91 O 1 *
bit 90 O 1 *
bit 89 O 1 *
bit 88 O 1 *
bit 87 O 1 *
bit 86 I 1 IO_166
bit 85 O 1 IO_166 84 0 Z
bit 84 C 0 *
bit 83 I 1 IO_167
bit 82 O 1 IO_167 81 0 Z
bit 81 C 0 *
bit 80 I 1 IO_168
bit 79 O 1 IO_168 78 0 Z
bit 78 C 0 *
bit 77 I 1 IO_169
bit 76 O 1 IO_169 75 0 Z
bit 75 C 0 *
bit 74 I 1 IO_170
bit 73 O 1 IO_170 72 0 Z
bit 72 C 0 *
bit 71 I 1 IO_171
bit 70 O 1 IO_171 69 0 Z
bit 69 C 0 *
bit 68 I 1 IO_149
bit 67 O 1 IO_149 66 0 Z
bit 66 C 0 *
bit 65 O 1 *
bit 64 O 1 *
bit 63 O 1 *
bit 62 I 1 IO_151
bit 61 O 1 IO_151 60 0 Z
bit 60 C 0 *
bit 59 O 1 *
bit 58 O 1 *
bit 57 O 1 *
bit 56 I 1 IO_153
bit 55 O 1 IO_153 54 0 Z
bit 54 C 0 *
bit 53 O 1 *
bit 52 O 1 *
bit 51 O 1 *
bit 50 O 1 *
bit 49 O 1 *
bit 48 O 1 *
bit 47 O 1 *
bit 46 O 1 *
bit 45 O 1 *
bit 44 I 1 IO_157
bit 43 O 1 IO_157 42 0 Z
bit 42 C 0 *
bit 41 I 1 IO_158
bit 40 O 1 IO_158 39 0 Z
bit 39 C 0 *
bit 38 O 1 *
bit 37 O 1 *
bit 36 O 1 *
bit 35 O 1 *
bit 34 O 1 *
bit 33 O 1 *
bit 32 O 1 *
bit 31 O 1 *
bit 30 O 1 *
bit 29 O 1 *
bit 28 O 1 *
bit 27 O 1 *
bit 26 O 1 *
bit 25 O 1 *
bit 24 O 1 *
bit 23 I 1 IO_176
bit 22 O 1 IO_176 21 0 Z
bit 21 C 0 *
bit 20 I 1 IO_177
bit 19 O 1 IO_177 18 0 Z
bit 18 C 0 *
bit 17 I 1 IO_178
bit 16 O 1 IO_178 15 0 Z
bit 15 C 0 *
bit 14 I 1 IO_179
bit 13 O 1 IO_179 12 0 Z
bit 12 C 0 *
bit 11 I 1 IO_180
bit 10 O 1 IO_180 9 0 Z
bit 9 C 0 *
bit 8 O 1 *
bit 7 O 1 *
bit 6 O 1 *
bit 5 O 1 *
bit 4 O 1 *
bit 3 O 1 *
bit 2 O 1 *
bit 1 O 1 *
bit 0 O 1 *
