> > At 07:59 PM 2/2/97 +0000, you wrote: > >Hi Mike, > > > >> Hello! I am working on a project that uses a 16C56 chip. Will the COM84 > >> programmer read and program this chip? > > > >No. The 16C56 needs a 14-wire interface (2 clocks + 12 data) to program > >it compared to the 2-wire (clock + data) interface provided by the > >COM84 programmer. > > Thanks for the reply David. Now how do i build a 16C56 programmer? Well a 16C5X programmer is a bit tougher thatn the 16C84 not only because of the 14 pin interface but also because the 16C5X chips are EPROM based not EEPROM based. The two big changes from that are that you need a 100 uS (microsecond) pulse for programming and that the Vpp voltage actually uses real current (up to 50ma IIRC). Such a programmer is on my task list. It may even get done this year ;-) IMHO the cleanest way to build a programmer is to bootstrap off the 16C84. With the 16C84 you can get the precise 100 uS pulses you need and encapulate most of the functionality in the programmer, not the PC program. Also the 16C84 is easy to program/reprogram using the COM84 programmer. The biggest problem with the 16C84 is the lack of I/O pins. So you'll need a few support chips to get the I/O you need. The programmer breaks down into three sections: 1) I/O to the 16C5X chip. For output use two 74C595 3-state serial shift registers. Why? a) Only requires 4 wires to shift, latch, and tri-state 16 lines. b) Can be tri-stated so that you can read back the data written to the 16C5X chip. For input use two 74HC244 octal buffers because the data can be read in 4 bits at a time. The fourth half buffer can be used to buffer 4 bits of one of the '595s so that the other 4 bits of that '595 can be used to the 244 output enables. 2) Vpp control. Vpp needs to swing from 0V to 13V. My favorite circuit for this is to use an LM317 variable regulator configured as a programmable regulator using a resistor to the ADJ pin to set 13V and a Open Collector buffer to the pin to set 1.25V. In addition the MCLR/Vpp pin on the PIC should be connected to Vpp via a 100 ohm resistor to limit current. The 1.25V though that resistor only gives 12ma of current which can easily be sucked down by another OC buffer (a 7406 gives you 6 of them) So with a LM317, 3 resistors, and a 7406 you can control the Vpp using only one 16C84 pin. 3) PC interface. A couple of options here. The easy way is to build a 4 wire interface to the parallel port described on the list a couple of days ago. It's basically two data lines, a clock, and a handshake line. Even better is to use one of the 7406 OC buffers to buffer the data line so that you only need one data line. The PC can drive the data line when it wants to send data and to set the data line to an OC state when it wants to read. In fact the weak pullups on the B port of the 16C84 can be utilized so that you don't need an extra pullup resistor. The other option is to add a MAX232 and connect to the serial port. Only requires two pins from the 16C84. Ok how do you hook it up? A0-A2 of the 16C84 connect to the DATA, CLK, and LATCH of the 74C595's. The high 4 bits of the 595 closest to the 16C84 are buffered through 1/2 of one of the 244's. Those 4 bits plus the whole 595 further away from the 16C84 are the output 12 bits to the 16C5X. The low 4 bits of the closer 595 connect to the output enables of the other 3 1/2s of the 244's and the output enables of the 1/2 244 connected to the 595 and the output enable of the further 595. B4-B6 are the PC interface. B0-B3 connect to the outputs of the 3 1/2's of the 244s whose inputs are connected to the 12 input bits from the 16C5X chip. B7 Clocks the programming pulse line of the 16C5X chip. A3 Clocks the increment address line of the 16C5X chip. A4 controls the programmable voltage generator. The generator should be wired to produce 13V when A4 is low. So with a wall wart (15-18V), a 16C84, 5 TTL chips, and the programmable voltage generator, along with the program that glues it all together. It can be pulled together. I know a picture would do wonders to describe this but I just don't have time to do it right this second. Maybe later this week. A lot of the support chips are due to the lack of I/O pins on the 16C84. This could be solved by using a 40 pin 16CXX chip (line the 16C65 or the 16C74) Since these are serially programmable (like the 16C84) a 16C84 plus the programmable voltage generator is all you need to program the bigger chips. You could then build the programmer from that bigger chip eliminating all of the support chips except the 7406. Plus you get a parallel slave port and a serial port in the bargain. So there's some thoughts. Hope they help. BAJ