On Sat, 2006-03-18 at 08:25 -0800, andyteleco wrote: > Hi, I'm writing some routines to read a DS2411 (serial number) chip using a > PIC and to send the data to a PC via a DIO card. The communication with the > chip is perfect and the number is read, but I can't send the data to the PC > since I want to use RB3 as a strobe signal and for that I need to set > TRISB(3)=0, which I can't achieve (TRISB stays at the same value after > writing on it). I'm using an MPLAB ICD2 with the PICStart Plus programmer. > The communication fails both on programmer and debugger mode. RB3 is used for PGM as well, are you sure you don't have low voltage programming enabled (config bits)? If you did that pin would be reserved for low voltage programming enable. Otherwise that pin is also used by the CCP circuitry. The "normal" default state in my mind for that circuitry is disabled, but I'm not 100% familiar with the F88, so you should check the datasheet. Any time you use a pin on a PIC that has more then one purpose, you must check the datasheet to assure you've disabled what you don't want. A good example of this (which isn't applicable in your case) is analog stuff (comparator and ADC inputs). The MChip default state for pins with these functions is analog enabled. TTYL ----------------------------- Herbert's PIC Stuff: http://repatch.dyndns.org:8383/pic_stuff/ -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist