Support new overclocking speeds for avalon: 325, 350 and 375
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103
diff --git a/ASIC-README b/ASIC-README
index 6d10d9c..de349a6 100644
--- a/ASIC-README
+++ b/ASIC-README
@@ -103,7 +103,10 @@ It is possible to set this a little lower if you are trying to tune for short
block mining (eg p2pool) but much lower and the device will start creating
duplicate shares.
-Sample settings for different frequencies (last 2 values):
+Sample settings for valid different frequencies (last 2 values):
+34:375
+36:350
+39:325
43:300
45:282 (default)
47:270
@@ -111,14 +114,14 @@ Sample settings for different frequencies (last 2 values):
Frequency:
This is the clock speed of the devices. Only specific values work, 256, 270,
-282 (default) and 300.
+282 (default), 300, 325, 350 and 375.
If you use the full curses based interface with Avalons you will get this
information:
-AVA 0: 22/ 46C 60%/2400R
+AVA 0: 22/ 46C 2400R
The values are:
-ambient temp / highest device temp set fan % / lowest detected fan RPM.
+ambient temp / highest device temp lowest detected ASIC cooling fan RPM.
Use the API for more detailed information than this.
diff --git a/driver-avalon.c b/driver-avalon.c
index 1e14732..7d0e483 100644
--- a/driver-avalon.c
+++ b/driver-avalon.c
@@ -96,18 +96,36 @@ static int avalon_init_task(struct avalon_task *at,
buf[9] = 0x01;
buf[10] = 0x00;
buf[11] = 0x00;
- if (frequency == 256) {
- buf[6] = 0x03;
- buf[7] = 0x08;
- } else if (frequency == 270) {
- buf[6] = 0x73;
- buf[7] = 0x08;
- } else if (frequency == 282) {
- buf[6] = 0xd3;
- buf[7] = 0x08;
- } else if (frequency == 300) {
- buf[6] = 0x63;
- buf[7] = 0x09;
+ switch (frequency) {
+ case 256:
+ buf[6] = 0x03;
+ buf[7] = 0x08;
+ break;
+ default:
+ case 270:
+ buf[6] = 0x73;
+ buf[7] = 0x08;
+ break;
+ case 282:
+ buf[6] = 0xd3;
+ buf[7] = 0x08;
+ break;
+ case 300:
+ buf[6] = 0x63;
+ buf[7] = 0x09;
+ break;
+ case 325:
+ buf[6] = 0x28;
+ buf[7] = 0x0a;
+ break;
+ case 350:
+ buf[6] = 0xf0;
+ buf[7] = 0x0a;
+ break;
+ case 375:
+ buf[6] = 0xb8;
+ buf[7] = 0x0b;
+ break;
}
return 0;
@@ -447,11 +465,14 @@ static bool get_options(int this_option_offset, int *baud, int *miner_count,
case 270:
case 282:
case 300:
+ case 325:
+ case 350:
+ case 375:
*frequency = tmp;
break;
default:
quit(1, "Invalid avalon-options for "
- "frequency must be 256/270/282/300");
+ "frequency must be 256/270/282/300/325/350/375");
}
}
}