CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

7-segment display and keypad multiplexing

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Jake
Guest







7-segment display and keypad multiplexing
PostPosted: Tue Dec 30, 2003 10:01 am     Reply with quote

Anyone;

I am new to the PIC world and was wondering if anyone can help with some source code or a flow chart to get me going on a project that has 4, 7-segment displays multiplexed with a 2x3 keypad. I am using port B to drive the segments ( 7 plus the DP) and port D to drive the anodes of the 4 dislays and also to provide the 3 columns to the keypad matrix. The 2 rows for the keypads are read in port C.

What I am looking for is the proper timing to create the display and also, while a segment is 'turned ON' also be able to see if a key is hit.

If anyone can point me in a direction I would greatly appreciate it.

Thanks in advance and have a great New Year!

Jake
snoopy
Guest







PostPosted: Tue Dec 30, 2003 1:34 pm     Reply with quote

Hi

for 7 segment, i am using max7221. that is really simple way
to multiplex 7 segment, max7221 works with spi communication.

For the keypad, look there are several example on internet.

ex:

output_high(PIN_C2); //put pin c2 to high
if input(PIN_C0) //if input c0 is high
{ write would you like to do (a fonction)}
if input(PIN_C1)
{ write would you like to do(a fonction)} }

output_low(PIN_C2); //put pin c2 to low


output_high(PIN_C3); //put pin c3 to high
if input(PIN_C0) //if input c0 is high
{ write would you like to do (a fonction)}}
if input(PIN_C1)
{ write would you like to do (a fonction)}}


i try to give you a really beginner soft.

before begin software, you need to think what do you want to do.
write it on the paper and after make a little step by step sequence
of your program.

Good lock
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group