READCODE Instruction dont'work


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2011
    Posts
    20

    Unhappy READCODE Instruction dont'work

    Hello,

    Just a question on istruction that i have never used before today.

    I need to read a table of Words values stored in program space flash on my pic.
    So i need to user READCODE to retrieve data from a table of DW made in Assembly
    where i have stored a table of values.

    But when i try to compile a very simple program that use the istruction READCODE
    i will get back this errors:
    ---------------------------------------------------------------------------------
    PICBASIC PRO(TM) Compiler 2.60C, (c) 1998, 2011 microEngineering Labs, Inc.
    All Rights Reserved.
    ERROR: Unable to execute mpasmwin.Error[113] C:\PBP\PBPPIC14.LIB 449 : Symbol
    not previously defined (EEADRH)
    Error[113] C:\PBP\PBPPIC14.LIB 463 : Symbol not previously defined (EEADRH)
    Error[113] C:\PBP\PBPPIC14.LIB 477 : Symbol not previously defined (EEADRH)
    Error[113] C:\PBP\PBPPIC14.LIB 491 : Symbol not previously defined (EEADRH)
    Error[113] C:\PBP\PBPPIC14.LIB 899 : Symbol not previously defined (EEADRH)
    Error[113] C:\PBP\PBPPIC14.LIB 449 : Symbol not previously defined (EEDATH)
    Error[113] C:\PBP\PBPPIC14.LIB 463 : Symbol not previously defined (EEDATH)
    Error[113] C:\PBP\PBPPIC14.LIB 477 : Symbol not previously defined (EEDATH)
    Error[113] C:\PBP\PBPPIC14.LIB 491 : Symbol not previously defined (EEDATH)
    Error[113] C:\PBP\PBPPIC14.LIB 823 : Symbol not previously defined (EEDATH)
    ---------------------------------------------------------------------------------

    This is my very simple program just to test if READCODE work:


    ---------------------------------------------------------------------------------
    TRISA = %00100000 ' Set PORTA to all input
    TRISB = %00000000 ' Set PORTA to all input


    DEFINE OSC 4

    Char var WORD
    READCODE $100,Char
    ---------------------------------------------------------------------------------

    I use a 16f628A PIC for my project.
    But if i try to compile the same prog for a 16f88/16f887(just for example) all work fine and i don't get any errors.

    Have you any ideas about it
    Maybe the READCODE istruction don't work on all PIC models ?


    Thanks in advance,
    Gabriele

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


    Did you find this post helpful? Yes | No

    Default Re: READCODE Instruction dont'work

    Not all PIC chips have the ability to read and write to their own Flash memory.

    The 16F628A is one that cannot.

    You can use PEEKCODE/POKECODE or LOOKUP2.
    Or there's EEPROM (READ/WRITE/DATA).
    DT

  3. #3
    Join Date
    Sep 2011
    Posts
    20


    Did you find this post helpful? Yes | No

    Default Re: READCODE Instruction dont'work

    Thank Darrel to confirm me that READCODE don't work with 16f628A like i have supposed.
    So just a curiosity; which is more faster between use poke/peek and lookup2 ?

    PS:
    "I Blink, therefore i am"
    It too cool too true in pic's world! ROTFL

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