Page 1 of 1

Lookup table resizing.

Posted: Thu Mar 21, 2024 9:16 pm
by mnfisher
I hit a small issue resizing a lookup table (in an Arduino sketch - though this might not be relevant)

I created an 8 bit lookup table and pasted in 4637 values - this was correctly reflected in the num values field.

However - to create a simpler 'demo' version of my program I then replaced these values by pasting in 19 values - now NumValues shows 1 (and lut1::GetNumValues() returns 1) (the values were the first 19 of the larger data set)

Typing some values - say 1 2 3 4 5 6 also has NumValues as 1.

Replacing the original data - restores NumValues to 4637.

Martin

Re: Lookup table resizing.

Posted: Thu Mar 21, 2024 9:48 pm
by kersing
An 8 bit lookup table with >256 values?? Does that make sense?

Re: Lookup table resizing.

Posted: Fri Mar 22, 2024 5:42 am
by mnfisher
Yes - a table of 8 bit values.
Not sure if size is limited but the initial size shows correctly and in simulation (which is all that is needed here) seems to work correctly (although I didn't single step through it all - and the simulation locked when I altered the rate slider)

Martin

Re: Lookup table resizing.

Posted: Fri Mar 22, 2024 10:22 am
by BenR
Hello,

I think to work out the number of values it counts commas. Spaces won't currently work but we could maybe add that to the parse script so that it converts spaces into commas.

Re: Lookup table resizing.

Posted: Fri Mar 22, 2024 10:48 am
by mnfisher
Ok - I'll replace the spaces with commas - odd that it works for the original data block - which also uses spaces....