On Friday, 24. September 2010 10:43:36 Thomas Jarosch wrote:
> For a FT245BM type chip, the eeprom->size will be 0x80.
> This results in
>
> i = 0x94;
> k = 127;
>
> "i++ & k" will result in 0x14. The length of the manufacturer string
> is stored in 0x0f, so this is wrong for the BM type chips. Luckily
> it will be overwritten later on.
>
> Can you enlighten me why the offset for the "length of the manufacturer
> string descriptor" is calculated dynamically? Atleast for the FT245BM and
> the FT2232C, it's always at 0x0F. Cut'n'paste typo?
Forget about it, it's the actual string length.
I still have trouble reading the code because of the "k" bitmask wraparound
magic. Maybe we find a better name for it, like "eeprom_size_limit"?
Thomas
--
libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx
|