NerdKits - electronics education for a digital generation

You are not logged in. [log in]

NEW: Learning electronics? Ask your questions on the new Electronics Questions & Answers site hosted by CircuitLab.

Microcontroller Programming » Accessing PB1 - 5

August 03, 2011
by Elementell
Elementell's Avatar

How do I access pins PB1-5? setting PORTC =| (1<<PB2) doesn't work, and neither does PORTB.
Can anyone help?
Are they inaccessible?

August 04, 2011
by Robotnik
Robotnik's Avatar
DDRB |= (1<<PB2);  //set PB2 to output
PORTB |= (1<<PB2); //set PB2 to output 5 volts/logical 1

Post a Reply

Please log in to post a reply.

Did you know that you can use printf and scanf functions to talk to your computer from your USB NerdKit? Learn more...