Øyvind Harboe wrote: > Here is a thought: > > - define jtag device/target num to be a unique id that has nothing > to do with the ordering of targets/jtag devices >
This exists now for the TARGET - not for the TAP chain. (ie: remember the [new_target_name] thing?) > - the jtag device chain can then afterwards be reordered and have > devices enabled/disabled/added, the id of a jtag device remains > constant > Like the TARGET NAME - that exists now, that was the purpose! > This scheme may well be reasonably simple to implement. > yes, and here is step #1 The "jtag_device" command needs to change - jtag create NAME -ir-len 4 ir-capture 0x01 -ir-mask 0x0f -id-opcode 0x0e Much like the "target" command changed. Step 2 We create a new command "jtag order" - which sets the tap order, you would use it like this: jtag order omapJRC omapCORTEX omapTRACE omapTHIS omapDSP omapTHAT Step 3 We create a new "event" - that does -invokes a TCL script. That TCL script does the following: (a) wiggle pins and configure the JRC tap. (b) executes the "jtag order" command. Step 4 It should work :-) Then - we just need to create a "jrc command" that matches up with the above. Oyvind> The trickiest bit I see is to find and repair all places where 'num' is not used as an id, but used to refer to "device offset 'num' in the chain"... - The oldest trick I've ever used solves that quick and fast You delete the index variable from the target and device structure, along with the 'next' element, turn on every warning about "unknown and unused variable" you can find.... Nothing will work compile until you fix it ! ============== -Duane. _______________________________________________ Openocd-development mailing list Openocd-development@lists.berlios.de https://lists.berlios.de/mailman/listinfo/openocd-development