Skip to content

Commit

Permalink
Merge branch 'feature/neoscrypt-lyra2re-support'
Browse files Browse the repository at this point in the history
  • Loading branch information
nwoolls committed Jan 14, 2015
2 parents 16d66ed + 0c77ae3 commit 8c78224
Show file tree
Hide file tree
Showing 6 changed files with 37 additions and 0 deletions.
2 changes: 2 additions & 0 deletions MultiMiner.Engine/Data/AlgorithmParameter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,7 @@ class AlgorithmParameter
public const string AlgorithmX13 = "--algorithm x13";
public const string AlgorithmX14 = "--algorithm x14";
public const string AlgorithmX15 = "--algorithm x15";
public const string AlgorithmNeoScrypt = "--algorithm neoscrypt";
public const string AlgorithmLyra2RE = "--algorithm lyra2re";
}
}
8 changes: 8 additions & 0 deletions MultiMiner.Engine/MiningEngine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,14 @@ private static void RegisterBuiltInAgorithms()
algorithm = factory.RegisterAlgorithm(AlgorithmNames.X15, AlgorithmFullNames.X15, CoinAlgorithm.AlgorithmFamily.Unknown);
algorithm.DefaultMiner = MinerNames.SGMiner5;
algorithm.MinerArguments[MinerNames.SGMiner5] = AlgorithmParameter.AlgorithmX15;

algorithm = factory.RegisterAlgorithm(AlgorithmNames.NeoScrypt, AlgorithmFullNames.NeoScrypt, CoinAlgorithm.AlgorithmFamily.Scrypt);
algorithm.DefaultMiner = MinerNames.SGMiner5;
algorithm.MinerArguments[MinerNames.SGMiner5] = AlgorithmParameter.AlgorithmNeoScrypt;

algorithm = factory.RegisterAlgorithm(AlgorithmNames.Lyra2RE, AlgorithmFullNames.Lyra2RE, CoinAlgorithm.AlgorithmFamily.Unknown);
algorithm.DefaultMiner = MinerNames.SGMiner5;
algorithm.MinerArguments[MinerNames.SGMiner5] = AlgorithmParameter.AlgorithmLyra2RE;
}

private static void RegisterMiners()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ public static bool PopulateFromJson(this MultipoolInformation multipoolInformati
case 7:
multipoolInformation.Algorithm = AlgorithmNames.Nist5;
break;
case 8:
multipoolInformation.Algorithm = AlgorithmNames.NeoScrypt;
break;
case 9:
multipoolInformation.Algorithm = AlgorithmNames.Lyra2RE;
break;
default:
//unknown algo
return false;
Expand Down
8 changes: 8 additions & 0 deletions MultiMiner.Xgminer/Data/AlgorithmNames.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ public static class AlgorithmNames
public const string ScryptJane = "ScryptJane";
public const string Keccak = "Keccak";
public const string Nist5 = "Nist5";
public const string NeoScrypt = "NeoScrypt";
public const string Lyra2RE = "Lyra2RE";
}

public static class AlgorithmFullNames
Expand All @@ -30,8 +32,12 @@ public static class AlgorithmFullNames
public const string ScryptJane = "Scrypt-Jane";
public const string Keccak = "Keccak";
public const string Nist5 = "Nist5";
public const string NeoScrypt = "NeoScrypt";
public const string Lyra2RE = "Lyra2RE";
}

//used for determining profitability with Multipools
//reference at https://www.nicehash.com/index.jsp?p=multialgo
public static class AlgorithmMultipliers
{
public const double SHA256 = 1.0;
Expand All @@ -46,5 +52,7 @@ public static class AlgorithmMultipliers
public const double ScryptJane = 0.0005;
public const double Keccak = 0.5;
public const double Nist5 = 0.015;
public const double NeoScrypt = 0.0003;
public const double Lyra2RE = 0.00125;
}
}
1 change: 1 addition & 0 deletions MultiMiner.Xgminer/Data/CoinAlgorithm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ namespace MultiMiner.Xgminer.Data
{
public class CoinAlgorithm
{
//used for determining work utility / effective hashrate
public enum AlgorithmFamily
{
Unknown,
Expand Down
12 changes: 12 additions & 0 deletions MultiMiner.Xgminer/Data/KnownAlgorithms.cs
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,18 @@ public static class KnownAlgorithms
Name = AlgorithmNames.Nist5,
FullName = AlgorithmFullNames.Nist5,
Multiplier = AlgorithmMultipliers.Nist5
},
new KnownAlgorithm
{
Name = AlgorithmNames.NeoScrypt,
FullName = AlgorithmFullNames.NeoScrypt,
Multiplier = AlgorithmMultipliers.NeoScrypt
},
new KnownAlgorithm
{
Name = AlgorithmNames.Lyra2RE,
FullName = AlgorithmFullNames.Lyra2RE,
Multiplier = AlgorithmMultipliers.Lyra2RE
}
};
}
Expand Down

0 comments on commit 8c78224

Please sign in to comment.