-
-
Notifications
You must be signed in to change notification settings - Fork 5
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
ZWaveJS.NET does not support multiple drivers #61
Comments
Ooof! possible of course, but will need some (quite a bit) of re-work - and thought From the top of my head
Example Controller C = JO.SelectToken("result.state.controller").ToObject<Controller>();
C._Driver = this
There is a lot that surrounds the static approach presently, unless I'm over thinking it 🤔 |
@marcus-j-davies , do you want me to take a shot at it, or do you want to do it? |
Hi @spudwebb I am not one to reject free labour! 😉 Thanks |
Is this still open or resolved? I see the latest available is '22 still (from Visual Studio NuGet) |
Hi, this issue is still open, as v4 has not yet been published. it’s fixed in the v4 branch. |
Closing... This feature is available in V4, where its release is imminent. |
I'm trying to control multiple instances of ZWave JS from the same C# program. For this, I initialize multiple instances of the ZWaveJS.NET.Driver class but as soon as I initialize a second instance, the Driver.Instance of the first instance is overwritten because Driver.Instance is static:
ZWaveJS.NET/Visual Studio Projects/ZWaveJS.NET/ZWaveJS.NET/Driver.cs
Line 14 in 6c3db91
So I think we should refactor the library so that it does not use a singleton pattern for the Driver class. Do you agree ?
The text was updated successfully, but these errors were encountered: