FreeCalypso > hg > fc-usbser-tools
changeset 41:940cde8a99b6
fteeprom-prog: we don't need to claim the interface
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sun, 10 Sep 2023 21:22:20 +0000 |
parents | f5847be43d35 |
children | 2746b160afb7 |
files | fteeprom/fteeprom-prog.c |
diffstat | 1 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/fteeprom/fteeprom-prog.c Sun Sep 10 21:13:58 2023 +0000 +++ b/fteeprom/fteeprom-prog.c Sun Sep 10 21:22:20 2023 +0000 @@ -114,11 +114,15 @@ fprintf(stderr, "error: specified USB device not found\n"); exit(1); } - usbh = usbwrap_open_dev(dev, 1); + usbh = usb_open(dev); + if (!usbh) { + fprintf(stderr, "error: usb_open() failed\n"); + exit(1); + } if (ft232r_mode) ft232r_eeprom_magic(usbh); for (n = 0; n < eeprom_size; n++) ftmini_write_eeprom_loc(usbh, n, eeprom[n]); - usbwrap_close_dev(usbh); + usb_close(usbh); exit(0); }