> > > Can anybody tell me how to read out a Rotary encoder with a pic (16f84)?? > The easiest way (in my opinion) is to feed one of the two outputs (I assume its a quadrature type) to B0 and the other one to any other input (probably B1). Set the B0 input to ext interrupt enabled . Whenever an interrupt is detected by an edge presenting itself (rising or falling .. its all programable) a movement of (pulses-per-rev divided by 360) deg has been made and if you read B1and there is a 1 there the encoder turned one way, if a 0 then it turned the other. If no interrupts are available (B0 is the only ext one) then you will need to poll one input and read the other on a change.... instead. _____________________________ Lance Allen Technical Officer Uni of Auckland Psych Dept New Zealand _____________________________