Rem0o / FanControl.Releases

This is the release repository for Fan Control, a highly customizable fan controlling software for Windows.
Other
13.78k stars 437 forks source link

Issue with duplicate Fan and Control identifiers in ASRock z690 PG Velocita #2094

Closed brentward closed 10 months ago

brentward commented 11 months ago

Describe the bug My system shows duplicate identifiers for fans and sensors which is causing conflicts and preventing sensor pairing and any configuration information from saving. Is there a log.txt file next to FanControl.exe with recent date entries? No log.txt

Relevant hardware specs and setup ASRock z690 PG Velocita

In LibreHardwareMonitor there are two different entries for Nuvoton NCT6796D-R that each list 7 fans and controls, so it seems that FanControl is not distinguishing between the fans and controls with the same index on the different controllers.

Screenshot 2023-10-18 170231 Screenshot 2023-10-18 171828

The default configuration shows duplicate identifies for Controls and FanSensors.

{
  "__VERSION__": "172",
  "Main": {
    "Controls": [
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/0",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #1",
        "NickName": "Fan #1",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/1",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #2",
        "NickName": "Fan #2",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/2",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #3",
        "NickName": "Fan #3",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/3",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #4",
        "NickName": "Fan #4",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/4",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #5",
        "NickName": "Fan #5",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/5",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #6",
        "NickName": "Fan #6",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/6",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #7",
        "NickName": "Fan #7",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/0",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #1",
        "NickName": "Fan #1",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/1",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #2",
        "NickName": "Fan #2",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/2",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #3",
        "NickName": "Fan #3",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/3",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #4",
        "NickName": "Fan #4",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/4",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #5",
        "NickName": "Fan #5",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/5",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #6",
        "NickName": "Fan #6",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "/lpc/nct6796dr/control/6",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Fan #7",
        "NickName": "Fan #7",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "NVApiWrapper/0-GA102-A/control/0",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Control 1 - NVIDIA GeForce RTX 3080",
        "NickName": "Control 1 - NVIDIA GeForce RTX 3080",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      },
      {
        "Enable": false,
        "ForceApply": false,
        "Identifier": "NVApiWrapper/0-GA102-A/control/1",
        "IsHidden": false,
        "ManualControl": false,
        "ManualControlValue": 50,
        "MinimumPercent": 0,
        "Name": "Control 2 - NVIDIA GeForce RTX 3080",
        "NickName": "Control 2 - NVIDIA GeForce RTX 3080",
        "PairedFanSensor": null,
        "SelectedCommandStepDown": 8.0,
        "SelectedCommandStepUp": 8.0,
        "SelectedFanCurve": null,
        "SelectedOffset": 0,
        "SelectedStart": 0,
        "SelectedStop": 0
      }
    ],
    "CustomSensors": [],
    "FanCurves": [
      {
        "IsHidden": false,
        "Name": "Flat curve example",
        "Percent": 50.0
      }
    ],
    "FanSensors": [
      {
        "Identifier": "/lpc/nct6796dr/fan/0",
        "IsHidden": false,
        "Name": "Fan #1",
        "NickName": "Fan #1"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/1",
        "IsHidden": false,
        "Name": "Fan #2",
        "NickName": "Fan #2"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/2",
        "IsHidden": false,
        "Name": "Fan #3",
        "NickName": "Fan #3"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/3",
        "IsHidden": false,
        "Name": "Fan #4",
        "NickName": "Fan #4"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/4",
        "IsHidden": false,
        "Name": "Fan #5",
        "NickName": "Fan #5"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/5",
        "IsHidden": false,
        "Name": "Fan #6",
        "NickName": "Fan #6"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/6",
        "IsHidden": false,
        "Name": "Fan #7",
        "NickName": "Fan #7"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/0",
        "IsHidden": false,
        "Name": "Fan #1",
        "NickName": "Fan #1"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/1",
        "IsHidden": false,
        "Name": "Fan #2",
        "NickName": "Fan #2"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/2",
        "IsHidden": false,
        "Name": "Fan #3",
        "NickName": "Fan #3"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/3",
        "IsHidden": false,
        "Name": "Fan #4",
        "NickName": "Fan #4"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/4",
        "IsHidden": false,
        "Name": "Fan #5",
        "NickName": "Fan #5"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/5",
        "IsHidden": false,
        "Name": "Fan #6",
        "NickName": "Fan #6"
      },
      {
        "Identifier": "/lpc/nct6796dr/fan/6",
        "IsHidden": false,
        "Name": "Fan #7",
        "NickName": "Fan #7"
      },
      {
        "Identifier": "NVApiWrapper/0-GA102-A/fan/0",
        "IsHidden": false,
        "Name": "Fan 1 - NVIDIA GeForce RTX 3080",
        "NickName": "Fan 1 - NVIDIA GeForce RTX 3080"
      },
      {
        "Identifier": "NVApiWrapper/0-GA102-A/fan/1",
        "IsHidden": false,
        "Name": "Fan 2 - NVIDIA GeForce RTX 3080",
        "NickName": "Fan 2 - NVIDIA GeForce RTX 3080"
      }
    ],
    "HideFanSpeedCards": false,
    "HorizontalUIOrientation": false,
    "PrimaryColor": "#FF607D8B",
    "SecondaryColor": "#FFAEEA00",
    "SelectedTheme": "Dark",
    "ShowHiddenCards": true,
    "SyncThemeWithWindows": true,
    "TemperatureSensors": [],
    "TrayIconColor": "#FFFFFFFF",
    "TrayIcons": []
  },
  "Sensors": {
    "DisabledPlugins": [],
    "DisableStorageSensors": true,
    "LibreHardwareMonitorSettings": {
      "Controller": false,
      "CPU": true,
      "EmbeddedEC": true,
      "GPU": true,
      "InpOut": false,
      "Memory": false,
      "Motherboard": true,
      "PSU": false,
      "Storage": false,
      "ZeroRPMOverride": false
    },
    "NvAPIWrapperSettings": {
      "Enabled": true,
      "ZeroRPMOverride": false
    },
    "SensorCount": 77
  }
}
Rem0o commented 11 months ago

From your LHM screenshot, you got 2 NCT6796D-R on that board? That's a first.

"Identifier": "/lpc/nct6796dr/control

Problem would then lie here, we got identifier conflicts.

brentward commented 11 months ago

Yeah, that seems like the issue. Is this an issue with LHM or does FanControl create the identifiers?

Rem0o commented 11 months ago

FanControl uses the identifiers provided as is, so I guess I'll have to add another layer on top verifying for dups.

Rem0o commented 11 months ago

Created a PR in LHM for this bug: https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/pull/1183

brentward commented 11 months ago

Update: I must have used the wrong version of FanControl because I tried using the build artifacts from your LHM PR again with a fresh copy of the net_7_0 version of FanControl and it started up and the issue seems to be resolved. I will use it for a bit and report back.

~Is it possible to use the build artifacts from your LHM PR to test if it fixes FanControl? I tried just dropping the LibreHardwareMonitorLib.* files from the net70 artifact into the FanControl directory but that didn't work.~

brentward commented 10 months ago

I've been using it with the artifacts from your LHM PR for a few days and everything seems to be working.

brentward commented 10 months ago

Does the latest FanControl release, V173, include your LHM fix? I installed it expecting to have to replace the LHM files again but it continued to work without doing that.

Rem0o commented 10 months ago

I compile my own branch of LHM for FanControl, with urgent fixes in it, until they get merged.

Rem0o commented 10 months ago

https://github.com/LibreHardwareMonitor/LibreHardwareMonitor/commit/a84e6c6e8d678c9bf0ee03a4a06b6cf5860474b8

brentward commented 9 months ago

When I upgraded to V174 a bunch of sensors for the fans were reset. Is this caused by a difference between your custom version of LHM and the way it was merged? I'm redetecting the fans now and they are all still work but I'm wondering; will I have to do this again on future upgrades? Screenshot 2023-11-22 104829

Rem0o commented 9 months ago

Yes kind of, the implementation changed a bit. Now all identifiers with an index of 0 get their index removed so that everybody with only a single LPC chip doesn't get all their identifiers changed.

for eg: If you got only a single NCT6796D: /lpc/nct6796d/control/1

if you got three: NCT6796D /lpc/nct6796d/control/1 /lpc/nct6796d/1/control/1 /lpc/nct6796d/2/control/1 [...]

People with single chip => no identifier change People with two chip (like you) => both chip get a unique identifier.

You should be good now.