**** BEGIN LOGGING AT Fri Jun 22 02:59:57 2007 Jun 22 12:18:45 what all is required in the cfg file to get openocd+ftd2xx talking to a olimex-jtag device Jun 22 12:18:59 is ft2232_device_desc required? Jun 22 12:37:57 yeah Jun 22 12:38:28 either device description or serial, iirc Jun 22 12:39:12 it should've complained with an error if you didn't specify one Jun 22 12:39:49 I think I'm fighting permission problems Jun 22 12:41:46 what's happening when you launch openocd? Jun 22 12:41:53 yes, running as root fixed it Jun 22 12:42:34 ah, but then libftdi wouldn't have worked on that machine either Jun 22 12:42:50 they're both using /proc/bus/usb/ Jun 22 12:43:14 http://mmd.ath.cx/openocd/45-ft2232.rules Jun 22 12:43:29 is the udev rules file i'm using on my ubuntu desktop Jun 22 12:43:57 you'll have to add the vid/pid for the olimex dongle Jun 22 12:44:01 thanks -- i'll apply those when a I get chance! Jun 22 12:44:14 well, getting a little further, but flash programming is still failing Jun 22 12:44:22 with the same error? Jun 22 12:44:38 Warning: cfi.c:1754 cfi_probe(): configuration specifies 0x1000000 size, but a 0x2000000 size flash was found Jun 22 12:44:41 Warning: cfi.c:376 cfi_read_intel_pri_ext(): expected one protection register field, but found 2 Jun 22 12:44:44 Warning: target.c:561 target_alloc_working_area(): not enough working area available Jun 22 12:44:47 Warning: target.c:561 target_alloc_working_area(): not enough working area available Jun 22 12:44:50 Error: armv4_5.c:591 armv4_5_run_algorithm(): timeout waiting for algorithm to complete, trying to halt target Jun 22 12:45:09 and in the telnet window: Jun 22 12:45:10 failed writing file /build/tmp/u-boot-holon.bin to flash bank 0 at offset 0x00000000 Jun 22 12:45:13 flash program error Jun 22 12:45:44 what size is your flash? the openocd believes its 32mb, but you specified a 16mb flash in the cfg Jun 22 12:46:19 you have to specify the size of the bank, not of a single chip Jun 22 12:47:29 ok, I'll fix that Jun 22 12:47:51 this is also bottom boot block flash which may be causing some problems. Jun 22 12:48:02 the first 4 sectors are smaller than the rest Jun 22 12:48:16 does "flash probe 0" show the correct sector sizes? Jun 22 12:48:37 d'oh Jun 22 12:48:39 flash info 0 Jun 22 12:50:18 yes Jun 22 12:50:21 #0: 0x00000000 (0x10000kB) erased, not protected Jun 22 12:50:21 #1: 0x00010000 (0x10000kB) erased, not protected Jun 22 12:50:21 #2: 0x00020000 (0x10000kB) erased, not protected Jun 22 12:50:21 #3: 0x00030000 (0x10000kB) erased, not protected Jun 22 12:50:21 #4: 0x00040000 (0x40000kB) erased, not protected Jun 22 12:50:23 #5: 0x00080000 (0x40000kB) erased, not protected Jun 22 12:50:37 tell me if I'm pasting too much in this channel Jun 22 12:51:41 so the sizes are for both flash chips combined Jun 22 12:51:46 yeah Jun 22 12:51:59 that looks right then Jun 22 12:52:35 you specified 0x200000 as the working_area base - what type of memory is there? Jun 22 12:53:02 checking ... Jun 22 12:53:32 according to the pxa manual i've got here the internal sram is mapped at 0x5c000000 Jun 22 12:55:45 drath: that does not look right then Jun 22 12:58:01 try "working_area 0 0x5c000000 0x10000 backup" (or 'nobackup' if you have no code using that area) Jun 22 12:58:11 drath: that was it -- looks like flash works :-) Jun 22 12:58:16 *flash programming Jun 22 12:59:05 thanks for all the help -- this is a great! Jun 22 12:59:14 you're welcome Jun 22 12:59:26 wookey_: looks like PXA27x is finally working Jun 22 12:59:43 wookey_: been able to track down the problem with the help of cbrake and the guys from Pengutronix Jun 22 13:00:28 cbrake: as for your libftdi problem: the "easy" way around this would be decreasing the buffer in ft2232.c until it works Jun 22 13:00:46 drath: great -- I'll try that now Jun 22 13:00:59 cbrake: the "hard" way would be using usbmon to capture what ftd2xx does, and implement the same for libftdi Jun 22 13:01:42 drath: :-) I'll put the "hard way" on my todo list -- looks like fun Jun 22 13:02:17 drath excellent Jun 22 13:02:30 So now I really must try it Jun 22 13:02:43 tell me when the right version is checked in Jun 22 13:02:50 (must dash now) Jun 22 13:04:40 drath: what do you do for working ram on the PXA255 as it does not have internal SRAM? Jun 22 13:06:26 wookey_: it's already in SVN Jun 22 13:06:35 cbrake: initialize SDRAM Jun 22 13:06:52 cbrake: you can set up the registers with "mww" and "mdw" commands Jun 22 13:07:32 you can also flash without RAM, but that's taking a lot longer Jun 22 13:07:41 drath: that is what I figured. Jun 22 13:07:56 drath: so if you leave the working_area off, it will just take longer Jun 22 13:08:18 yeah Jun 22 13:08:23 _much_ longer Jun 22 13:08:26 heh Jun 22 13:09:11 well, I'll do some more testing with libftdi and then do a writeup on how to make this all work with the 270 Jun 22 13:09:31 you can put your config at http://openfacts.berlios.de/index-en.phtml?title=OpenOCD_scripts Jun 22 13:11:09 will do! Jun 22 13:21:26 pxa270 entry added to scripts page Jun 22 13:21:30 thanks Jun 22 13:31:49 drath: when you say decrease the buffer size in ft2232.c, do you mean FT2232_BUFFER_SIZE? Jun 22 13:37:04 yeah Jun 22 13:37:14 line 147 Jun 22 13:37:28 the openocd fills that buffer until either it requires the data or the buffer grows full Jun 22 13:37:44 the data is then transfered to the ft2232, and results are read back Jun 22 13:38:48 drath: ok, I've tried it down to 1K and it is still failing Jun 22 13:39:02 drath: I guess its time for the "hard" approach :-) **** ENDING LOGGING AT Sat Jun 23 02:59:57 2007