Searching \ for 'Lookup Table' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/mems.htm?key=table
Search entire site for: 'Lookup Table'.

Truncated match.
PICList Thread
'lookup table'
1997\12\09@131323 by Aaron Hickman

picon face
PICLIST,

       Can anyone suggest a format for implementing a lookup table that can sto
re
scientific notation (ie. 3.2E-2)?  The lookup table involves some 30 values
or so, possibly exceeding the on board EEPROM of a PIC.  Should I use a
serial EEPROM to store this data?   Any suggestions, or even code fragments
will be greatly appreciated.

Sincerely,
Aaron Hickman



                \\\ | ///
               \\ - - //      "Yes it IS safe
           ( @ @ )         to switch on"
+---oOOo-(_)-oOOo------------------+

Aaron B. Hickman
Drexel University
Dept. of Chemistry
Phone (215)895-2645
Fax    (215)895-1980


'Lookup Table'
1999\08\06@103657 by Jim Mand
flavicon
face
We are having trouble implementing a lookup table for an AC motor speed
control.  I posted a message about six weeks ago and received a few
suggestions.  I attended a MChip seminar on another topic. While there I
picked the brain of one of the engineers.  We still can't get the code to
work.

Any suggestions will be greatly appreciated.

James Mand
Design Concepts, Inc
spam_OUTjamesmTakeThisOuTspamdesign-concepts.com

1999\08\09@021953 by Bjarne Nebelong

flavicon
face
Routine ; Do something
       movf    TabelEntry,w    ; Load W with the value for the table
       call    JumpTable
       movwf   TableResult     ; TableResult holds the LookUo Value

       return          ; Jump back

;------ Make sure that this part is in the beginning of memory
JumpTable
addwf   PCL,f   ; W:
       retlw   .0      ; 4
       retlw   .1      ; 5
       retlw   .2      ; 6

If W was 0, it returns 4
If W was 1, it returns 5
etc

HŠlsningar/ Regards,
Bjarne Nebelong
Manager Electrical Design
BINDOMATIC¨
.....bjarne.nebelongKILLspamspam@spam@bindomatic.se
+46-(0)8 709 58 46

                       -----Ursprungligt meddelande-----
                       FrŒn: Jim Mand [jamesmspamKILLspamDESIGN-CONCEPTS.COM]
                       Skickat:         den 6 augusti 1999 16:39
                       Till:   .....PICLISTKILLspamspam.....MITVMA.MIT.EDU
                       €mne: Lookup Table

                       We are having trouble implementing a lookup table
for an AC motor speed
                       control.  I posted a message about six weeks ago and
received a few
                       suggestions.  I attended a MChip seminar on another
topic. While there I
                       picked the brain of one of the engineers.  We still
can't get the code to
                       work.

                       Any suggestions will be greatly appreciated.

                       James Mand
                       Design Concepts, Inc
                       EraseMEjamesmspam_OUTspamTakeThisOuTdesign-concepts.com

1999\08\09@023829 by Dennis Plunkett

flavicon
face
Could you please post the code section that calls the table, the table
itself (Only a small part) and the memory map of where the table is and
where the calling part is.

Also have you tested this with MPLAB? What are the results
When you say it doesn't work by this what do you mean, does it post the
wrong result? or no result at all.
If there is no result does your code reset? Or do you get an indication
that the code jumps to the wrong location?

Most table problems are when the called table is in the next code segment
i.e. over 255bytes away and crossing a page boundary etc. If this is the
case then your code will be jumping but off to an unknown location on
return from the table.
If the table values are wrong then you may be out by one location, this is
a common error as PCL points to the next location before the add so a
simple NOP in the first table location will surfice (I have to jutt the
memory on that one, been a while so it may be wrong)

Hope that helps a bit
Dennis




At 08:11 9/08/99 +0200, you wrote:
{Quote hidden}

More... (looser matching)
- Last day of these posts
- In 1999 , 2000 only
- Today
- New search...