Shop OBEX P1 Docs P2 Docs Learn Events
Creating a Table of values — Parallax Forums

Creating a Table of values

ArchiverArchiver Posts: 46,084
edited 2002-04-13 10:49 in General Discussion
Please pardon the newbie, but what is the easiest way to store a look
up table on the BS2p?

Thanks,
Nevin

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2002-04-13 05:05
    Use the DATA statement to create your table(s), then READ to access the data.

    -- Jon Williams
    -- Parallax


    In a message dated 4/12/02 1:47:21 PM Central Daylight Time,
    nevinlaura@y... writes:


    > Please pardon the newbie, but what is the easiest way to store a look
    > up table on the BS2p?
    >




    [noparse][[/noparse]Non-text portions of this message have been removed]
  • ArchiverArchiver Posts: 46,084
    edited 2002-04-13 10:49
    Write the values to EEPROM.

    Example:

    Data "A","B","C","D","E"

    Will place those characters in eeprom addresses 0 to 4

    Then, just us the READ command to get the value

    Example

    READ 3, CHARACTER

    will read address 3 and place that data in the variable "CHARACTER"


    Cheers,

    Ben, Wellington, New Zealand.

    --
    http://www.lennard.net.nz/
    Ben Lennard, NCEE, Dip EE

    Web Hosting and Electronics R&D
    Club Coordinator, Victoria University of Wellington Hockey Club

    Hm: +64 4 972 7567
    Mb: +64 21 536 627
    87 Spencer Street
    Crofton Downs
    Wellington
    New Zealand

    "To the optimist, the glass is half full. To the pessimist, the glass is
    half empty. To the engineer, the glass is twice as big as it needs to be."

    No animals were harmed in the transmission of this email, although the
    Dog next door is living on borrowed time, let me tell you! Those of you
    with an overwhelming fear of the unknown will be gratified to learn that
    there is no hidden message revealed by reading this warning backwards.




    >From: "nevinlaura" <nevinlaura@y...>
    >To: basicstamps@yahoogroups.com
    >Subject: [noparse][[/noparse]basicstamps] Creating a Table of values
    >Date: Sat, 13 Apr 2002 5:42 AM
    >

    > Please pardon the newbie, but what is the easiest way to store a look
    > up table on the BS2p?
    >
    > Thanks,
    > Nevin
    >
    >
    > 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.