![]() |
|||||||||||||||||
![]() |
|
Custom Search
Readers
comments
|
|||||||||||||||
16F84a Counting RA4 Input : output to single LEDs : commentFor the moment there are some problems in displaying comment text directly so I have re-created Justins entry here:I don't understand. Do you want it to count the number of times you press a button and display a different LED for each press? That would be easily done with something like unsigned short x = 0 void main () { if (porta & (1<<4)) { // check key press delay_ms (20); // wait for boucing while (!porta & (1<<4)) ; //wait for release ++x } if x == 1 ... //first press if x == 2 ... //second press if x == 3 ... //etc } Hope this helps, Justin Back to original problem |
|||||||||||||||||
|
|
|||||||||||||||||
|
|||||||||||||||||