Browse Source

Extend length of string that can be passed to BFL devices.

Con Kolivas 13 years ago
parent
commit
ac8db06e46
1 changed files with 3 additions and 1 deletions
  1. 3 1
      driver-bitforce.c

+ 3 - 1
driver-bitforce.c

@@ -241,9 +241,9 @@ static bool bitforce_get_temp(struct cgpu_info *bitforce)
 
 static bool bitforce_send_work(struct thr_info *thr, struct work *work)
 {
-	unsigned char ob[61] = ">>>>>>>>12345678901234567890123456789012123456789012>>>>>>>>";
 	struct cgpu_info *bitforce = thr->cgpu;
 	int fdDev = bitforce->device_fd;
+	unsigned char ob[70];
 	char pdevbuf[0x100];
 	char *s;
 
@@ -264,8 +264,10 @@ re_send:
 		return false;
 	}
 
+	sprintf((char *)ob, ">>>>>>>>");
 	memcpy(ob + 8, work->midstate, 32);
 	memcpy(ob + 8 + 32, work->data + 64, 12);
+	sprintf((char *)ob + 8 + 32 + 12, ">>>>>>>>");
 
 	BFwrite(fdDev, ob, 60);
 	BFgets(pdevbuf, sizeof(pdevbuf), fdDev);