pic 16f887 memory question


Closed Thread
Results 1 to 9 of 9
  1. #1
    Join Date
    Dec 2010
    Posts
    48

    Default pic 16f887 memory question

    I have a few questions regarding the memory on the pic 16f887. First, if I write to the EEPROM memory on the chip, will that limit the amount of words I can have in my program? Also, what kind of external memory can I have the '887 communicate with? Has anyone done this before successfully? I'm trying to write a program with a lot of LCDOUT commands (I'm using a 4x20 lcd). Each four line LCDOUT command uses a little over 200 words, and I can fit roughly 35-40 four line LCDOUT commands per chip. I'm trying to use around 1000 four line LCDOUT commands and I'm pretty stumped. What should I do? Thanks to everyone for your help.

  2. #2
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    The program and data areas are separate.
    You can use an I2C EEPROM.

    Not seeing your code and not knowing what you want to write to the display...
    Might think about a sub routine to send data to the display and just update the variables being sent.

    And you do not have to write to all the lines on the display at once.
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Dec 2010
    Posts
    48


    Did you find this post helpful? Yes | No

    Default

    Well, I'm trying to make a text based RPG, so I'm going to need a lot of screens to describe the different rooms you're in. I also want to have different screens that show character status, inventory, etc., so your idea of having a subroutine and only updating variable values will apply there. My plan is to have at least 6 different levels (preferably 8). Is it possible to put picbasic code in the I2C EEPROM or does it not work like that? I'm not familiar with EEPROM and how it works.
    Last edited by emerson; - 14th January 2011 at 13:31.

  4. #4
    Join Date
    Jan 2009
    Location
    Miami, Florida USA
    Posts
    644


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by emerson View Post
    Is it possible to put picbasic code in the I2C EEPROM or does it not work like that? I'm not familiar with EEPROM and how it works.
    No, that I know. However you can go with a PIC that has more program memory available. You can use this page to find the chip that you need.

    http://www.microchip.com/maps/microcontroller.aspx

    Robert
    "No one is completely worthless. They can always serve as a bad example."

    Anonymous

  5. #5
    Join Date
    Dec 2010
    Posts
    48


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by rsocor01 View Post
    No, that I know. However you can go with a PIC that has more program memory available. You can use this page to find the chip that you need.

    http://www.microchip.com/maps/microcontroller.aspx

    Robert
    That webpage is great! I think I'm going to try the DSPIC128MC804IPT. Thanks for the help.

  6. #6
    Join Date
    Jan 2009
    Location
    Miami, Florida USA
    Posts
    644


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by emerson View Post
    That webpage is great! I think I'm going to try the DSPIC128MC804IPT. Thanks for the help.
    PBP does not support that PIC. You might need to use another language like C32 from Microchip.
    "No one is completely worthless. They can always serve as a bad example."

    Anonymous

  7. #7
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    If you are planning to use PBP then you may want to look at supported parts for PBP.
    http://melabs.com/includes/compatibility/pbp.pics.htm

    Go with an 18F for new projects.
    Dave
    Always wear safety glasses while programming.

  8. #8
    Join Date
    Dec 2010
    Posts
    48


    Did you find this post helpful? Yes | No

    Default

    Ok, so I chose the 18f4620, I have a new question though. When you compile your program in Microcode Studio and it tells you in the bottom left corner that your program uses (in my case) 1632 bytes, do I compare that to the chips 64K bytes of flash memory? I'm used to it telling me how many words I've used, not bytes.

    here is the datasheet for the chip:

    http://ww1.microchip.com/downloads/e...Doc/39626b.pdf

  9. #9
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    "do I compare that to the chips 64K bytes of flash memory?"

    Yes.
    Dave
    Always wear safety glasses while programming.

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