Fix sleep duration (Milliseconds -> Microseconds)

This commit is contained in:
Maschell 2018-06-19 17:31:20 +02:00
parent 07314ec15b
commit ec2e5dd8e3
3 changed files with 3 additions and 3 deletions

View File

@ -86,7 +86,7 @@ bool CPTCPServer::whileLoop() {
if(wiiu_errno != 6) { if(wiiu_errno != 6) {
return false; return false;
} }
OSSleepTicks(OSMillisecondsToTicks(1000)); OSSleepTicks(OSMicrosecondsToTicks(1000));
continue; continue;
} }
//DEBUG_FUNCTION_LINE("got byte from tcp! %01X\n",ret); //DEBUG_FUNCTION_LINE("got byte from tcp! %01X\n",ret);

View File

@ -104,7 +104,7 @@ void UDPServer::DoUDPThreadInternal(){
n = recv(sockfd,buffer,MAX_UDP_SIZE,0); n = recv(sockfd,buffer,MAX_UDP_SIZE,0);
if (n < 0){ if (n < 0){
s32 errno_ = wiiu_errno; s32 errno_ = wiiu_errno;
OSSleepTicks(OSMillisecondsToTicks(2000)); OSSleepTicks(OSMicrosecondsToTicks(2000));
if(errno_ != 11 && errno_ != 9){ if(errno_ != 11 && errno_ != 9){
break; break;
} }

View File

@ -99,7 +99,7 @@ void ControllerPatcherHID::myHIDReadCallback(u32 handle, s32 error, unsigned cha
HIDReadCallback(handle,buf,bytes_transfered,usr); HIDReadCallback(handle,buf,bytes_transfered,usr);
if(usr->slotdata.hidmask == gHID_LIST_DS4){ if(usr->slotdata.hidmask == gHID_LIST_DS4){
OSSleepTicks(OSMillisecondsToTicks(2000)); //DS4 is way tooo fast. sleeping to reduce lag. (need to check the other pads) OSSleepTicks(OSMicrosecondsToTicks(2000)); //DS4 is way tooo fast. sleeping to reduce lag. (need to check the other pads)
} }
HIDRead(handle, usr->buf, bytes_transfered, myHIDReadCallback, usr); HIDRead(handle, usr->buf, bytes_transfered, myHIDReadCallback, usr);
} }