LCD_AnyPin.pbp


+ Reply to Thread
Results 1 to 40 of 113

Thread: LCD_AnyPin.pbp

Hybrid View

  1. #1
    Join Date
    Nov 2009
    Posts
    19


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Pic_User View Post
    See Darrel's Question...
    I'm sorry I don't understand your post, but I tried it with MCRLE_OFF and it makes no difference. I must have some other issues I'm yet unaware of. I have ordered a proper dev board so when that comes maybe I can get a handle on the problem.

    I had set MCRLE_ON from trying to interpret the data sheet:

    Page-212:
    MCLRE: RE3/MCLR pin function select bit(4)
    1 = RE3/MCLR pin function is MCLR
    0 = RE3/MCLR pin function is digital input, MCLR internally tied to VDD

    Page-215 (14.2.2)
    An internal MCLR option is enabled by clearing the
    MCLRE bit in the Configuration Word Register 1.

    When MCLRE = 0, the Reset signal to the chip is generated
    internally. When the MCLRE = 1, the RA3/MCLR pin
    becomes an external Reset input. In this mode, the
    RA3/MCLR pin has a weak pull-up to VDD.


    These data sheets are a long read and at times I'm having trouble interpreting some of the pages.

  2. #2
    Join Date
    Nov 2009
    Posts
    19


    Did you find this post helpful? Yes | No

    Default

    Ok, making great progress.

    I recieved my development board, plugged everyting in and coded up the demo example again ....and I'm getting text!
    (woo-hoo!)

    I'm getting:

    #numbers Hello,
    $hex From DT!

    is this correct?

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


    Did you find this post helpful? Yes | No

    Default

    Yessiree!
    That's what you should get.
    And the numbers should be counting.

    Congratulations!
    <br>
    DT

  4. #4
    Join Date
    May 2010
    Posts
    9


    Did you find this post helpful? Yes | No

    Default More LCD-AnyPin..

    Darrel,

    Top thanks to you for sharing such nifty code. Like your Bargraph code, I got it to work first time.
    If by chance that you are still running this thread, would you perhaps let me know what I'm doing wrong when I hook all 6 LCD lines to the same Port? It works fine when I hook E and RS to separate Ports.
    This is my first time with MPASM. I had to comment-out the config line, else it doesn't assemble.

    Thanks again.
    Respect for knowing all what you know about PICs.
    Attached Images Attached Images  

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


    Did you find this post helpful? Yes | No

    Default

    Hi Peter,

    I'm not sure what the problem is, but I ran your program on a 16F877a with all the LCD pins on PORTB, and everything worked fine.
    Although, with the pinout you are using ... you don't really need the LCD_AnyPin program (the data bus is on RB4-7).


    Name:  877a_AnyPin.JPG
Views: 7639
Size:  185.0 KB

    For the config error, see this page ...
    http://melabs.com/support/config_defaults.htm
    DT

  6. #6
    Join Date
    May 2010
    Posts
    9


    Did you find this post helpful? Yes | No

    Default

    I'm gobsmacked.
    Many thanks for taking the time to do that just on my account. Really appreciated.

    Your photo has given me a good clue; I see that you are using B.2 and B.3. Up til now I'd been using B.0 and B.1 only.
    It turns out that it only works from B.1 onwards (with both PBP *and* LCD_AnyPin). I thought it might be because of a hardware fault, but B.0 is fine with a temporary LED.
    It's all rather strange because the PBP manual implies that any PortB pin should work.

    Do you mind if I trouble you for one more question, pse?
    Could you have a look at my CONFIG and perhaps let me know why MSC gives an error when I try to compile without the semicolon?

    Thanks again to you for doing all that work on my account.

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


    Did you find this post helpful? Yes | No

    Default

    Well, I moved E and RS to RB0 and RB1 ... it still works.

    You might try turning that LED around and see if PORTB.0 will drive the output both ways.
    It could be that half of the output stage is toasted.

    And for the config error, you just need to comment the default configs in the .inc file.
    See this page ... http://melabs.com/support/config_defaults.htm
    DT

Members who have read this thread : 11

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