mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-28 15:18:38 -05:00
Some clean up of IQ+ frequency control
IQ+ users on MS Windows should update the driver, the PE0FKO libusb-w32 driver is obsolete and not compatible with the latest libusb user mode library we are using for control of this device. By far the easiest way to upgrade, without loosing compatibility with applications using older vendor USB drivers, is to download the Zadig tool from https://zadig.akeo.ie/, run the tool, scan for all appropriate USB devices (check the "Menu->Options->List All Devices" option), select the device called DG8SAQ from the top drop-down list, then with WinUSB listed as the replacement driver to right of the green arrow, double-click the "Replace libusb-w32" button. After a few seconds the driver will be replace, quit the utility and you are done.
This commit is contained in:
parent
71b9ec921b
commit
028b217df3
@ -44,7 +44,6 @@ double delay_average;
|
||||
int from_freq;
|
||||
int to_freq;
|
||||
int increment_freq;
|
||||
int retval = -1;
|
||||
int display_freq = -1;
|
||||
int delay;
|
||||
static libusb_device_handle * global_si570usb_handle;
|
||||
@ -84,21 +83,23 @@ int set570(double freq_MHz)
|
||||
// if(freq_MHz != 999.0) return 0;
|
||||
//###
|
||||
|
||||
char * my_usbSerialID = NULL;
|
||||
char * my_usbSerialID = nullptr;
|
||||
|
||||
// MAIN MENU DIALOG
|
||||
retval=Si570usbOpenDevice(&global_si570usb_handle, my_usbSerialID);
|
||||
if (retval != 0) return -1;
|
||||
if (Si570usbOpenDevice(&global_si570usb_handle, my_usbSerialID) != USB_SUCCESS)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
//SET FREQUENCY
|
||||
if((freq_MHz < 3.45)|(freq_MHz > 866.0)) return -2;
|
||||
retval=setFreqByValue(global_si570usb_handle,freq_MHz);
|
||||
setFreqByValue(global_si570usb_handle,freq_MHz);
|
||||
return 0;
|
||||
}
|
||||
|
||||
unsigned char Si570usbOpenDevice (libusb_device_handle * * udh, char * usbSerialID)
|
||||
{
|
||||
// if (*udh) return USB_SUCCESS; // only scan USB devices 1st time
|
||||
if (*udh) return USB_SUCCESS; // only scan USB devices 1st time
|
||||
|
||||
int vendor = USBDEV_SHARED_VENDOR;
|
||||
char *vendorName = (char *)VENDOR_NAME;
|
||||
@ -130,7 +131,7 @@ unsigned char Si570usbOpenDevice (libusb_device_handle * * udh, char * usbSerial
|
||||
libusb_device_descriptor descriptor;
|
||||
if ((rc = libusb_get_device_descriptor (device, &descriptor)) < 0)
|
||||
{
|
||||
printf ("usb get devive descriptor error message %s\n", libusb_error_name (rc));
|
||||
printf ("usb get device descriptor error message %s\n", libusb_error_name (rc));
|
||||
errorCode = USB_ERROR_ACCESS;
|
||||
continue;
|
||||
}
|
||||
@ -139,7 +140,7 @@ unsigned char Si570usbOpenDevice (libusb_device_handle * * udh, char * usbSerial
|
||||
// now we must open the device to query strings
|
||||
if ((rc = libusb_open (device, &handle)) < 0)
|
||||
{
|
||||
printf ("usb open device descriptor error message %s\n", libusb_error_name (rc));
|
||||
printf ("usb open device error message %s\n", libusb_error_name (rc));
|
||||
errorCode = USB_ERROR_ACCESS;
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user