Further restricted the identification for Indilinx SSDs to prevent Maxtor HDDs to be identified as Indilinx SSD.
authormoel.mich
Mon, 02 Jan 2012 21:17:21 +0000
changeset 330b2c6d350396d
parent 329 756af5ee409e
child 331 e60f97192555
Further restricted the identification for Indilinx SSDs to prevent Maxtor HDDs to be identified as Indilinx SSD.
Hardware/HDD/DebugSmart.cs
Hardware/HDD/SSDIndilinx.cs
Properties/AssemblyVersion.cs
     1.1 --- a/Hardware/HDD/DebugSmart.cs	Mon Jan 02 20:45:18 2012 +0000
     1.2 +++ b/Hardware/HDD/DebugSmart.cs	Mon Jan 02 21:17:21 2012 +0000
     1.3 @@ -205,7 +205,43 @@
     1.4           C6 000000000000 100 100 0 
     1.5           C7 810100000000 253 253 0 
     1.6           E8 240000000000 60  60  10
     1.7 -         E9 630594120000 92  92  0")
     1.8 +         E9 630594120000 92  92  0"),
     1.9 +
    1.10 +      new Drive("Maxtor 6L300R0", null, 10,    
    1.11 +        @"3   9E5500000000 183 193         
    1.12 +          4   0A0D00000000 252 252         
    1.13 +          5   010000000000 253 253         
    1.14 +          6   000000000000 253 253         
    1.15 +          7   000000000000 252 253         
    1.16 +          8   DFA700000000 224 245         
    1.17 +          9   CE5700000000 155 155         
    1.18 +          10  000000000000 252 253         
    1.19 +          11  000000000000 252 253         
    1.20 +          12  BA0400000000 250 250         
    1.21 +          192 000000000000 253 253         
    1.22 +          193 000000000000 253 253         
    1.23 +          194 3D0000000000 253 42          
    1.24 +          195 5D1F00000000 252 253         
    1.25 +          196 000000000000 253 253         
    1.26 +          197 010000000000 253 253         
    1.27 +          198 000000000000 253 253         
    1.28 +          199 030000000000 196 199         
    1.29 +          200 000000000000 252 253         
    1.30 +          201 000000000000 252 253         
    1.31 +          202 000000000000 252 253         
    1.32 +          203 000000000000 252 253         
    1.33 +          204 000000000000 252 253         
    1.34 +          205 000000000000 252 253         
    1.35 +          207 000000000000 252 253         
    1.36 +          208 000000000000 252 253         
    1.37 +          209 EA0000000000 234 234         
    1.38 +          210 000000000000 252 253         
    1.39 +          211 000000000000 252 253         
    1.40 +          212 000000000000 252 253         
    1.41 +          130 5B0300010002 1   9           
    1.42 +          59  FC3203030100 205 0           
    1.43 +          1   000000000000 0   0           
    1.44 +          144 000000000000 0   34 ")
    1.45        };
    1.46  
    1.47      public IntPtr OpenDrive(int driveNumber) {
     2.1 --- a/Hardware/HDD/SSDIndilinx.cs	Mon Jan 02 20:45:18 2012 +0000
     2.2 +++ b/Hardware/HDD/SSDIndilinx.cs	Mon Jan 02 21:17:21 2012 +0000
     2.3 @@ -40,33 +40,36 @@
     2.4  namespace OpenHardwareMonitor.Hardware.HDD {
     2.5    using System.Collections.Generic;
     2.6  
     2.7 -  [NamePrefix(""), RequireSmart(0xD1)]
     2.8 +  [NamePrefix(""), RequireSmart(0x01), RequireSmart(0x09), RequireSmart(0x0C), 
     2.9 +    RequireSmart(0xD1), RequireSmart(0xCE), RequireSmart(0xCF)]
    2.10    internal class SSDIndilinx : AbstractHarddrive {
    2.11  
    2.12      private static readonly IEnumerable<SmartAttribute> smartAttributes =
    2.13        new List<SmartAttribute> {
    2.14 -
    2.15 -     new SmartAttribute(0xB8, SmartNames.InitialBadBlockCount),
    2.16 -     new SmartAttribute(0xC3, SmartNames.ProgramFailure),
    2.17 -     new SmartAttribute(0xC4, SmartNames.EraseFailure),
    2.18 -     new SmartAttribute(0xC5, SmartNames.ReadFailure),
    2.19 -     new SmartAttribute(0xC6, SmartNames.SectorsRead),
    2.20 -     new SmartAttribute(0xC7, SmartNames.SectorsWritten),
    2.21 -     new SmartAttribute(0xC8, SmartNames.ReadCommands),
    2.22 -     new SmartAttribute(0xC9, SmartNames.WriteCommands),
    2.23 -     new SmartAttribute(0xCA, SmartNames.BitErrors),
    2.24 -     new SmartAttribute(0xCB, SmartNames.CorrectedErrors),
    2.25 -     new SmartAttribute(0xCC, SmartNames.BadBlockFullFlag),
    2.26 -     new SmartAttribute(0xCD, SmartNames.MaxCellCycles),
    2.27 -     new SmartAttribute(0xCE, SmartNames.MinErase),
    2.28 -     new SmartAttribute(0xCF, SmartNames.MaxErase),
    2.29 -     new SmartAttribute(0xD0, SmartNames.AverageEraseCount),
    2.30 -     new SmartAttribute(0xD1, SmartNames.RemainingLife,
    2.31 -       null, SensorType.Level, 0),
    2.32 -     new SmartAttribute(0xD2, SmartNames.UnknownUnique),
    2.33 -     new SmartAttribute(0xD3, SmartNames.SataErrorCountCrc),
    2.34 -     new SmartAttribute(0xD4, SmartNames.SataErrorCountHandshake),
    2.35 -    };
    2.36 +        new SmartAttribute(0x01, SmartNames.ReadErrorRate),
    2.37 +        new SmartAttribute(0x09, SmartNames.PowerOnHours),
    2.38 +        new SmartAttribute(0x0C, SmartNames.PowerCycleCount),
    2.39 +        new SmartAttribute(0xB8, SmartNames.InitialBadBlockCount),
    2.40 +        new SmartAttribute(0xC3, SmartNames.ProgramFailure),
    2.41 +        new SmartAttribute(0xC4, SmartNames.EraseFailure),
    2.42 +        new SmartAttribute(0xC5, SmartNames.ReadFailure),
    2.43 +        new SmartAttribute(0xC6, SmartNames.SectorsRead),
    2.44 +        new SmartAttribute(0xC7, SmartNames.SectorsWritten),
    2.45 +        new SmartAttribute(0xC8, SmartNames.ReadCommands),
    2.46 +        new SmartAttribute(0xC9, SmartNames.WriteCommands),
    2.47 +        new SmartAttribute(0xCA, SmartNames.BitErrors),
    2.48 +        new SmartAttribute(0xCB, SmartNames.CorrectedErrors),
    2.49 +        new SmartAttribute(0xCC, SmartNames.BadBlockFullFlag),
    2.50 +        new SmartAttribute(0xCD, SmartNames.MaxCellCycles),
    2.51 +        new SmartAttribute(0xCE, SmartNames.MinErase),
    2.52 +        new SmartAttribute(0xCF, SmartNames.MaxErase),
    2.53 +        new SmartAttribute(0xD0, SmartNames.AverageEraseCount),
    2.54 +        new SmartAttribute(0xD1, SmartNames.RemainingLife,
    2.55 +          null, SensorType.Level, 0),
    2.56 +        new SmartAttribute(0xD2, SmartNames.UnknownUnique),
    2.57 +        new SmartAttribute(0xD3, SmartNames.SataErrorCountCrc),
    2.58 +        new SmartAttribute(0xD4, SmartNames.SataErrorCountHandshake)
    2.59 +      };
    2.60  
    2.61      public SSDIndilinx(ISmart smart, string name, string firmwareRevision, 
    2.62        int index, ISettings settings)
     3.1 --- a/Properties/AssemblyVersion.cs	Mon Jan 02 20:45:18 2012 +0000
     3.2 +++ b/Properties/AssemblyVersion.cs	Mon Jan 02 21:17:21 2012 +0000
     3.3 @@ -37,5 +37,5 @@
     3.4  
     3.5  using System.Reflection;
     3.6  
     3.7 -[assembly: AssemblyVersion("0.3.2.6")]
     3.8 -[assembly: AssemblyInformationalVersion("0.3.2.6 Alpha")]
     3.9 \ No newline at end of file
    3.10 +[assembly: AssemblyVersion("0.3.2.7")]
    3.11 +[assembly: AssemblyInformationalVersion("0.3.2.7 Alpha")]
    3.12 \ No newline at end of file