LCD port bit choices


Closed Thread
Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2004
    Location
    New Hampshire
    Posts
    76

    Default LCD port bit choices

    Hi all,

    Much of the electronics work I do is by example... I'm a mechanical guy by trade and I'm designing my second circuit board. Scarry huh?

    That said... I'm trying to lay out circuits for a 16f876. I'd like to use portc for a six wire hookup for an LCD display. Most examples I find show the four data lines connected to the upper for bits of a port such as RC7, RC6, RC5, RC4. But TX and RX are on the upper two bits of portC and I'd like to use those for in-circuit programming via max232 and bootloader.

    The lines of code (I have seen) used to set up the ports for LCD use in PicBasic Pro do not appear to point to any particular port bits (that I've found). And believe me I've looked.

    I am trying to keep portB open for other stuff and portA is being used for analog inputs.

    Can someone please point me to the information I am looking for. Or at least tell me if I am on the right track.

    How do I tell the processor and PicBasic Pro which individual port BITS I am connecting my six wire LCD to on a 16f876?

    I hope this wasn't too stupid a question. :-P

    Many thanks,

    Ross
    Never enough knowledge to be called intelligent but just enough knowledge to be considered dangerous!

    I like that! :-)

  2. #2
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default

    rossfree, As long as you can have 4 i/o port pins in a row starting at portx.0 or portx.4 then you have got it. The control pins can be placed on any of the other i/o pins. This is in the manual.....

    Dave Purola,
    N8NTA

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


    Did you find this post helpful? Yes | No

    Default

    Dave I'm with you in this "problem." The answer you received from rossfree is correct. The data lines need to start at 0 or 4 on one of the three ports. RS and E can go anywhere.

    I too have a project using the USART, analog inputs, external interrupt, and much of port B. I ended up using PortB.4-7 for the datalines, PortB.3 for E, and PortC for RS. When I laid out the PCB this kept everything on one layer w/o overlap (vias). BTW I'm also using CCP1 to control contrast via PWM.

    Hope this helps.

  4. #4
    Join Date
    Oct 2004
    Location
    New Hampshire
    Posts
    76


    Did you find this post helpful? Yes | No

    Default

    Thanks guys,

    That clears things up. And I'll get back into that manual.

    Thanks again!

    Ross
    Never enough knowledge to be called intelligent but just enough knowledge to be considered dangerous!

    I like that! :-)

Similar Threads

  1. 16f688 LCD what have I done wrong
    By spitfiredriver in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 8th August 2009, 20:54
  2. first project, and yes, doesn`t work
    By bogdan in forum mel PIC BASIC Pro
    Replies: 15
    Last Post: - 28th April 2009, 07:13
  3. Microcontroller with 2 way paging application problem
    By oneohthree in forum mel PIC BASIC Pro
    Replies: 30
    Last Post: - 20th April 2007, 18:27
  4. Running an LCD on different port
    By malc-c in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 18th December 2006, 07:41
  5. encoder wowes
    By wallaby in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 6th December 2005, 22:56

Members who have read this thread : 1

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