Limit of PokeCode??


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

    Default Limit of PokeCode??

    I have to load 500bytes of data to my 877a. I have started at location 7100. I put this statement first towards the start of the code:

    Code:
    ERASECODE 7100
    I then used the POKECODE @7100 .............

    The problem is that after 255 locations I am getting problem with the compiler. How can I load 500 bytes of data without any interruption in between?
    ___________________
    WHY things get boring when they work just fine?

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


    Did you find this post helpful? Yes | No

    Default Re: Limit of PokeCode??

    POKECODE puts the data in the .hex file, and the programmer puts it in the chip while programming.
    It does not write to flash memory at run-time.

    So putting ERASECODE in your program would normally erase what was already programmed.

    But on the 16F877A, you cannot use ERASECODE because there is no FREE bit in EECON1.
    When writing to flash at run-time on this chip, it does an erase/write cycle much like EEPROM.
    There is no mechanism to erase blocks of FLASH memory.
    Most PIC chips do not work that way.

    So just lose the ERASECODE statement.
    And don't try to put all 500 values in the same POKECODE statement.
    Split them up into multiple POKECODEs.
    DT

  3. #3


    Did you find this post helpful? Yes | No

    Thumbs up Re: Limit of PokeCode??

    Thanks Darrel. I didn't knew about the EECON1 (Still don't, never came across dealing with it). I read a post by Melanie about PokeCode sometime ago, I tried searching it now but could not find it. There I remember reading about this ERASECODE, I guess I missed some part of it where this must have been explained.

    For now I have removed any ERASECODE statement, and divided the Pokecode into 2 statements (each with 250 values), and it compiles fine for now. Currently everything I am doing, I am simulating it on proteus, I hope when I burn this to PIC finally, all works fine.

    Thanks for your help.
    ___________________
    WHY things get boring when they work just fine?

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