mirror of https://github.com/EspoTek/Labrador.git
Added a single #define
That's it. Literally a single #define that determines how many milliseconds the OS waits before reconnecting. Fixed an error with Windows not reading it on new mobo, hopefully fixes it under OS X as well.
This commit is contained in:
parent
8d0f6dbeeb
commit
d69bbf8e68
Binary file not shown.
|
@ -22,5 +22,7 @@ extern double SERIAL_DELAY;
|
|||
#define DEBUG_SETTINGSDOTSET
|
||||
#define COLUMN_BREAK 749
|
||||
|
||||
#define USB_RECONNECT_PERIOD 250
|
||||
|
||||
#endif // DESKTOP_SETTINGS_H
|
||||
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -6,8 +6,8 @@ unixUsbDriver::unixUsbDriver(QWidget *parent) : genericUsbDriver(parent)
|
|||
{
|
||||
unsigned char error = 1;
|
||||
while(error){
|
||||
QThread::msleep(USB_RECONNECT_PERIOD);
|
||||
error = usbInit(0x03eb, 0xa000);
|
||||
if(error)QThread::msleep(64);
|
||||
}
|
||||
setDeviceMode(deviceMode);
|
||||
newDig(digitalPinState);
|
||||
|
|
|
@ -5,7 +5,7 @@ winUsbDriver::winUsbDriver(QWidget *parent) : genericUsbDriver(parent)
|
|||
//This opens the USB connection. Nothing can continue until the board is up and running.
|
||||
bool connected = false;
|
||||
while(!connected){
|
||||
QThread::msleep(32);
|
||||
QThread::msleep(USB_RECONNECT_PERIOD);
|
||||
connected = usbInit(0x03eb, 0xa000);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue