Hello PIC users I have been on the PICLIST for some time now, but this is my first posting because I haven't had much time. First a short introduction: I'm an EE student in my last term - I hope :) I live in Denmark and have been working with PIC's since 1991. One of my first PIC projects was to write an assembler since the tools Microchip provides were (and still are) slow, buggy and generally user unfriendly. The first version was a command line program, but soon it became an Borland-like IDE (Integrated Development Environment) with menus, multi-file editor, etc. The next step was to add a simulator/debugger. This gave me some problems, because Microchips manuals doesn't tell all you need to know. In some cases the manuals are even misleading. Some of the tricky areas are RTCC synchronization, interrupts and A/D timing (in PIC16C71). To get the information I need, I have written some small programs, and tested them on the real thing (i.e. PIC's). This means that my debugger behaves exactly like the hardware, which is more than I can say for any other debuggers I have worked with (Microchip, Transdata etc.). I have also found a bug with the TO (TimeOut) bit in the Status register. Sometimes the bit is not set correctly after a MCLR reset. If anybody is interested I can post some more info. Currently I'm working on PIC16C84 support for the debugger, and I found some "features" regarding the data EEPROM: When you want to write to the EEPROM, you have to set up the address (EEADR) and data (EEDATA) and then execute the following sequence: MOVLW 55h MOVWF EECON2 MOVLW 0AAh MOVWF EECON2 BSF EECON1,WR to initiate the self timed erase/write cycle. (and of course the write enable (WREN) bit must have been set). This rather awkward procedure is used to minimize the risk of unintended writes to the data EEPROM, which may hold important data. BUT... What happens if you change the EEADR after the erase/write cycle has been started ? To test, I wrote a program that initiated a write and then incremented the EEADR register every 0.5ms. Result: 4 (!) EEPROM locations were erased and the data was written into a 5. location... Looks like Microchip forgot an address latch. Michael Brinks