LCD menu


Closed Thread
Results 1 to 5 of 5

Thread: LCD menu

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    Yes, there is always another way...

    One of my products (on an 18F2420) has a 5 level Menu structure, that is 170 items deep! With 3 Button Control and an LCD. It is on a product which sells 1000/month and which competitors can't figure how it's done! So I won't give you the code, because it'll hand them the secret (and I know they read this forum)... but I will generalise...

    The Menu consists of a 8 Byte Table per line... the Table is held in program codespace (see elsewhere on this forum how to do that).

    Byte 1 tell the Menu Subroutine what kind of Data Element we are dealing with... ie, Numeric, Numeric with Fixed Decimals, Alphanumeric, Date, Time etc.

    Byte 2 is the Data Element Byte Length.

    Byte 3 is the Minimum permitted value for any Numeric entry.

    Byte 4 is the Maximum permitted value for any Numeric entry.

    Byte 5 are Flags... these are Bits that Control frills, eg Cursor ON/OFF, Visible or Invisible Entry (like that required for Passwords) , whether Data-Entry is permitted or not, etc etc

    Byte 6 points to the location in EEPROM where the first Byte of Data is to be found.

    Byte 7 points to the Message in Program Codespace which will appear on your LCD prompting your Data-Entry (eg "Enter Time Delay").

    Byte 8 points to a secondarry Message in Program Codespace for additional information (eg "Minutes").

    The Menu Subroutine, sequentially reads the eight control bytes and acts on it accordingly. Once you have built your subroutine, it's a simple matter of adding just eight bytes (plus prompting messages) per Menu item. It's small, it's compact, and everything you need to learn how to do it is on this forum somewhere (though not in a ready cut & paste form). Clue: It does rely very heavilly on reading large Tables of Data from Program Codespace and manipulating Alphanumeric STRINGS (for all the LCD Messages) with PBP. Sort out how to do that first, and the rest is simple!

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,115


    Did you find this post helpful? Yes | No

    Default

    Nice one Mel. I suppose that this part is one ofthe memory hungry ones.

    Ioannis

Similar Threads

  1. 16f688 LCD what have I done wrong
    By spitfiredriver in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 8th August 2009, 19:54
  2. Play with LCD on PICDEM
    By The IceMan in forum mel PIC BASIC
    Replies: 5
    Last Post: - 22nd August 2008, 16:56
  3. Sending menu to PC from PIC16F876A
    By joseph Degorio in forum Serial
    Replies: 2
    Last Post: - 12th November 2007, 07:03
  4. Need help with LCD number display.
    By Steve Matson in forum mel PIC BASIC
    Replies: 8
    Last Post: - 26th June 2007, 23:07
  5. LCD will not start
    By btaylor in forum mel PIC BASIC Pro
    Replies: 49
    Last Post: - 24th May 2007, 02:30

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts