[PicForth] Re: Fixed jtable
David P Harris
dpharris at telus.net
Tue Nov 9 09:59:25 CET 2004
Do you not want a more general table? PICLIST has some code for this:
http://www.piclist.com/techref/microchip/tables.htm
David (Harris)
Samuel Tardieu wrote:
>>>>>>"David" == David McNab <david at rebirthing.co.nz> writes:
>>>>>>
>>>>>>
>
>David> As a side note - it would appear that the standard 'ftable'
>David> (from which I ripped code for jtable) also suffers from this
>David> limitation. Might be worth looking at having 'ftable' also
>David> adjust PCLATH.
>
>After looking at the code, I do not think this is needed. Such tables
>are always fully included in only one page (end-ftable checks
>that). It is composed of:
>
>TABLE:
> ADDWF PCL,F
> RETLW CHOICE0
> RETLW CHOICE1
> ...
>
>It means that to be able to call TABLE, one needs to have the PCLATH
>set to this page already. The situation in your jump tables is
>different, because you call other words from there, which is not the
>case in data tables.
>
> Sam
>
>
More information about the PicForth
mailing list