POOKECODE and PEEKCODE


Closed Thread
Results 1 to 15 of 15

Hybrid View

  1. #1
    Join Date
    Apr 2008
    Posts
    85


    Did you find this post helpful? Yes | No

    Default

    hello ALain,

    youa re right.

    the variable does nothing on the POKECODeE. after refresh my mind i relize taht. misunderstanding the address

    thanks again for your help

    regards,

    the address

  2. #2
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,648


    Did you find this post helpful? Yes | No

    Lightbulb

    Hi, Minhle

    May be you might try the WRITECODE Command

    a good night somtimes Helps ... to understand what is looked for. LOL

    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  3. #3
    Join Date
    Apr 2008
    Posts
    85


    Did you find this post helpful? Yes | No

    Default

    Hello Alain,
    thanks, both EEPROM and DATA, WRITE and READ are work well

    regards,

  4. #4
    Join Date
    Apr 2008
    Posts
    85


    Did you find this post helpful? Yes | No

    Default pokcode redo

    hi ,can someone help to see where is problemes are
    the output is only the first byte of data stored in a table
    pic16f877A

    ADCON0 = 0
    ADCON1 = 7
    define osc 20

    trisB = 0 ' SET PORTB AS OUTPUT
    PORTB = 0 ; SET PORTB t and C to 0
    trisc = 0
    portc = 0

    trisd = 0 ; 2 pins of this port is for reset and clock


    erasecode $500 ; erase code space @$500 (page 0)

    B0 var word
    StrAddr var word
    F0 var byte
    E0 var byte
    k var byte
    LOOP ; this loop display the value stored in the flash
    b0 = 0 ; initial value
    FOR StrAddr = 500 to 505 step 2 ; read a word
    call display
    NEXT StrAddr
    goto loop
    '--------------------

    DISPLAY:
    Peekcode StrAddr, b0 ; fetch a value from table
    f0 = b0.lowbyte
    e0 = b0.highbyte
    call output1
    return

    '-----------
    output1:
    for k = 0 to 30 ; output 2 ports of B and C
    call reset
    portb = f0
    portc = e0
    call delay
    next k
    return

    '-------------------------------------------------------
    RESET: PORTd.2 = 1 ;RESET 4017 pin 16-PIC
    @NOP
    PORTd.2 = 0
    RETURN
    '-----------------------------------------------------------
    DELAY:
    pause 1 ;
    portb = 0 ; reset portb , c
    portc = 0
    portd.3 = 1 ; clock the 4017 pin17-PIC
    @nop
    portd.3 = 0

    return
    end


    pokecode @$500, $2a,$55 ,$55, $2a ,$55 ,$2a ; store data in flash mem

    thnaks for all reply,

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