Shop OBEX P1 Docs P2 Docs Learn Events
Stuck...Store command BS2P — Parallax Forums

Stuck...Store command BS2P

ArchiverArchiver Posts: 46,084
edited 2003-02-13 23:48 in General Discussion

Original Message
From: Eric Adams
To: basicstamps@yahoogroups.com
Sent: Tuesday, February 11, 2003 2:24 PM
Subject: Stuck...Store command BS2P


I am stuck and must be missing something. Let me explain.
I have a BS2P. I was using bank 0 and 1 for my program & data statements.
Bank 1 was only run at reset to initialize the connected PC's screen. Once It
was run the bit 1 of scratch pad ram was set to a 1 to prevent any additional
runs. The program worked fine but as any program feature creap entered I needed
more program room. I deceided to free up some 800 bytes of EEprom Data in both
banks 0 and 1 and move all the Data to bank 2. This would give me more room for
program space. I have moved the combined EEprom data from bank 0 and 1 into
bank 2. I have updated the indexes to the tables used in bank 0 & 1 to
correspond to the combined data (Now in Bank 2) and issued a STORE 2 command in
both bank 0 & 1 programs.

However now I am unable to access any of the data correctly. What am I
missing??? Any help or hints greatly appreciated



[noparse][[/noparse]Non-text portions of this message have been removed]

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2003-02-11 20:10
    >
    Original Message
    > From: Eric Adams
    > To: basicstamps@yahoogroups.com
    > Sent: Tuesday, February 11, 2003 2:24 PM
    > Subject: Stuck...Store command BS2P
    >
    >
    > I am stuck and must be missing something. Let me explain.
    > I have a BS2P. I was using bank 0 and 1 for my program & data
    >statements. Bank 1 was only run at reset to initialize the
    >connected PC's screen. Once It was run the bit 1 of scratch pad ram
    >was set to a 1 to prevent any additional runs. The program worked
    >fine but as any program feature creap entered I needed more program
    >room. I deceided to free up some 800 bytes of EEprom Data in both
    >banks 0 and 1 and move all the Data to bank 2. This would give me
    >more room for program space. I have moved the combined EEprom data
    >from bank 0 and 1 into bank 2. I have updated the indexes to the
    >tables used in bank 0 & 1 to correspond to the combined data (Now in
    >Bank 2) and issued a STORE 2 command in both bank 0 & 1 programs.
    >
    > However now I am unable to access any of the data correctly. What
    >am I missing??? Any help or hints greatly appreciated


    Write yourself a short program to verify operation. You know, you
    have execute the STORE 2 command every time you change banks, not
    just once?

    'bank 0
    ix var byte
    store 2
    write 0,ix
    run 1

    'bank 1
    ix var byte
    store 2
    read 0,ix
    debug ?ix
    ix=ix+1
    pause 1000
    run 0

    -- Tracy
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-12 01:37
    Hi Tracy & fellow stampers

    Tracy your little program works as did the Parallax examples which I tried
    earlier before I went into this data rearrangement. I thought I understood
    the STORE when reading the manual. However my rearrangement of all of the
    DATA statements from modules 0 & 1 and putting them into module 2 all by
    themself still does not work. The store command says it affects Read &
    Write statements. Question does the data have to be previously written by
    the program in slot 0 or 1 for the store2 to work. What I am trying to say
    is my data is just DATA statements not written by write instructions in
    modules 0 and 1 Is there some pointer that gets updated when a write is done
    verses just plopping the data into a module?

    As I mentioned before I am using the exact data statements as I used in
    modules 0 & 1 just relocating them to module 2 and adding the Store 2
    command so the reads can go to module 2. Any ideas ??




    Original Message
    From: "Tracy Allen" <tracy@e...>
    To: <basicstamps@yahoogroups.com>
    Sent: Tuesday, February 11, 2003 3:10 PM
    Subject: Re: [noparse][[/noparse]basicstamps] Stuck...Store command BS2P


    > >
    Original Message
    > > From: Eric Adams
    > > To: basicstamps@yahoogroups.com
    > > Sent: Tuesday, February 11, 2003 2:24 PM
    > > Subject: Stuck...Store command BS2P
    > >
    > >
    > > I am stuck and must be missing something. Let me explain.
    > > I have a BS2P. I was using bank 0 and 1 for my program & data
    > >statements. Bank 1 was only run at reset to initialize the
    > >connected PC's screen. Once It was run the bit 1 of scratch pad ram
    > >was set to a 1 to prevent any additional runs. The program worked
    > >fine but as any program feature creap entered I needed more program
    > >room. I deceided to free up some 800 bytes of EEprom Data in both
    > >banks 0 and 1 and move all the Data to bank 2. This would give me
    > >more room for program space. I have moved the combined EEprom data
    > >from bank 0 and 1 into bank 2. I have updated the indexes to the
    > >tables used in bank 0 & 1 to correspond to the combined data (Now in
    > >Bank 2) and issued a STORE 2 command in both bank 0 & 1 programs.
    > >
    > > However now I am unable to access any of the data correctly. What
    > >am I missing??? Any help or hints greatly appreciated
    >
    >
    > Write yourself a short program to verify operation. You know, you
    > have execute the STORE 2 command every time you change banks, not
    > just once?
    >
    > 'bank 0
    > ix var byte
    > store 2
    > write 0,ix
    > run 1
    >
    > 'bank 1
    > ix var byte
    > store 2
    > read 0,ix
    > debug ?ix
    > ix=ix+1
    > pause 1000
    > run 0
    >
    > -- Tracy
    >
    >
    > To UNSUBSCRIBE, just send mail to:
    > basicstamps-unsubscribe@yahoogroups.com
    > from the same email address that you subscribed. Text in the Subject and
    Body of the message will be ignored.
    >
    >
    > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-12 02:28
    Hi Again:

    I gave the program a few write commands using the existing data in
    locations 0-3 after the STORE 2 and then I was able to read the rest of the
    data in module 2. Can't figure it out but it worked.

    Thanks all

    Original Message
    From: "Eric Adams" <hugs102@b...>
    To: <basicstamps@yahoogroups.com>
    Sent: Tuesday, February 11, 2003 8:37 PM
    Subject: Re: [noparse][[/noparse]basicstamps] Stuck...Store command BS2P


    > Hi Tracy & fellow stampers
    >
    > Tracy your little program works as did the Parallax examples which I tried
    > earlier before I went into this data rearrangement. I thought I
    understood
    > the STORE when reading the manual. However my rearrangement of all of the
    > DATA statements from modules 0 & 1 and putting them into module 2 all by
    > themself still does not work. The store command says it affects Read &
    > Write statements. Question does the data have to be previously written by
    > the program in slot 0 or 1 for the store2 to work. What I am trying to
    say
    > is my data is just DATA statements not written by write instructions in
    > modules 0 and 1 Is there some pointer that gets updated when a write is
    done
    > verses just plopping the data into a module?
    >
    > As I mentioned before I am using the exact data statements as I used in
    > modules 0 & 1 just relocating them to module 2 and adding the Store 2
    > command so the reads can go to module 2. Any ideas ??
    >
    >
    >
    >
    >
    Original Message
    > From: "Tracy Allen" <tracy@e...>
    > To: <basicstamps@yahoogroups.com>
    > Sent: Tuesday, February 11, 2003 3:10 PM
    > Subject: Re: [noparse][[/noparse]basicstamps] Stuck...Store command BS2P
    >
    >
    > > >
    Original Message
    > > > From: Eric Adams
    > > > To: basicstamps@yahoogroups.com
    > > > Sent: Tuesday, February 11, 2003 2:24 PM
    > > > Subject: Stuck...Store command BS2P
    > > >
    > > >
    > > > I am stuck and must be missing something. Let me explain.
    > > > I have a BS2P. I was using bank 0 and 1 for my program & data
    > > >statements. Bank 1 was only run at reset to initialize the
    > > >connected PC's screen. Once It was run the bit 1 of scratch pad ram
    > > >was set to a 1 to prevent any additional runs. The program worked
    > > >fine but as any program feature creap entered I needed more program
    > > >room. I deceided to free up some 800 bytes of EEprom Data in both
    > > >banks 0 and 1 and move all the Data to bank 2. This would give me
    > > >more room for program space. I have moved the combined EEprom data
    > > >from bank 0 and 1 into bank 2. I have updated the indexes to the
    > > >tables used in bank 0 & 1 to correspond to the combined data (Now in
    > > >Bank 2) and issued a STORE 2 command in both bank 0 & 1 programs.
    > > >
    > > > However now I am unable to access any of the data correctly. What
    > > >am I missing??? Any help or hints greatly appreciated
    > >
    > >
    > > Write yourself a short program to verify operation. You know, you
    > > have execute the STORE 2 command every time you change banks, not
    > > just once?
    > >
    > > 'bank 0
    > > ix var byte
    > > store 2
    > > write 0,ix
    > > run 1
    > >
    > > 'bank 1
    > > ix var byte
    > > store 2
    > > read 0,ix
    > > debug ?ix
    > > ix=ix+1
    > > pause 1000
    > > run 0
    > >
    > > -- Tracy
    > >
    > >
    > > To UNSUBSCRIBE, just send mail to:
    > > basicstamps-unsubscribe@yahoogroups.com
    > > from the same email address that you subscribed. Text in the Subject
    and
    > Body of the message will be ignored.
    > >
    > >
    > > Your use of Yahoo! Groups is subject to
    http://docs.yahoo.com/info/terms/
    > >
    > >
    > >
    >
    >
    > To UNSUBSCRIBE, just send mail to:
    > basicstamps-unsubscribe@yahoogroups.com
    > from the same email address that you subscribed. Text in the Subject and
    Body of the message will be ignored.
    >
    >
    > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-12 02:33
    >Hi Tracy & fellow stampers
    >
    >Tracy your little program works as did the Parallax examples which I tried
    >earlier before I went into this data rearrangement. I thought I understood
    >the STORE when reading the manual. However my rearrangement of all of the
    >DATA statements from modules 0 & 1 and putting them into module 2 all by
    >themself still does not work. The store command says it affects Read &
    >Write statements. Question does the data have to be previously written by
    >the program in slot 0 or 1 for the store2 to work. What I am trying to say
    >is my data is just DATA statements not written by write instructions in
    >modules 0 and 1 Is there some pointer that gets updated when a write is done
    >verses just plopping the data into a module?
    >
    >As I mentioned before I am using the exact data statements as I used in
    >modules 0 & 1 just relocating them to module 2 and adding the Store 2
    >command so the reads can go to module 2. Any ideas ??


    Can you show us a short example program, that does not work the way you expect?

    If you install DATA in bank 2, you should be able to READ it from
    banks 0 or 1. Are you sure your bank 2 is declared as part of your
    project?!

    Example:

    '{$stamp BS2p, eek1.bsp, eek2.bsp} <--- declare?
    'bank 0, eek0.bsp
    ix var nib ' 16 byte pointer
    char var byte
    store 2
    read ix,char
    debug char
    ix=ix+1
    run 1
    'bank 1, eek1.bsp
    ix var byte
    char var byte
    store 2
    read ix,char
    debug char
    ix=ix+1
    run 0
    'bank 2, eek2.bsp
    data "testing 1, 2, 3",cr ' 16 chars


    -- Tracy
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-13 20:06
    Hi Tracy:

    I have tried to duplicate the problem several ways with no luck. I think it
    may have been a typo in the Declare statement which probably caused this.
    It however looked like the Write statements cleared it but it probably was
    me inputting your little program forcing me to reload my original program.
    In either case it is fixed and I am indebted to you (again)

    Thanks
    Eric

    Original Message
    From: "Tracy Allen" <tracy@e...>
    To: <basicstamps@yahoogroups.com>
    Sent: Tuesday, February 11, 2003 9:33 PM
    Subject: Re: [noparse][[/noparse]basicstamps] Stuck...Store command BS2P


    > >Hi Tracy & fellow stampers
    > >
    > >Tracy your little program works as did the Parallax examples which I
    tried
    > >earlier before I went into this data rearrangement. I thought I
    understood
    > >the STORE when reading the manual. However my rearrangement of all of
    the
    > >DATA statements from modules 0 & 1 and putting them into module 2 all by
    > >themself still does not work. The store command says it affects Read &
    > >Write statements. Question does the data have to be previously written
    by
    > >the program in slot 0 or 1 for the store2 to work. What I am trying to
    say
    > >is my data is just DATA statements not written by write instructions in
    > >modules 0 and 1 Is there some pointer that gets updated when a write is
    done
    > >verses just plopping the data into a module?
    > >
    > >As I mentioned before I am using the exact data statements as I used in
    > >modules 0 & 1 just relocating them to module 2 and adding the Store 2
    > >command so the reads can go to module 2. Any ideas ??
    >
    >
    > Can you show us a short example program, that does not work the way you
    expect?
    >
    > If you install DATA in bank 2, you should be able to READ it from
    > banks 0 or 1. Are you sure your bank 2 is declared as part of your
    > project?!
    >
    > Example:
    >
    > '{$stamp BS2p, eek1.bsp, eek2.bsp} <--- declare?
    > 'bank 0, eek0.bsp
    > ix var nib ' 16 byte pointer
    > char var byte
    > store 2
    > read ix,char
    > debug char
    > ix=ix+1
    > run 1
    >
    > 'bank 1, eek1.bsp
    > ix var byte
    > char var byte
    > store 2
    > read ix,char
    > debug char
    > ix=ix+1
    > run 0
    >
    > 'bank 2, eek2.bsp
    > data "testing 1, 2, 3",cr ' 16 chars
    >
    >
    > -- Tracy
    >
    > To UNSUBSCRIBE, just send mail to:
    > basicstamps-unsubscribe@yahoogroups.com
    > from the same email address that you subscribed. Text in the Subject and
    Body of the message will be ignored.
    >
    >
    > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2003-02-13 23:48
    >Hi Tracy
    >In either case it is fixed and I am indebted to you (again

    Who on this list isn't

    Larry Gaminde


    Original Message
    From: "Eric Adams" <hugs102@b...>
    To: <basicstamps@yahoogroups.com>
    Sent: February 13, 2003 12:06 PM
    Subject: Re: [noparse][[/noparse]basicstamps] Stuck...Store command BS2P


    : Hi Tracy:
    :
    : I have tried to duplicate the problem several ways with no luck. I
    think it
    : may have been a typo in the Declare statement which probably caused
    this.
    : It however looked like the Write statements cleared it but it
    probably was
    : me inputting your little program forcing me to reload my original
    program.
    : In either case it is fixed and I am indebted to you (again)
    :
    : Thanks
    : Eric
    :
    :
    Original Message
    : From: "Tracy Allen" <tracy@e...>
    : To: <basicstamps@yahoogroups.com>
    : Sent: Tuesday, February 11, 2003 9:33 PM
    : Subject: Re: [noparse][[/noparse]basicstamps] Stuck...Store command BS2P
    :
    :
    : > >Hi Tracy & fellow stampers
    : > >
    : > >Tracy your little program works as did the Parallax examples
    which I
    : tried
    : > >earlier before I went into this data rearrangement. I thought I
    : understood
    : > >the STORE when reading the manual. However my rearrangement of
    all of
    : the
    : > >DATA statements from modules 0 & 1 and putting them into module 2
    all by
    : > >themself still does not work. The store command says it affects
    Read &
    : > >Write statements. Question does the data have to be previously
    written
    : by
    : > >the program in slot 0 or 1 for the store2 to work. What I am
    trying to
    : say
    : > >is my data is just DATA statements not written by write
    instructions in
    : > >modules 0 and 1 Is there some pointer that gets updated when a
    write is
    : done
    : > >verses just plopping the data into a module?
    : > >
    : > >As I mentioned before I am using the exact data statements as I
    used in
    : > >modules 0 & 1 just relocating them to module 2 and adding the
    Store 2
    : > >command so the reads can go to module 2. Any ideas ??
    : >
    : >
    : > Can you show us a short example program, that does not work the
    way you
    : expect?
    : >
    : > If you install DATA in bank 2, you should be able to READ it from
    : > banks 0 or 1. Are you sure your bank 2 is declared as part of
    your
    : > project?!
    : >
    : > Example:
    : >
    : > '{$stamp BS2p, eek1.bsp, eek2.bsp} <--- declare?
    : > 'bank 0, eek0.bsp
    : > ix var nib ' 16 byte pointer
    : > char var byte
    : > store 2
    : > read ix,char
    : > debug char
    : > ix=ix+1
    : > run 1
    : >
    : > 'bank 1, eek1.bsp
    : > ix var byte
    : > char var byte
    : > store 2
    : > read ix,char
    : > debug char
    : > ix=ix+1
    : > run 0
    : >
    : > 'bank 2, eek2.bsp
    : > data "testing 1, 2, 3",cr ' 16 chars
    : >
    : >
    : > -- Tracy
    : >
    : > To UNSUBSCRIBE, just send mail to:
    : > basicstamps-unsubscribe@yahoogroups.com
    : > from the same email address that you subscribed. Text in the
    Subject and
    : Body of the message will be ignored.
    : >
    : >
    : > Your use of Yahoo! Groups is subject to
    http://docs.yahoo.com/info/terms/
    : >
    : >
    :
    :
    : To UNSUBSCRIBE, just send mail to:
    : basicstamps-unsubscribe@yahoogroups.com
    : from the same email address that you subscribed. Text in the
    Subject and Body of the message will be ignored.
    :
    :
    : Your use of Yahoo! Groups is subject to
    http://docs.yahoo.com/info/terms/
    :
    :
Sign In or Register to comment.