fixed EEPROM user-area space checks for FT232R and FT245R chips in ftdi_eeprom_build()
authorRobin Haberkorn <haberkorn@metratec.com>
Fri, 23 Jan 2015 10:37:14 +0000 (11:37 +0100)
committerThomas Jarosch <thomas.jarosch@intra2net.com>
Fri, 23 Jan 2015 10:37:14 +0000 (11:37 +0100)
According to FTDI Application Note 121 ("Accessing the EEPROM User Area Of FTDI
Devices"), the FT232R and FT245R chips have a total 48 words (96 bytes) of
user area space available for descriptive strings.

[Note from Thomas Jarosch: That has also been verified with "FT Prog" by Robin]

src/ftdi.c

index 47e6959..ea487d0 100644 (file)
@@ -2604,6 +2604,8 @@ int ftdi_eeprom_build(struct ftdi_context *ftdi)
             user_area_size = 90;     // two extra config bytes and 4 bytes PnP stuff
             break;
         case TYPE_R:
+            user_area_size = 96;
+            break;
         case TYPE_230X:
             user_area_size = 88;     // four extra config bytes + 4 bytes PnP stuff
             break;