[<<] [<] Page 1 of 2 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
ICD
From: Ralf Forsberg ####@####.#### Date: 15 Nov 2002 12:06:00 -0000 Message-Id: <20021115120041.GA3268@home.se> Hello, I am about to build an ICD (can't afford to buy one at the moment). The plan is to start with the source in icdprog and try to work out how to simulate with the ICD using MPLAB as the reference. I'm hoping that this will lead to ICD support in gpsim. I get indications that the ICD will be discontinued in favor of the ICD2, so the ICD2 would be the better choice. Also the ICD2 has USB which gives better transfer rates, and has support for the 18x chips. The USB chip that is used (FTDI), I have learned has Linux drivers! So I imagine that you can just select a virtual serial port in order to use the USB for the ICD2. Does anyone know if there are schematics of the ICD2 somewhere? Another thought is that IIRC the protocol used by the ICD is ascii-based. Do you imagine it would be possible to code new firmware that uses a tighter protocol? It wouldn't be compatible with MPLAB, but it would be faster and there would be no need for reverse engineering. There is a DS51242A that have some information about this, but it does not look complete? / Ralf | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: "Niklas Wennerstrand" ####@####.#### Date: 15 Nov 2002 20:22:05 -0000 Message-Id: <000101c28ce3$f6ffa890$26a840d5@HAL> Hello Ralf, The FTDI chip is not used in the ICD2 if I have read right on the piclist. It has accordingly to someone that has opened the ICD2 a cypress USB chip. The FTDI chip is quite nice to use if you want to build an ICD2 yourself. Maybe Microchip is willing to share their ICD2 USB commands but I doubt it. Even if you have the information on their device driver for USB under windoze you will have problem implement it under linux. USB is quite tricky to do, far more complex than straight forwads rs232. But with the FTDI drivers for linux you can get fast communication to your design. Its like rs232 but fast. (USB support under linux took several kernel versions to get there so take that as a measurement on its complexity) If you want Microchip ICD2 to work under linux with Microchip USB firmware in the cypress chip then you have to have a USB analyser snooping the messages and a USB analyser is not something that ordinary mortals can afford. The ideal would be to make Microchip ICD2 work under linux but to do that without Microchips help is almost impossible. Maybe some one here sees this as a challenge and proves me wrong? But as ICD2 also have rs232 I would start there and after that figure out the USB alternative later on. If yo do not plan to get support for Microchip ICD2 under gpsim you can build your own ICD2 with a fast FTDI chip as an alternative and still get it quite "simple". The ICD commands to the actual 16F87X have even been on Microchips website but I have not seen any information on the 18FXXX devices yet and as they program different than 16F87X in general I would suspect that the ICD handling differs as well. You would need to know that as well so that all PIC can be supported. You will probably need the collective knowledge on this community to finish the project. But if you do get the ICD2 to work under gpsim it would be really nice. Regards Niklas -----Ursprungligt meddelande----- Från: Ralf Forsberg ####@####.#### Skickat: den 15 november 2002 13:01 Till: ####@####.#### Ämne: ICD Hello, I am about to build an ICD (can't afford to buy one at the moment). The plan is to start with the source in icdprog and try to work out how to simulate with the ICD using MPLAB as the reference. I'm hoping that this will lead to ICD support in gpsim. I get indications that the ICD will be discontinued in favor of the ICD2, so the ICD2 would be the better choice. Also the ICD2 has USB which gives better transfer rates, and has support for the 18x chips. The USB chip that is used (FTDI), I have learned has Linux drivers! So I imagine that you can just select a virtual serial port in order to use the USB for the ICD2. Does anyone know if there are schematics of the ICD2 somewhere? Another thought is that IIRC the protocol used by the ICD is ascii-based. Do you imagine it would be possible to code new firmware that uses a tighter protocol? It wouldn't be compatible with MPLAB, but it would be faster and there would be no need for reverse engineering. There is a DS51242A that have some information about this, but it does not look complete? / Ralf --------------------------------------------------------------------- To unsubscribe, e-mail: ####@####.#### For additional commands, e-mail: ####@####.#### | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: Ralf Forsberg ####@####.#### Date: 16 Nov 2002 17:02:17 -0000 Message-Id: <20021116165652.GA483@home.se> On Fri, Nov 15, 2002 at 09:16:54PM +0100, Niklas Wennerstrand wrote: > Hello Ralf, > The FTDI chip is not used in the ICD2 if I have read right on the > piclist. > It has accordingly to someone that has opened the ICD2 a cypress USB > chip. Ok. My bad. / Ralf | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: Ralf Forsberg ####@####.#### Date: 16 Nov 2002 17:13:05 -0000 Message-Id: <20021116170742.GA586@home.se> On Fri, Nov 15, 2002 at 09:16:54PM +0100, Niklas Wennerstrand wrote: > > If you want Microchip ICD2 to work under linux with Microchip USB > firmware in the cypress chip then you have to have a USB analyser > snooping the messages and a USB analyser is not something that ordinary > mortals can afford. I found this: http://sourceforge.net/projects/usbsnoop/ I have no idea if it would work. Perhaps someone with a ICD2 could try it out. / Ralf | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: Alessandro Zummo ####@####.#### Date: 17 Nov 2002 11:38:36 -0000 Message-Id: <yam9086.1456.143559448@mail.galactica.it> On 16-Nov-02 at 18:07:42, Ralf Forsberg ####@####.#### wrote: > On Fri, Nov 15, 2002 at 09:16:54PM +0100, Niklas Wennerstrand wrote: >> >> If you want Microchip ICD2 to work under linux with Microchip USB >> firmware in the cypress chip then you have to have a USB analyser >> snooping the messages and a USB analyser is not something that ordinary >> mortals can afford. > I found this: > http://sourceforge.net/projects/usbsnoop/ > I have no idea if it would work. Perhaps someone with a ICD2 could > try it out. usbsnoop is a very useful software, but doesn't work on every version of windows. i used it succesfully to develop a Linux driver.. i think i was running winblows 95 at that time. my opinion is that Microchip tunnelled on USB the same protocol used on the serial cable.. it's a quite common option. If this is the case, i could write the necessary support in the kernel to expose the ICD to the userland. To start, we need someone with an ICD2 and a Linux machine to provide us with some useful data: cat /proc/bus/usb or lsusb. -- - alex. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: Barry Gershenfeld ####@####.#### Date: 18 Nov 2002 21:04:34 -0000 Message-Id: <2.2.16.20021118130019.6b27401a@zmicro.com> >To start, we need someone with an ICD2 and a Linux >machine to provide us with some useful data: > > cat /proc/bus/usb >or > lsusb. > - alex. I can do that. I got the ICD2 when they first came out so I didn't know if the firmware inside would be relevant. Then I thought, it's probably a hardware thing, so just try it. Sorry for the length; I didn't know what to leave out. Barry ## Results of plugging in the device. # usb.c: USB device 2 (vend/prod 0x4d8/0x8000) is not claimed by any active driver. ## Results of ls -lR /proc/bus/usb /proc/bus/usb/: total 0 dr-xr-xr-x 1 root root 0 Nov 14 18:13 001 -r--r--r-- 1 root root 0 Nov 17 16:36 devices -r--r--r-- 1 root root 0 Nov 17 16:36 drivers /proc/bus/usb/001: total 1 -rw-r--r-- 1 root root 18 Nov 17 16:37 001 -rw-r--r-- 1 root root 18 Nov 17 16:37 002 ## 001 and 002 above are small binary files ## contents of 'drivers' usbdevfs hub ## contents of 'devices' T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=12 MxCh= 2 B: Alloc= 0/900 us ( 0%), #Int= 0, #Iso= 0 D: Ver= 1.00 Cls=09(hub ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1 P: Vendor=0000 ProdID=0000 Rev= 0.00 S: Product=USB UHCI Root Hub S: SerialNumber=ece0 C:* #Ifs= 1 Cfg#= 1 Atr=40 MxPwr= 0mA I: If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=255ms T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 2 Spd=12 MxCh= 0 D: Ver= 1.10 Cls=ff(vend.) Sub=ff Prot=ff MxPS=64 #Cfgs= 1 P: Vendor=04d8 ProdID=8000 Rev= 0.01 C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=100mA I: If#= 0 Alt= 0 #EPs= 0 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) I: If#= 0 Alt= 1 #EPs=13 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) E: Ad=81(I) Atr=03(Int.) MxPS= 16 Ivl= 10ms E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=84(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=04(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=86(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=06(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=88(I) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=08(O) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=89(I) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=09(O) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=8a(I) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=0a(O) Atr=01(Isoc) MxPS= 16 Ivl= 1ms I: If#= 0 Alt= 2 #EPs=13 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) E: Ad=81(I) Atr=03(Int.) MxPS= 64 Ivl= 10ms E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=02(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=84(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=04(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=86(I) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=06(O) Atr=02(Bulk) MxPS= 64 Ivl= 0ms E: Ad=88(I) Atr=01(Isoc) MxPS= 256 Ivl= 1ms E: Ad=08(O) Atr=01(Isoc) MxPS= 256 Ivl= 1ms E: Ad=89(I) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=09(O) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=8a(I) Atr=01(Isoc) MxPS= 16 Ivl= 1ms E: Ad=0a(O) Atr=01(Isoc) MxPS= 16 Ivl= 1ms ## Results of lsusb Bus 001 Device 001: ID 0000:0000 Virtual Hub Device Descriptor: bLength 18 bDescriptorType 1 bcdUSB 1.00 bDeviceClass 9 Hub bDeviceSubClass 0 bDeviceProtocol 0 bMaxPacketSize0 8 idVendor 0x0000 Virtual idProduct 0x0000 Hub bcdDevice 0.00 iManufacturer 0 iProduct 2 USB UHCI Root Hub iSerial 1 ece0 bNumConfigurations 1 Configuration Descriptor: bLength 9 bDescriptorType 2 wTotalLength 25 bNumInterfaces 1 bConfigurationValue 1 iConfiguration 0 bmAttributes 0x40 Self Powered MaxPower 0mA Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 0 bAlternateSetting 0 bNumEndpoints 1 bInterfaceClass 9 Hub bInterfaceSubClass 0 bInterfaceProtocol 0 iInterface 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x81 EP 1 IN bmAttributes 3 Transfer Type Interrupt Synch Type none wMaxPacketSize 8 bInterval 255 Language IDs: (length=4) 0000 (null)((null)) Bus 001 Device 002: ID 04d8:8000 Microchip Technology Inc. Language IDs: none (invalid length string descriptor 02; len=2) Device Descriptor: bLength 18 bDescriptorType 1 bcdUSB 1.10 bDeviceClass 255 Vendor Specific Class bDeviceSubClass 255 Vendor Specific Subclass bDeviceProtocol 255 Vendor Specific Protocol bMaxPacketSize0 64 idVendor 0x04d8 Microchip Technology Inc. idProduct 0x8000 bcdDevice 0.01 iManufacturer 0 iProduct 0 iSerial 0 bNumConfigurations 1 Configuration Descriptor: bLength 9 bDescriptorType 2 wTotalLength 218 bNumInterfaces 1 bConfigurationValue 1 iConfiguration 0 bmAttributes 0x80 MaxPower 100mA Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 0 bAlternateSetting 0 bNumEndpoints 0 bInterfaceClass 255 Vendor Specific Class bInterfaceSubClass 255 Vendor Specific Subclass bInterfaceProtocol 255 Vendor Specific Protocol iInterface 0 Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 0 bAlternateSetting 1 bNumEndpoints 13 bInterfaceClass 255 Vendor Specific Class bInterfaceSubClass 255 Vendor Specific Subclass bInterfaceProtocol 255 Vendor Specific Protocol iInterface 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x81 EP 1 IN bmAttributes 3 Transfer Type Interrupt Synch Type none wMaxPacketSize 16 bInterval 10 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x82 EP 2 IN bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x02 EP 2 OUT bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x84 EP 4 IN bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x04 EP 4 OUT bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x86 EP 6 IN bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x06 EP 6 OUT bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x88 EP 8 IN bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x08 EP 8 OUT bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x89 EP 9 IN bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x09 EP 9 OUT bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x8a EP 10 IN bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x0a EP 10 OUT bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 0 bAlternateSetting 2 bNumEndpoints 13 bInterfaceClass 255 Vendor Specific Class bInterfaceSubClass 255 Vendor Specific Subclass bInterfaceProtocol 255 Vendor Specific Protocol iInterface 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x81 EP 1 IN bmAttributes 3 Transfer Type Interrupt Synch Type none wMaxPacketSize 64 bInterval 10 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x82 EP 2 IN bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x02 EP 2 OUT bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x84 EP 4 IN bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x04 EP 4 OUT bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x86 EP 6 IN bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x06 EP 6 OUT bmAttributes 2 Transfer Type Bulk Synch Type none wMaxPacketSize 64 bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x88 EP 8 IN bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 256 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x08 EP 8 OUT bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 256 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x89 EP 9 IN bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x09 EP 9 OUT bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x8a EP 10 IN bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x0a EP 10 OUT bmAttributes 1 Transfer Type Isochronous Synch Type none wMaxPacketSize 16 bInterval 1 Language IDs: none (invalid length string descriptor 02; len=2) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: "benny k." ####@####.#### Date: 19 Nov 2002 01:18:05 -0000 Message-Id: <20021119012609.GF22088@bagu.org> On Sun, Nov 17, 2002 at 12:31:29PM +0100, Alessandro Zummo wrote: > usbsnoop is a very useful software, but doesn't work > on every version of windows. i used it succesfully to develop > a Linux driver.. i think i was running winblows 95 at that time. i found that snoopyPro (available at the same site) was a little nicer to use. i had problems with win98se but managed to get it working with winME. if somebody does decide to go snooping about, i can give them a mini-explanation of the snoopyPro output. it took me a little while to get my head around it b/c of the lack of documentation. i guess this should happen off the list b/c its not really related to the topic. > If this is the case, i could write the necessary support in > the kernel to expose the ICD to the userland. what about using libusb (http://libusb.sourceforge.net/)? ben | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: Alessandro Zummo ####@####.#### Date: 19 Nov 2002 02:15:20 -0000 Message-Id: <yam9088.126.143572208@mail.galactica.it> On 18-Nov-02 at 21:46:33, Barry Gershenfeld ####@####.#### wrote: >> To start, we need someone with an ICD2 and a Linux >> machine to provide us with some useful data: >> >> cat /proc/bus/usb >> or >> lsusb. >> - alex. > I can do that. I got the ICD2 when they first came out so I didn't > know if the firmware inside would be relevant. Then I thought, > it's probably a hardware thing, so just try it. > Sorry for the length; I didn't know what to leave out. [...] WoW! With so many endpoints this ICD would be difficult to address even with all the required specs.. i wonder if microchip really uses all of them. -- - alex. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: "Eric Smith" ####@####.#### Date: 23 Nov 2002 00:57:58 -0000 Message-Id: <1620.4.20.168.135.1038012732.squirrel@ruckus.brouhaha.com> > Also the ICD2 > has USB which gives better transfer rates, and has support for > the 18x chips. The USB chip that is used (FTDI), I have learned has > Linux drivers! So I imagine that you can just select a virtual serial > port in order to use the USB for the ICD2. FTDI? My ICD2 has a Cypress chip. Or does FTDI just resell Cypress parts with custom firmware? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: ICD
From: Ralf Forsberg ####@####.#### Date: 23 Nov 2002 17:49:49 -0000 Message-Id: <20021123174356.GA467@home.se> On Fri, Nov 22, 2002 at 04:52:12PM -0800, Eric Smith wrote: > > Also the ICD2 > > has USB which gives better transfer rates, and has support for > > the 18x chips. The USB chip that is used (FTDI), I have learned has > > Linux drivers! So I imagine that you can just select a virtual serial > > port in order to use the USB for the ICD2. > > FTDI? My ICD2 has a Cypress chip. Or does FTDI just resell Cypress parts > with custom firmware? Yes I got the chips mixed up, but Niklas corrected me. / Ralf | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 2 [>] [>>] |