On Mon, Mar 08, 1999 at 12:14:22AM -0800, Gerhard Fiedler wrote: > in my data sheets of all the 16c7x series it says "the trisa register > controls the direction of the ra pins, even when they are being used as > analog inputs" in the porta chapter, and "the port pins that are desired as > analog inputs must have their corresponding tris bits set. if the tris bit > is cleared, the digital output level (Voh or Vol) will be converted" in the > adc chapter. > > i read this as that the output level will actually be a digital one (Voh or > Vol) in case the tris bit is cleared (which is consistent with the > schematic of the porta inputs in the data sheets). do you read something > different here? Well, at no point does it actually say that if the TRIS bit is cleared will the digital output level appear on the pin; the statement about "the output level will be converted" means that the analog input will see the digital output , but says nothing about what will appear on the external pin. Certainly nothing in the text is a clear assurance that with TRIS cleared the pin will work as an output, OTOH I agree with you that the logic diagram does se em quite clear; but I know that in practice, I found it not to work. Also remember that the logic diagram is illustrative only, and is not the actual circuit. If I get time, I'll run some tests again, just to get to the bottom of this. Cheers, Clyde -- Clyde Smith-Stubbs | HI-TECH Software Email: clyde@htsoft.com | Phone Fax WWW: http://www.htsoft.com/ | USA: (408) 490 2885 (408) 490 2885 PGP: finger clyde@htsoft.com | AUS: +61 7 3355 8333 +61 7 3355 8334 --------------------------------------------------------------------------- HI-TECH C: compiling the real world.