avr-chat
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-chat] Reading Ports?


From: Peter Fuhrmann
Subject: Re: [avr-chat] Reading Ports?
Date: Mon, 5 Jun 2006 06:09:35 +0200
User-agent: KMail/1.7.2

Hello Chris!

Your problem is really simple, I made the same mistake a couple of times.

>         loop_until_bit_is_set(PORTB, PB5); // Wait until fully extended.
You need to use the PINB register instead of PORTB for reading the inputs. 
PORTB will only read back the value you have put there forever.

Regards,
Peter




reply via email to

[Prev in Thread] Current Thread [Next in Thread]