**** BEGIN LOGGING AT Mon Nov 13 02:59:57 2006 Nov 13 10:22:01 Hi, anybody have the time to offer some help with mixed chains on openocd? Nov 13 10:27:52 msg nickserv help Nov 13 10:30:00 ....oops - try putting a / in next time, dumbo Nov 13 10:30:06 the-moog: hey Nov 13 10:30:10 the-moog: what exactly do you want? Nov 13 10:30:22 the-moog: setting up the .cfg for a chain with multiple devices? Nov 13 10:30:36 Hi, I'm having some trouble with open ocd and I'm up against it timewise Nov 13 10:31:07 I've just got a new board back, up 'till now I've been using an olimex dev board, that has worked fine Nov 13 10:31:51 I can use lattce isp on the mixed chain, but I can't get openocd to work, perhaps you would have time to point me in the right direction Nov 13 10:32:11 what chips are in the chain? Nov 13 10:32:21 From TDI to TDO: Nov 13 10:32:36 OpenOCD expects them to be listed from TDO to TDI Nov 13 10:32:44 1: CPU Philips/NXP LCP2220 Nov 13 10:33:01 i.e. the one closest to TDO should be listed first as "jtag_device ..." Nov 13 10:33:29 (yes, I *think* I have the order in .cfg correct) Nov 13 10:33:40 2: FPGA Altera Cyclone Nov 13 10:33:54 3: CPLD Lattice powermanager 2 Nov 13 10:34:19 How does openocd know which device is the ARM? Nov 13 10:34:34 you specify the jtag# in the target line Nov 13 10:34:46 http://openfacts.berlios.de/index-en.phtml?title=OpenOCD_configuration Nov 13 10:34:48 ah, perhaps that is what is wrong Nov 13 10:35:32 my target line reads: Nov 13 10:35:40 target arm7tdmi little run_and_halt 0 arm7tdmi-s_r4 Nov 13 10:36:03 yeah, the 0 means "first target in the chain" (the one closest to TDO) Nov 13 10:36:15 you should change that to 2 in your case Nov 13 10:36:24 changing to 2 now...... Nov 13 10:36:25 make sure you're using a current version Nov 13 10:36:28 of the openocd Nov 13 10:36:43 btw the target help on the website does not mention this..... Nov 13 10:37:02 target arm7tdmi [variant] Nov 13 10:37:03 The arm7tdmi target definition requires at least one additional argument, specifying the position of the target in the JTAG daisy-chain. Nov 13 10:37:43 YES!!! responds to halt now THANK YOU!! Nov 13 10:37:46 you're welcome Nov 13 10:38:20 Ok, while you are here, the flash commands do CFI, i.e. intel, what about AMD? Nov 13 10:38:36 ...sorry spansion (stupind name if ever there was one) Nov 13 10:39:07 i've received several patches for spansion, but noone cared to send me something clean enough for inclusion Nov 13 10:39:42 :( Nov 13 10:40:18 and while i have several boards with external flashes they all have intel chips Nov 13 10:40:36 i can send you the last patch i've received, if you want Nov 13 10:40:53 but you'll have to test it yourself, and make sure that it works correctly Nov 13 10:41:24 I probably have no time to play and build the windoze port - or even the tools to do it, no worries, I'll work round somehow Nov 13 10:42:25 thanks for your help anyway Nov 13 10:43:02 no problem Nov 13 10:43:36 I'm just looking at my log from open ocd. Even though it appears to work, I get: Nov 13 10:43:48 Warning: jtag.c:1038 jtag_read_buffer(): value captured during scan didn't pass the requested check: captured: 0x00 check_value: 0x0 Nov 13 10:43:48 1 check_mask: 0x00 Nov 13 10:44:20 what is the IR capture exactly? Nov 13 10:46:42 when scanning instructions in the JTAG instruction register, every chip is expected to load "b01" into the two least significant bits of the IR register, which are then shifted out. the ARMs actually shift out b0001. the OpenOCD uses these values to verify that communication is working correctly Nov 13 10:47:42 what type of jtag interface do you use? Nov 13 10:47:49 amontec jtagkey Nov 13 10:48:00 what's your jtag_speed setting? Nov 13 10:48:03 2 Nov 13 10:48:14 maybe you have to reduce the speed Nov 13 10:48:36 i.e. increase the jtag_speed value Nov 13 10:49:41 the strange thing is the check mask in the error log report is 0x00, but in the config file it is all 1's Nov 13 10:51:24 uhm, yeah, that is strange Nov 13 10:51:55 can you send me your .cfg and a log (-d -l ) to Dominic.Rath gmx.de Nov 13 10:51:58 ? Nov 13 10:55:48 Ok doing it now..... Nov 13 11:02:43 ...done Nov 13 11:03:37 hum, which version of the OpenOCD do you use? Nov 13 11:04:07 * vmaster note to myself - add that stupid version string to the logoutput, too Nov 13 11:09:47 good question: d/l today - was using 080, now using 115 from http://www.yagarto.de/ Nov 13 11:10:52 It looks like there is some corruption of the jtag chain. I've just tried setting registers using reg and the register value is wrong Nov 13 11:11:27 yeah, communication failed completely at the end of the logfile you've sent me Nov 13 11:11:36 Debug: arm7_9_common.c:620 arm7_9_poll(): DBGACK set, dbg_state->value: 0x4f1f0f0f Nov 13 11:11:49 that's the JTAG idcode Nov 13 11:11:55 I tried resume, that seems to break it good Nov 13 11:12:10 its not an IDCODE from any of the chips in the chain Nov 13 11:12:35 hum, looks a lot like an ARM idcode Nov 13 11:12:45 yes? Nov 13 11:13:23 any idea what the ID code for a LPC2220 should be? Nov 13 11:13:27 what are the part numbers of the two plds in your design? Nov 13 11:14:26 ispPAC-POWR1014/A - IDCode: 00145h Nov 13 11:14:43 oops Nov 13 11:14:57 00145043 Nov 13 11:15:03 (h obviously) Nov 13 11:16:07 Altera EP1C3T144I6 Nov 13 11:16:57 0x4f1f0f0f is the idcode of my LPC2294 Nov 13 11:19:17 I can't find a reliable source for ID code for altera, I was using the latice ISP software yesterday and that listes all the ids Nov 13 11:19:45 hold on, I'm just checking a few things Nov 13 11:24:18 hum, the lattice and the altera parts are both capable of >10MHz TCK operation Nov 13 11:24:43 you don't happen to have the equipment to verify signal integrity on TCK, TMS, TDI and TDO? Nov 13 11:24:52 especially TMS Nov 13 11:24:55 and TCK Nov 13 11:25:40 i'll compile a debug version for you (if i find out how to build for mingw...) Nov 13 11:27:13 I have a basic storage scope I'll take a look at the tms/tck signals at each chip. Nov 13 11:58:18 the-moog: http://mmd.ath.cx/openocd/openocd_r115_debug.exe Nov 13 11:58:59 got it. Nov 13 11:59:58 this one includes a fix for comparing the jtag data that didn't make it into R115, and is going to output a lot of debug info Nov 13 12:00:06 I've been playing with the scope, but can't make sense of what is going on. The scope is not very good at capturing fast, non repetative signals - but the levels vs noise look ok Nov 13 12:01:27 ok, try again with the new exe, and send me the log file Nov 13 12:01:42 you might have to compress it Nov 13 12:02:05 I've just d/l it - trying it now.... Nov 13 12:03:50 no more log than normal - do I need to use -d ? Nov 13 12:04:02 mhh, let me check Nov 13 12:09:50 gnah... gotta love windoze Nov 13 12:10:04 i'll get myself something for lunch, be back in a few minutes Nov 13 12:33:38 the-moog: outputs a lot more, as expected - did you run the openocd_r115_debug.exe, not just openocd.exe? Nov 13 12:33:54 hi Nov 13 12:34:48 yes I ran the correct one - jet me just check that I have done this right. I just copied the .exe you sent into the install folder\bin of openocd Nov 13 12:36:34 I'll do the same with a -d3 and send you the result from the initialisation Nov 13 12:58:27 the-moog: there's definitely a communication problem, but there might also be a bug somewhere... the value 0x01 reported as the check_mask is wrong, it should be 0xf... Nov 13 13:04:11 There are some mods I can do to shorten the chain - I will do this after lunch. I will report back when the chain only has the ARM present if there is still a problem. Nov 13 13:07:18 vmaster: you see the new lego nxt brick has a SAM series atmel? Nov 13 13:07:18 vmaster: they even have jtag headers onboard Nov 13 13:07:43 vmaster: should be able to use openocd with it easy Nov 13 13:08:44 yeah, they're already using it, at least someone contacted me and asked a few questions Nov 13 13:09:11 ahh cool Nov 13 13:09:21 vmaster: the nxt brick is pretty expensive though Nov 13 13:21:03 just working on a ui for the programming/communications pc frontend for the geep-b , but pondering if i should be using qt3.x or qt4 Nov 13 13:43:48 geep-b? Nov 13 13:44:10 AchiestDragon: sounds like an african hemoragic virus Nov 13 14:50:19 ~seen lennert Nov 13 14:50:44 lennert was last seen on IRC in channel #openjtag, 5d 4h 40m 31s ago, saying: 'probably LE as that's what other folks use'. **** ENDING LOGGING AT Tue Nov 14 02:59:57 2006