Hardware/Mainboard/SuperIOHardware.cs
changeset 167 b7cc9d09aefe
parent 166 fa9dfbfc4145
child 168 7f90baeb96b0
     1.1 --- a/Hardware/Mainboard/SuperIOHardware.cs	Thu Aug 12 20:53:27 2010 +0000
     1.2 +++ b/Hardware/Mainboard/SuperIOHardware.cs	Sun Aug 15 14:46:58 2010 +0000
     1.3 @@ -44,39 +44,18 @@
     1.4    internal class SuperIOHardware : Hardware {
     1.5  
     1.6      private ISuperIO superIO;
     1.7 -    protected readonly string name;
     1.8 +    private string name;
     1.9  
    1.10      private List<Sensor> voltages = new List<Sensor>();
    1.11      private List<Sensor> temperatures = new List<Sensor>();
    1.12 -    private List<Sensor> fans = new List<Sensor>();  
    1.13 +    private List<Sensor> fans = new List<Sensor>();
    1.14 +
    1.15  
    1.16      public SuperIOHardware(ISuperIO superIO, Manufacturer manufacturer,
    1.17        Model model, ISettings settings) 
    1.18      {
    1.19        this.superIO = superIO;
    1.20 -
    1.21 -      switch (superIO.Chip) {
    1.22 -        case Chip.F71858: name = "Fintek F71858"; break;
    1.23 -        case Chip.F71862: name = "Fintek F71862"; break;
    1.24 -        case Chip.F71869: name = "Fintek F71869"; break;
    1.25 -        case Chip.F71882: name = "Fintek F71882"; break;
    1.26 -        case Chip.F71889ED: name = "Fintek F71889ED"; break;
    1.27 -        case Chip.F71889F: name = "Fintek F71889F"; break;
    1.28 -        case Chip.IT8712F: this.name = "ITE IT8712F"; break;
    1.29 -        case Chip.IT8716F: this.name = "ITE IT8716F"; break;
    1.30 -        case Chip.IT8718F: this.name = "ITE IT8718F"; break;
    1.31 -        case Chip.IT8720F: this.name = "ITE IT8720F"; break;
    1.32 -        case Chip.IT8726F: this.name = "ITE IT8726F"; break;
    1.33 -        case Chip.W83627DHG: this.name = "Winbond W83627DHG"; break;
    1.34 -        case Chip.W83627DHGP: this.name = "Winbond W83627DHG-P"; break;
    1.35 -        case Chip.W83627EHF: this.name = "Winbond W83627EHF"; break;
    1.36 -        case Chip.W83627HF: this.name = "Winbond W83627HF"; break;
    1.37 -        case Chip.W83627THF: this.name = "Winbond W83627THF"; break;
    1.38 -        case Chip.W83667HG: this.name = "Winbond W83667HG"; break;
    1.39 -        case Chip.W83667HGB: this.name = "Winbond W83667HG-B"; break;
    1.40 -        case Chip.W83687THF: this.name = "Winbond W83687THF"; break;
    1.41 -        case Chip.Unknown: this.name = "Unkown"; break;
    1.42 -      }
    1.43 +      this.name = ChipName.GetName(superIO.Chip);
    1.44  
    1.45        List<Voltage> v = new List<Voltage>();
    1.46        List<Temperature> t = new List<Temperature>();
    1.47 @@ -483,7 +462,6 @@
    1.48                    v.Add(new Voltage("Standby +3.3V", 7, 34, 34, 0));
    1.49                    v.Add(new Voltage("VBAT", 8, 34, 34, 0));
    1.50                    t.Add(new Temperature("CPU", 0));
    1.51 -                  t.Add(new Temperature("Auxiliary", 1, true));
    1.52                    t.Add(new Temperature("Motherboard", 2));
    1.53                    f.Add(new Fan("Chassis Fan #1", 0));
    1.54                    f.Add(new Fan("CPU Fan", 1));
    1.55 @@ -673,15 +651,10 @@
    1.56      private class Temperature {
    1.57        public readonly string Name;
    1.58        public readonly int Index;
    1.59 -      public readonly bool Hidden;
    1.60  
    1.61 -      public Temperature(string name, int index) :
    1.62 -        this(name, index, false) { }
    1.63 -
    1.64 -      public Temperature(string name, int index, bool hidden) {
    1.65 +      public Temperature(string name, int index) {
    1.66          this.Name = name;
    1.67          this.Index = index;
    1.68 -        this.Hidden = hidden;
    1.69        }
    1.70      }
    1.71