display lcd variable array Ascii


Closed Thread
Results 1 to 9 of 9
  1. #1
    Join Date
    Oct 2005
    Posts
    32

    Unhappy display lcd variable array Ascii

    Hello!

    If I want to writer the value of a variable one in ASCII on a display I write LCDOUT $$FE, 1, #var1 that is I precede with the # var1, if the same thing with an Array is wanted to be made as it could be made? sintax is LCDOUT $$FE, 1, str var\08 if I put # before var the compiler gives me error.

  2. #2
    Join Date
    Jun 2005
    Location
    Wisconsin
    Posts
    382


    Did you find this post helpful? Yes | No

    Default

    I don't know that there is a short hand way to do that. In the past I have either made the string ASCII via addition or written one byte at a time to the lcd.

    BTW I tend to use DEC variable in place of # variable.

  3. #3
    Join Date
    Oct 2005
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by DynamoBen
    I don't know that there is a short hand way to do that. In the past I have either made the string ASCII via addition or written one byte at a time to the lcd.

    BTW I tend to use DEC variable in place of # variable.
    not there are other solutions?

  4. #4
    Join Date
    Jun 2005
    Location
    Wisconsin
    Posts
    382


    Did you find this post helpful? Yes | No

    Default

    Do this....it works great.

    For idx = 0 to 7
    LCDOUT $FE, 1, #var[idx]
    next idx

  5. #5
    Join Date
    Aug 2005
    Posts
    42


    Did you find this post helpful? Yes | No

    Default

    lcdtest var byte[3]

    lcdtest(0)="1" 'ASCII value for 1
    lcdtest(1)=$32 'HEX value for 2
    lcdtest(2)=51 'DEC value for 3

    'Cear Display and Output to line 1
    LCDOUT $FE,1,str lcdtest\3

    Will display 123 on LCD.

    Regards

    Sean.

  6. #6
    Join Date
    Oct 2005
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Thanks to all however I have resolved using the commando lookup

  7. #7
    Join Date
    Oct 2005
    Posts
    32


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by sean-h
    lcdtest var byte[3]

    lcdtest(0)="1" 'ASCII value for 1
    lcdtest(1)=$32 'HEX value for 2
    lcdtest(2)=51 'DEC value for 3

    'Cear Display and Output to line 1
    LCDOUT $FE,1,str lcdtest\3

    Will display 123 on LCD.

    Regards

    Sean.
    hello!

    which it is the difference between:

    I2CREAD SDA,SCL,pag1,0,[str password\4]
    LCDOUT $FE,1,str password\4

    it is

    for ind_ep = 0 to 3
    I2CREAD SDA,SCL,pag1,ind_ep,[password[ind_ep]]
    pause 20
    next ind_ep
    LCDOUT $FE,1,str password\4

  8. #8
    Join Date
    Jun 2005
    Location
    Wisconsin
    Posts
    382


    Did you find this post helpful? Yes | No

    Default

    You don't need to pause when reading an I2C buss. You only really need a pause when writing to it.

    Both examples are functionally the same. The first one is much easier to ready.

  9. #9
    Nitro's Avatar
    Nitro Guest


    Did you find this post helpful? Yes | No

    Default another way?

    couldnt you just say
    lcdout "var="
    ?????

Similar Threads

  1. Hdsp 21xx display
    By Original in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 7th June 2012, 20:07
  2. LCD Display
    By lambert in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 16th January 2010, 22:18
  3. assembly in Pic
    By lerameur in forum Off Topic
    Replies: 11
    Last Post: - 1st May 2008, 20:06
  4. LCD display not working properly
    By dilpkan in forum mel PIC BASIC Pro
    Replies: 14
    Last Post: - 2nd February 2008, 07:43
  5. LCD Display not working - PIC heating...
    By flotulopex in forum mel PIC BASIC Pro
    Replies: 32
    Last Post: - 24th September 2006, 07:35

Members who have read this thread : 2

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