EvanMulawski / FanControl.CorsairLink

The unofficial CorsairLink plugin for Fan Control. Adds support for Corsair controllers, liquid coolers, and power supplies. An alternative to iCUE.
152 stars 11 forks source link

Add support for .NET 8 build of Fan Control #20

Open ChaseDDevelopment opened 1 year ago

ChaseDDevelopment commented 1 year ago

Hey there,

I am having the same behaviour as in issue (#2), though I believe it's a different exception:

I've attached the logs.
I've tried the latest Release (v 1.0.0) as well as the latest beta release.

I have ensured both zip's and dll's are unblocked as per the instructions. Please let me know if I can help in any way.


Corsair Commander PRO could not initialize or has no sensors.
2/26/2023 12:10:12 PM: [CorsairLink] DeviceManager: Found 2 Corsair device(s)
  name=CORSAIR iCUE Commander CORE, devicePath=\\?\hid#vid_1b1c&pid_0c1c&mi_01#7&26ae1e37&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
  name=CORSAIR iCUE Commander CORE, devicePath=\\?\hid#vid_1b1c&pid_0c1c&mi_00#7&2d6e075&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}

2/26/2023 12:10:12 PM: [CorsairLink] DeviceManager: Found 1 supported Corsair device(s)
  name=CORSAIR iCUE Commander CORE, devicePath=\\?\hid#vid_1b1c&pid_0c1c&mi_00#7&2d6e075&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}

2/26/2023 12:10:12 PM: [CorsairLink] An exception occurred attempting to initialize device 'CORSAIR iCUE Commander CORE (e20f10a0948871aa8559c2063091005f)' (\\?\hid#vid_1b1c&pid_0c1c&mi_00#7&2d6e075&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}):
2/26/2023 12:10:12 PM: [CorsairLink] System.TypeInitializationException: The type initializer for 'CorsairLink.Synchronization.CorsairDevicesGuard' threw an exception.
 ---> System.MissingMethodException: Method not found: 'Void System.Threading.Mutex.SetAccessControl(System.Security.AccessControl.MutexSecurity)'.
   at CorsairLink.Synchronization.CorsairDevicesGuard.CreateMutex()
   at CorsairLink.Synchronization.CorsairDevicesGuard..cctor()
   --- End of inner exception stack trace ---
   at CorsairLink.Synchronization.CorsairDevicesGuard.Acquire()
   at CorsairLink.Synchronization.CorsairDevicesGuardLock..ctor()
   at CorsairLink.Synchronization.CorsairDevicesGuardManager.AwaitExclusiveAccess()
   at CorsairLink.CommanderCoreDevice.RefreshImpl(Boolean initialize)
   at CorsairLink.CommanderCoreDevice.Connect()
   at FanControl.CorsairLink.CorsairLinkPlugin.FanControl.Plugins.IPlugin.Initialize()
2/26/2023 12:10:14 PM: [CorsairLink] DeviceManager: Found 2 Corsair device(s)
  name=CORSAIR iCUE Commander CORE, devicePath=\\?\hid#vid_1b1c&pid_0c1c&mi_01#7&26ae1e37&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
  name=CORSAIR iCUE Commander CORE, devicePath=\\?\hid#vid_1b1c&pid_0c1c&mi_00#7&2d6e075&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}```
EvanMulawski commented 1 year ago

Hi @ChaseDDevelopment, are you using the .NET Framework 4.8 build of Fan Control or the .NET 7 build?

ChaseDDevelopment commented 1 year ago

Hey @EvanMulawski I am using the .NET 7 build with runtime 7.0.3

EvanMulawski commented 1 year ago

There isn't a .NET 7-compatible build yet, so the .NET Framework build of Fan Control is required (and somewhat recommended; most of the available plugins only target .NET Framework anyway). I'll add this to the README.

Rem0o commented 1 year ago

@EvanMulawski you could create a multi-target (net48;net7) and use the FanControl.Plugin.dll from the net48 and net7 release with a prefix to bundle both version if you want to do that.

ChaseDDevelopment commented 1 year ago

@EvanMulawski Just got finished trying the Framework build v147 and it worked like a charm. Much appreciated!!

As a note, I did have to stay on the v147 build as when prompted by Fan control to update to v148, the plugin broke.

EvanMulawski commented 1 year ago

@ChaseDDevelopment Yeah, there's a problem with v148. See https://github.com/Rem0o/FanControl.Releases/discussions/1577#discussioncomment-5161062

ChaseDDevelopment commented 1 year ago

@ChaseDDevelopment Yeah, there's a problem with v148. See Rem0o/FanControl.Releases#1577 (comment)

No problem! Thanks for calling that issue out. Appreciate the work you've put into this, made sure One of the PC's in the house could have it's fans controlled nicely through corsair's core! This can be closed, unless you want it open for the enhancement.

CalculonPrime commented 1 year ago

There isn't a .NET 7-compatible build yet, so the .NET Framework build of Fan Control is required (and somewhat recommended; most of the available plugins only target .NET Framework anyway). I'll add this to the README.

Isn't .NET 7 a .NET Framework? If .NET 7 is not a .NET Framework, that's confusing.

Rem0o commented 1 year ago

Isn't .NET 7 a .NET Framework? If .NET 7 is not a .NET Framework, that's confusing.

@CalculonPrime Tell Microsoft. It is ;P

p1r473 commented 8 months ago

Tried this with the latest version of .NET 8 of FanControl - didnt work - had to roll back to 4.8 I guess this is still not implemented yet right?

EvanMulawski commented 8 months ago

Tried this with the latest version of .NET 8 of FanControl - didnt work - had to roll back to 4.8 I guess this is still not implemented yet right?

Not yet - will be in v2.0 which is currently being designed.

Rem0o commented 8 months ago

FanControl.Plugins.dll is netstandard2.0 by the way @EvanMulawski, so you can use the same for both.

TannerBragg commented 6 months ago

FanControl.Plugins.dll is netstandard2.0 by the way @EvanMulawski, so you can use the same for both.

All of my fans and pumps are run through core commanders. Without this plugin working with the .NET 8, I can't explore the software. I'd love to use this plugin, but it appears it is still incompatible with .NET 8.

I suppose it isn't being compiled against .NET Standard 2.0. I feel like this should be a relatively easy change to retarget the project? Can this be done so those of us on the latest can enjoy the plugin?

EvanMulawski commented 6 months ago

I am working on multi-targeting - will be after v1.6.0 comes out of beta.

EvanMulawski commented 5 months ago

Support added in v1.7.0-beta.1