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

creating menus and display it on LCD

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



Joined: 05 Sep 2007
Posts: 252

View user's profile Send private message

creating menus and display it on LCD
PostPosted: Sun Sep 16, 2007 9:56 pm     Reply with quote

Hi,
I am using PIC16f877a,ccs compiler (version 4.020).i want to know something.i want to create menus which can be displayed on LCD.i am using LCD (LMB202D) which is 20x2.actually i want to create different menus which shows me different values like
1-input voltage
2-output voltage
3-input Vmin and Vmax range
4-output Vmin and Vmax range

when i enter in one of the above menu it will show me some data regarding to the menu name.
i hope u guys will understand my question.can anyone tell me how can i do this or anyone have any example.
Foppie



Joined: 16 Sep 2005
Posts: 138
Location: The Netherlands

View user's profile Send private message Send e-mail Visit poster's website MSN Messenger

PostPosted: Mon Sep 17, 2007 1:14 am     Reply with quote

you could do the following, however this is not really a menu.

You could make a global variable declaring your LCDstate and an button interrupt increasing this variable on each button press with one.

from your main you can than call a update_LCD function that could look like this:
Code:
void lcd_update()
{
   switch (lcd_state)
   {
      case 0:
         printf(lcd_putc, "\fyour startup screen");
      break;
      case 1:
         printf(lcd_putc, "\finput voltage\n%u", input_voltage);
      break;
      default:
         lcd_state = 0; //makes the lcd cycle complete
      break;
   }
}
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