LCD_COMMANDUS define


Closed Thread
Results 1 to 6 of 6
  1. #1

    Default LCD_COMMANDUS define

    I have an Winstar 20x4 OLED display which works well and looks great apart from the fact the clear screen command takes 6.5ms.

    http://www.rapidonline.com/Electroni...Yellow-57-2302

    I don't want to change the LCD_COMMANDUS define to 6500 to cope with this as it also pauses every other command and wastes a huge amount of time, as all the other command require no delay according to the data sheet. So the command and data delay can be 1us or something tiny in all except the clear screen scenario.

    Is there any way to get LCDOUT to pasue for a varying length based on the command being sent.

    So for instance it recognises the clear screen command and only in that case pauses for a set time.

    So in effect can we have another define please for the next version of PBP.

    LCD_COMMANDUS 2000 as now for general commands

    LCD_COMMANDCLRUS 7000 for the Clear Screen Command

  2. #2
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,648


    Did you find this post helpful? Yes | No

    Default Re: LCD_COMMANDUS define

    Oleds are known to be sloww ... that's it !!

    now ... there should be a " busy " line somewhere ...

    BUSY FLAG (BF)
    The Busy Flag is used to determine whether IC is idle or internally operating. When IC is performingsome internal operations, the Busy Flag is set to "1". Under this condition, the no other instruction willnot be accepted. When RS Pin is set to "0" and R/WB Pin is set to "1", the Busy Flag will
    be outputted to the DB7 pin.
    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  3. #3
    Join Date
    Aug 2003
    Posts
    985


    Did you find this post helpful? Yes | No

    Default Re: LCD_COMMANDUS define

    can't you PAUSE 65 after sending the clear screen?

    LCDOUT $FE,$01
    PAUSE 65

    I would imagine it takes the same time to receive the command as any other,
    with the delay being to act on the clear screen command.

  4. #4
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,604


    Did you find this post helpful? Yes | No

    Default Re: LCD_COMMANDUS define

    Hi,
    Or you could do the pause "manually", something like:
    Code:
    i VAR BYTE
    
    Main:
      GOSUB LCD_ClearScreen
      LCDOUT["The value of i is: ", DECi]
      i = i + 1
    GOTO Main
    
    LCD_ClearScreen:
      LCDOUT[$FE, 1]  ' Clear Screen
      PauseUs 6500     ' Tweak to match...
    RETURN
    /Henrik.

  5. #5


    Did you find this post helpful? Yes | No

    Default Re: LCD_COMMANDUS define

    I could put a pause after every clear screen command but I don't wan't the code bloat.

    An extra define would be nice I'll ask the pbp developers. Add it to the wish list.

    I quite like the sub routine idea but an addition to the library routine would seem simplest.

  6. #6
    Join Date
    Aug 2003
    Posts
    985


    Did you find this post helpful? Yes | No

    Default Re: LCD_COMMANDUS define

    You don't put a pause after every clear screen, you just do it once:

    ClearOLED:
    LCDOUT $FE,$01
    PAUSE 65
    return

    add that to your code once, and just call ClearOLED.

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