More Powerful LCD Commands


Closed Thread
Results 1 to 32 of 32

Hybrid View

  1. #1
    Join Date
    Jun 2006
    Location
    Bangalore, India
    Posts
    136


    Did you find this post helpful? Yes | No

    Question

    mister-e , in the "C" psuedo-code give on the link mentioned above ,
    This is what i understood so far.
    To send any data to the LCD, the "LCDNybble" function has to be called twice with the character / command data in the variable "Nybble".
    The Nybble variable should be fed with the corresponding upper and lower bits sequentially.

    Does the "LCDNybble" function take care of pulsing the E pin of LCD?
    Myke has mentioned that before strobing the E pin, a 450ns pause is necessary.
    Will PAUSEUS 1 work?
    Last edited by shahidali55; - 6th June 2007 at 13:43.

  2. #2
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by shahidali55 View Post
    Myke has mentioned that before strobing the E pin, a 450ns pause is necessary.
    Will PAUSEUS 1 work?
    PAUSEUS 1 = 1000ns
    1000ns > 450ns
    Yes

  3. #3
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Math are good... but depending your OSC speed, you may want to use a serie of @ NOP instead.

    Have a look in the manual about PAUSEUS limitations.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  4. #4
    Join Date
    Jun 2006
    Location
    Bangalore, India
    Posts
    136


    Did you find this post helpful? Yes | No

    Post

    Based on the pseudo C code on page http://www.myke.com/lcd.htm,
    i made my own code. I have attached it with this post.
    Can someone chech it out and tell if what i've done is correct?
    I tested the commands using Dincer's JavaScript LCD Simulator V 1.05.
    (http://www.geocities.com/dinceraydin.../djlcdsim.html)
    This code should display the digit "1" on the display.
    Attached Files Attached Files
    Last edited by shahidali55; - 6th June 2007 at 18:43.

  5. #5
    Join Date
    Mar 2008
    Posts
    9


    Did you find this post helpful? Yes | No

    Default

    might be kinda nice to have a least-significant-digit location set. for instance if you need to display a variable that changes from 1 digit (0-9) to 3 digits (100, etc), and you need to display 4 of them at a time, the code starts to get very lengthy....

    i normally do an IF+THEN and if less than X, then add a space, but doing this for 4 variables, with 1 to 3 digits gets be rather long, and very hard to debug...

    LCDOUT $FE, 1, DEC VAR [10], "Hello" 'display decimal value of <VAR> with least significant digit at space 10

  6. #6
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Sorry i don't follow you could you shed some light on that?

    Why not updating only some fields on the LCD? Do you need Left/Right Aligned thingy?
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  7. #7
    Join Date
    Mar 2008
    Posts
    9


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e View Post
    Sorry i don't follow you could you shed some light on that?

    Why not updating only some fields on the LCD? Do you need Left/Right Aligned thingy?

    if you say this:


    VAR = 1
    LCDOUT $FE, 1, " ", DEC VAR 'three spaces

    you will get on the screen
    >___1< but lets say your variable becomes 100, you will get:
    >___100< i want to get it to say:
    >_100<


    so the first digit of the variable is the "setpoint," and if its one or 5 digits long, the first one will always be in the same place. not too big of a deal, but if you want to run 2 or 3 variables on the screen at the same time (and vary from 1 to 100), then it kinda sucks to program that....

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. Need help with LCD number display.
    By Steve Matson in forum mel PIC BASIC
    Replies: 8
    Last Post: - 26th June 2007, 23:07
  4. LCD will not start
    By btaylor in forum mel PIC BASIC Pro
    Replies: 49
    Last Post: - 24th May 2007, 02:30
  5. Dedicated LCD Controller question
    By chuckles in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 27th February 2006, 14:44

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