Darrel's SPWM and LCDOUT


Closed Thread
Results 1 to 23 of 23

Hybrid View

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


    Did you find this post helpful? Yes | No

    Default

    R-M-W is "Read-Modify-Write". It's the way PIC chips set an individual pin by reading the entire port, changing the 1 bit for the desired pin, then writing the whole port again. It can cause problems from time to time, but that is not the problem here. If the LCD and SPWM pins were on the same port it could have been. But I hadn't seen any code at the time, so I was guessing.

    And to keep from guessing again, could you post the whole program?

    I've run LCD's with SPWM before, so I don't think there's a common cause that I could point to. Hoping there's something else going on.
    <br>
    DT

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


    Did you find this post helpful? Yes | No

    Default

    Maybe just a LCD clear... or PSU noise.. who know?

    LVP_NOT set to OFF.. huh... how bad things could go with it...
    Last edited by mister_e; - 2nd April 2008 at 00:30.
    Steve

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

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


    Did you find this post helpful? Yes | No

    Default

    What surprises me is that the entire line changes to a different character.

    If it was a timing problem from the interrupts, I'd think it would be more Random.
    <br>
    DT

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


    Did you find this post helpful? Yes | No

    Default

    Looks like the PIC itself reset here and there... i still bet on some kind of noise... or UFO interferences... stack under/overflow?

    Fishing in the dark..
    Steve

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

  5. #5
    Join Date
    Mar 2008
    Location
    Gerogetown, Texas
    Posts
    94


    Did you find this post helpful? Yes | No

    Default

    Don't the DEFINES have to be in CAPs?

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


    Did you find this post helpful? Yes | No

    Default

    dEFINE, define or else variant will work, what's important it's on the right of it.
    Last edited by mister_e; - 2nd April 2008 at 01:36.
    Steve

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

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


    Did you find this post helpful? Yes | No

    Default

    I googled "Optrex DMC20481" and found a post on another forum suggesting that the LCD_COMMANDUS of 2000 was too low for that display. He said that 3000 worked for him.

    I pulled up the datasheet, and there doesn't seem to be any mention of the actual delays required. I guess if they're that bad, I wouldn't want to publish them either.

    Something to try.
    <br>
    DT

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