LCD BARgraphs


Results 1 to 40 of 233

Thread: LCD BARgraphs

Threaded View

  1. #1
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959

    Default LCD BARgraphs

    LCD BARgraphs
    LCDbar_INC.bas
    is an Include file that makes it easy to create BARgraphs on your LCD display.

    Features:
    • Can be placed anywhere on the screen.
    • Can be any width (whole characters)
    • Can be scaled anywhere between 0 and 32768.
    • Three styles to choose from.  {lines, boxed, blocks}
    • Just 1 Command does it all. (Well, sort of)
    Click here for Larger Video (225kbps)


    Code:
    @   BARgraph   Value, Row, Col, Width, Range, Style  
      
    Value: The Value of the BARgraph  (0 to Range).If Range = 100 and Value is 50, then            
              half of the BARgraph will be filled in.   Value MUST be a WORD sized variable¹  
    
    Row: LCD Row to place the BARgraph (1 to 4)   can be either a constant or a  
              variable¹.  
    
    Col: LCD Column to place the BARgraph (0 to LCDsize² - 1)   can be either a constant  
              or a variable¹. 
    
    Width: Width of the BARgraph in charaters. (1 to LCDsize²)   can be either a constant  
              or a variable¹. 
    
    Range: The "full-scale" range of the BARgraph  (0 to 32768) MUST be a constant.  
              Variables will not work here. 
    
    Style: Selects which Style will be used for the BARgraph  (lines, boxed, blocks)   can  
              be either a constant or a variable¹.  
    
    Note ¹ - Variables must be preceeded with a 
                 underscore.   ie.  _Temperature    
    Note ² - LCDsize is the number of Chars in 1 line of 
                 the LCD, for "4x16" it's 16
    Added 10/18/05 - If using a 4x20 display, you can use this define to let the program know the addressing is different.   Thanks, CocaColaKid!
    Code:
    DEFINE  LCD4X20  1
    Attached Files Attached Files
    Last edited by mackrackit; - 15th September 2011 at 09:08.

Similar Threads

  1. Is this code not initialising the LCD properly?
    By Platypus in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 30th January 2010, 19:14
  2. 16f688 LCD what have I done wrong
    By spitfiredriver in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 8th August 2009, 19:54
  3. Play with LCD on PICDEM
    By The IceMan in forum mel PIC BASIC
    Replies: 5
    Last Post: - 22nd August 2008, 16:56
  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 : 1

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