> -----Original Message----- > From: Drew Vassallo [SMTP:snurple@HOTMAIL.COM] > Sent: Wednesday, February 21, 2001 6:27 PM > To: PICLIST@MITVMA.MIT.EDU > Subject: Re: [PIC]: IIC Routines - giving, not needing > > > > The routines use consecutive bsf/bcf operations on a port throughout > >the > > > code. Although it might be bulletproof under the condtions you > > >Note that bsf/bcf operations are performed to the tris (data direction) > >registers, not to the port. > > Very true. I believe the problems encountered with consecutive PORT bit > operations are not applicable to TRIS registers. But otherwise, you'd be > right. > Heh, guess I should have looked a little closer before shooting that email off! I only mentioned it, because I had so much grief on the first ever PIC project I worked on (a PID TEC controller...talk about jumping in at the deep end!). The PIC was running at 4MHz and I was driving a MOSFET bridge to control current direction through the PIC. Couldn't understand why some bits weren't getting set :o) I suspect the MOSFET's had enough gate capacitance to upset things. Mike -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics