This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

LOOKUP TABLES

I need to know about what a lookup table exactly is. I'm studying the 8051 uC, I am following the book "The 8051 Microcontroller, by I. Scott MacKenzie". There's nothing much mentioned about lookup tables, only a tiny one-paragraph section. It's not clear to me what a lookup table is and why is it required.

Basically I need to know the following:
•what a lookup table is
•how to create a lookup table
•accessing a lookup table
•how is it stored in memory

Help would be much appreciated. Thank you :)

  • A lookup table is a general software/hardware concept, so a book about a specific processor or a specific programming language doesn't have much reason to describe the concept.

    A lookup table is a one-dimensional or multi-dimensional array/vector where you use one or more index/indices into the table to lookup a new value.

    So you might take the ID of an article as index and lookup the price of the article. Or a board game might have different pieces, where the lookup table contains the name - or position - of the individual pieces. Or the x,y position might be used to lookup if a piece is already at that location.

  • ab example from my wlork last week

    I read a thermistlor which is very non-linear

    I have a table{100][2]
    which hen contain
    R@100
    R@99
    R@98
    ...

    then I start with table[index] and go up or down till I have > and <, then 'index' will be the hemp

  • Erik,

    I do wish you'd consider using some of your undoubted huge income to invest in a new keyboard. It would make your useful posts far more readable.