-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dllexp_SetLedData returns ERROR_INSUFFICIENT_BUFFER when setting any configuration #10
Comments
I've hit this issue a few times with GLedAPI. My best guess is that it's timing related as it occurs most often when repeating the set LED flow from Init.
If anyone can find a reliable way to reproduce it then it might be possible to work around the driver issue.
|
Is this related to #8 ? |
No it looks like I might be introducing an issue when I have RGB Fusion running at the same time and I switch the lights off from Fusion. I am working to see if I can more easily reproduce the issue on a more consistent basis: C:\Users\israel\Desktop\rgb fusion>RGBFusionTool.exe -v --color white Options: Error: GLedApiDotNet.Raw.GLedAPIv1_0_0Exception: dllexp_SetLedData returned ERROR_INSUFFICIENT_BUFFER This might be completely avoided if I or other users don't have RGB Fusion open or using both at the same time. |
Just for testing, I powered off my system and pulled the power. I then launched windows and started using the tool w/o even launching RGB Fusion. Just to make sure there was nothing in the buffer. When repeated commands in quick succession: RGBFusionTool.exe -v --color blue RGBFusionTool.exe -v --color blue RGBFusionTool.exe -v --color blue Options: Error: GLedApiDotNet.Raw.GLedAPIv1_0_0Exception: dllexp_SetLedData returned ERROR_INSUFFICIENT_BUFFER In both of these two cases tonight, I was able to continue using after getting the error message. This unlike last night where the lights were unresponsive, even after reboot. To fix that, I had to pull the power. |
I suspect that having this tool run while anything else is trying to set LEDs will not work well. Gigabyte's tools go to some effort to kill other processes that might be trying to set lights. I've created issue #11 to track work on detecting and warning of conflicting processes. |
I did try on a fresh boot w/o starting the Fusion UI, though on startup there has to be some processes associated with Fusion as the lights come on, when I login to Windows. I was able to generate this one entering a lot of commands in quick succession. Do you have Fusion installed and/or running in the background? |
Whenever you run one of those tools Gigabyte puts some daemons in startup. I put a list of processes I've identified in issue #11. |
I keep upping the sleep time and I don't know if it really has any effect on throwing this error. It isn't one zone in particular. Granted once I get setting multi zone, I am hoping it will help, though it might also turn into an all or nothing. |
Good news the tool can run w/o RGB Fusion installed, bad news it didn't fix the issue. I did different tests and I can not find anything in common that would cause the problem. I wrote a SPAM script to help test: $path = $PSScriptRoot + "\RGBFusionTool.exe" $x=0
$x+=1 } I will up the time a lot to like 5 seconds on sleep to see if it is just a red herring or not. |
I tried doing a complete shutdown of my system including flipping the switch on the back of my power supply and I still can't get the program to work when compiled from source. The program does work when using the provided binary but that really shouldn't matter. Right? Is it something I'm doing wrong in the compile phase? |
TBH I never compiled from source and just used the binaries. Just wondering what Motherboard you are using? |
@trparky have you tried from an elevated prompt? I still don't know under what conditions you need to be elevated to get this to work (I don't need it, but others have had issues when running from a non-elevated prompt). |
Tried in an elevated command prompt, didn't work either. Gigabyte Z370 AORUS Ultra Gaming. Error: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> GLedApiDotNet.Raw.GLedAPIv1_0_0Exception: dllexp_InitAPI returned ERROR_INSUFFICIENT_BUFFER |
Hmm, the one you compile should work just as well as the provided binary. Especially if you're using the same |
Oh yeah, I was missing the ycc.dll and layout.ini files. I feel like an idiot. |
No worries, this is actually worth addressing as a feature. I've created issue #25 to capture the need for better dependency checking and more meaningful error output. |
I pretty sure I got all the dependencies ( GLedApi.dll, GLedApiDotNet.dll, layout.ini, Mono.Options.dll, & ycc.dll ) but now i get this response from doing: RGBFusionTool.exe --static=RED I get the following: Am i doing something wrong? The --help works perfectly but setting the colors will pause for about 6 seconds then spit the error mess ( I pasted above this ) |
Would you paste the output of the following PowerShell script: $winver = [System.Environment]::OSVersion.Version.ToString()
$toolver = (Get-Item .\RGBFusionTool.exe).VersionInfo.FileVersion.ToString()
$hashes = @("GLedApi.dll", "GLedApiDotNet.dll", "layout.ini", "Mono.Options.dll", "RGBFusionTool.exe", "ycc.dll") | % { Get-FileHash -Algorithm SHA256 -Path $_ }
$biosversion = (Get-WmiObject -Class Win32_BIOS).SMBIOSBIOSVersion
$motherboard = (Get-WmiObject -Class Win32_BaseBoard).Product
Write-Host -ForegroundColor White -BackgroundColor Black @"
``````
- Windows Version: $winver
- RGB Fusion Tool Version: $toolver
- Motherboard: $motherboard
- BIOS: $biosversion
Hashes:
$(($hashes | % { "$($_.Hash) $(Split-Path -Leaf $_.Path)"}) -join "`n")
``````
"@
Out-Null | Write-Host |
I got the following:
Hashes: 2C0DCD27AF18DABBE679ED915AE772A561072FF9C7AA8218284A017223945459 GLedApi.dll |
I notice one oddity and I'd like you to try with the It does look like your AB350-Gaming 3 is supported, so that's good 🙂. If you've tried Gigabyte's RGB Fusion tools have they worked ? No need to go installing it just yet if you haven't, but it'll help to identify what's up.
I searched VirusTotal for the your hash and there are no hits. So I'm not sure what version of If you downloaded an SDK right from Gigabyte you can check the hashes against the ones I have in README.md if you're concerned there may be corruption. I also see that your hashes for If you download the v0.9.1 release from the Github releases it should have the following SHA256 |
I re-downloaded the whole RGBFusionTool and just pressing F5 (to build), and using the .dlls from B18.0206.1.zip I get the following results:
but I'm stilling getting the weird errors, I tried unplugging my cooler's RGB connector from my mobo to see maybe thats the problem, but the problem still is present, the RGB Fusion app works fine. The error occurs around GLedAPIv1_0_0Wrapper.cs line: 51 the I've also tried using the GLedApi.dll, ycc.dll, and layout.ini from the built test in B18.0206.1.zip and from the RGBFusion app but I can't seem to fix this. Here I'm using the RGBFusion app and using the "Random" preset: |
Also with using the build test in B18.0206.1.zip: |
After thoughts: Maybe I shoud've gotten an MSI/Asus motherboard... |
I'm guessing that number was Good news is the RGB Fusion GUI stuff works so your hardware is probably in good shape. If you look in Worth noting that it's really hard to screw up calling into the SDK at this point since calls take any input until after If you're on Reddit I find /r/gigabytegaming/ to be a good place to mention issues - others with the same motherboard might have found a way to recover and one of the GBT_ people might be able to pass it on to the devs. I've created issue #30 to track this bug. I'll see if I can find a way to hack in support for your motherboard in the meantime. |
I was able to reproduce a variation on the issue by removing the entry for my motherboard from I thought there was a repro, however there is not. I've updated the title and returned the "no repro" tag. |
I have the same issue. Initially, my RGB's are stuck on WHITE. RGBFusion from gigabyte nor via the bios was able to turn the RGB's off or change color. Was hoping the app fixes the problem, but instead I'm getting the famous ERROR_INSUFFICIENT_BUFFER as well. Did a full powerdown as as suggested somewhere Any idea how to fix this as I couldn't really see a solution on this issue |
I've started getting this error after updating my AORUS X470 Gaming Wifi BIOS to the F6 revision. LEDS are stuck on orange full brightness, and Gigabyte's RGBFusion does not work either. I'll perform a full shutdown with power switch on the next chance I get, and provide updates. |
@oblivion2k |
Gigabyte's RGBFusion 2.0 works correctly after an overnight full shutdown with PSU switch off, but RGB Fusion Tool still has the same error, something must have changed between F2 and F6 BIOS revisions to trigger this. |
Have you tried the new version of the SDK? I haven't had a chance to test it so I didn't package it yet you can find it here: https://www.gigabyte.com/mb/rgb/sdk |
Any updates on this error? |
@MobKill3r2006 sadly, no - without the hardware to test against or another spec or SDK from Gigabyte this project is stuck with what's offered. There have been some other projects that did more to reverse engineer what Gigabyte is doing and you might consider those. I'd like to work on top of what they're offering; but given the lack of support I'd look to other vendors altogether for lighting. I think Corsair makes a controller that's well supported; @windows2000bug is someone to ask about options. |
Alright, damn it. This was the only project I found that uses code to control the lights on my motherboard. I wanted to make a program that controls both the lights on my motherboard and on my razer keyboard. Thanks, however. |
Same issue with x570 aorus ultra |
I seem to have the exact same issue using a Z390 I AORUS Pro Wifi mini-itx I get the following: Error: GLedApiDotNet.Raw.GLedAPIv1_0_0Exception: dllexp_InitAPI returned ERROR_INSUFFICIENT_BUFFER at System.Lazy 1.ViaFactory(LazyThreadSafetyMode mode) at System.Lazy 1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)at System.Lazy 1.CreateValue() at System.Lazy 1.get_Value()at RGBFusionTool.Application.Main(String[] args) in C:\RGBFusion\Source\RGBFusionTool\Application.cs:line 100 |
Got message yesterday and forgot to save it. It mentioned some buffer got full and would not allow me to change colors of the lights. I even switched to RGB Fusion and I couldn't do anything with that. The only way I got it to work again was to turn the PC off and kill the power. The LEDs stayed lit after shutdown and went off after I killed the main power switch.
The text was updated successfully, but these errors were encountered: