views:

112

answers:

1

Hi

I am looking for a very memory-efficient (like max. 500 bytes of memory for lookup tables etc.) implementation of a Reed-Solomon encoder for use in an embedded application?

I am interested in coding blocks of 10 bytes with 5 bytes of parity. Speed is of little importance.

Do you know any freely available implementations that I can use for this purpose?

Thanks in advance.

+1  A: 

Starting here:

http://www.eccpage.com/rs.c

You can pre-compute alpha_to, index_of, and gg

For the case in the example program that is 16+16+7 ints (do they need to be ints or will bytes work?) or 156 bytes

That example has 9 ints of data and 6 ints of ecc or 15 total, if these are 4 byte ints that is another 60 bytes, 216 total.

Or 54 bytes if this could be done with bytes only. I seem to remember it works with bytes.

The encoder routine itself has a modulo but you can probably replace that with an and depending on your lengths. If your embedded processor has a divide then that is probably not going to hurt you anyway. Otherwise the encoder routine is quite simple. I am thinking that you may approach 500 bytes with the tables, data, and code.

I dont remember how to get from the 9 data and 6 ecc of the example to the 10 and 5 you are looking for. Hopefully the code in the link above will give you a head start to what you are looking for.

dwelch
Hi. Thanks for the input, this sounds like a possible solution. Precomputing the tables, as there is more than enough flash available. Yes, it works with bytes. In fact RS coding works with any alpahabet size.
bjarkef