libftdi Archives

Subject: Re: How to query the device serial number of an already opened connection

From: Ryan Tennill <rtennill@xxxxxxxxxxxxxxxx>
To: libftdi@xxxxxxxxxxxxxxxxxxxxxxx
Date: Mon, 19 Oct 2015 11:40:05 -0500
I believe what you're looking for is provided by ftdi_usb_get_strings() with the caveat that it closes the device after use.

http://www.intra2net.com/en/developer/libftdi/documentation/group__libftdi.html#ga17e8eae09e58bd3bfeeab8decfce7fd9

Ryan

On 10/18/2015 10:36 AM, Alex Scarbro wrote:
Hello,

I'm working on an improved LCDproc HD44780 driver using the FTDI FT2232D to add keypad support.

I have both interfaces working perfectly, but would like to tell the user what the serial number is of the interface that has been opened.

Is it possible to query the serial number of an interface that has already been opened?

e.g.

    /* open LCD channel*/
    ftdi_init(&p->ftdic);
    ftdi_set_interface(&p->ftdic, INTERFACE_A);
    ftdi_usb_open(&p->ftdic, ftdiVendorIdLcd, ftdiProductIdLcd);

    <QUERY OPENED SERIAL NUMBER HERE>

    printf("Opened device serial number is: %s",serilaNo);
    ftdi_deinit(&p->ftdic);

Best regards,

Alex


libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx



-- 

217-351-2655 ext. 126
Distant Focus Corporation
4114B Fieldstone Rd
Champaign, IL 61822
http://jupiter.distantfocus.com/projects/


libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx


Current Thread