X-Git-Url: http://developer.intra2net.com/git/?p=libftdi;a=blobdiff_plain;f=src%2Fftdi.h;h=4e3880ee74405e9ed589e5297aca66c7034cbb9d;hp=c0a3d3db3c9c6a6c17ce98d612b2e96bd0d9bb75;hb=b9c1e31765740e24a34112a3df58e95646b2316b;hpb=7a172cafefbfccdc0f93916947bac74c758ae1d6 diff --git a/src/ftdi.h b/src/ftdi.h index c0a3d3d..4e3880e 100644 --- a/src/ftdi.h +++ b/src/ftdi.h @@ -200,6 +200,10 @@ struct ftdi_eeprom int vendor_id; /** product id */ int product_id; + + /** Was the eeprom structure initialized for the actual + connected device? **/ + int initialized_for_connected_device; /** self powered */ int self_powered; @@ -245,7 +249,7 @@ struct ftdi_eeprom /* Special function of FT232R/FT232H devices (and possibly others as well) */ /** CBUS pin function. See CBUS_xxx defines. */ - int cbus_function[9]; + int cbus_function[10]; /** Select hight current drive on R devices. */ int high_current; /** Select hight current drive on A channel (2232C */ @@ -448,10 +452,10 @@ enum ftdi_cbush_func {/* FIXME: Recheck value, especially the last */ /** Interface Mode. */ #define CHANNEL_IS_UART 0x0 -#define CHANNEL_IS_245 0x1 -#define CHANNEL_IS_CPU 0x2 -#define CHANNEL_IS_OPTO 0x3 -#define CHANNEL_IS_FT1284 0x4 +#define CHANNEL_IS_FIFO 0x1 +#define CHANNEL_IS_OPTO 0x2 +#define CHANNEL_IS_CPU 0x4 +#define CHANNEL_IS_FT1284 0x8 #define DRIVE_4MA 0 #define DRIVE_8MA 1 @@ -584,6 +588,7 @@ extern "C" int ftdi_set_eeprom_value(struct ftdi_context *ftdi, enum ftdi_eeprom_value value_name, int value); int ftdi_get_eeprom_buf(struct ftdi_context *ftdi, unsigned char * buf, int size); + int ftdi_set_eeprom_buf(struct ftdi_context *ftdi, const unsigned char * buf, int size); int ftdi_read_eeprom(struct ftdi_context *ftdi); int ftdi_read_chipid(struct ftdi_context *ftdi, unsigned int *chipid);