Main > Software Forum

LEDWiz SDK v1.3 Released for developers

<< < (3/6) > >>

arzoo:
hk,
I've got a question about the dll in regards to multiple devices. Randy's com control passes back a string of 1's and 0's representing which devices are detected. I have two ledwiz's (id1 and id2) so the com returns 1100000000000000. I assume if my second device was purchased with id3, then the com would return 1010000000000000.

But with the dll, all I know is how many devices are detected - deviceList.count. Can we assume that the device list always stores the devices in order? In my example above with id1 and id3, would id1 always come before id3 in the device list or is this dependent on the order that XP registered them?

I guess what I'm really asking is, with the dll, how can we identify each device?

I hope I'm making sense here, it's late.  :dizzy:

loadman:

--- Quote ---Randy's com control passes back a string of 1's and 0's representing which devices are detected. I have two ledwiz's (id1 and id2) so the com returns 1100000000000000. I assume if my second device was purchased with id3, then the com would return 1010000000000000.
--- End quote ---

FYI.. Just to confirm what you assumed correctly
In RandyT's Document distributed with the OCX it explains this bit.
1010000000000000 = Led Wiz ID#1 And  Led Wiz ID#3 detected
1110000000000000 = Led Wiz ID#1,Led Wiz ID#2  And  Led Wiz ID#3 detected


--- Quote ---I guess what I'm really asking is, with the dll, how can we identify each device?
--- End quote ---

Yeah..Good question I was going to investigate that tonight..

P.S I don't really care about the hot swap stuff for a LedWiz




arzoo:

--- Quote from: loadman on March 17, 2007, 12:53:36 am ---P.S I don't really care about the hot swap stuff for a LedWiz


--- End quote ---

I agree.

headkaze:

--- Quote ---E2010 Incompatible types: 'HWND' and 'Pointer'
--- End quote ---

Did you try a cast HWND(nil)? Actually just use a '0' instead should work fine.


--- Quote ---I haven't had a chance to try this yet (sorry, real world stuff came up) but I've gotta think that having the same functonality as the ocx internal to the dll(minus some of the less useful ones like random colors) should be top priority.  Yes I can setup a buffer and control individual lights quite easily with code, but the fact that the ledwiz doesn't let you read the current light state means that only one app at a time can control the lights unless you can only set one at a time.  For example j5 can't light a layout and then have mamehooker or one of the other hookers control the coin lights in mame because when the coin lights are set, all the other lights will get turned off.
--- End quote ---

Without the source for the dll I can't change it to keep track of the states/intensities and let you read the them. At the moment we will have to assume that only one application will be using the LEDWiz at one time I'm afraid. I've e-mailed Randy and he dosn't have the source for it, and I've e-mailed MikeQ so perhaps he can help out. Randy has mentioned that he will give me the necessary info to write another dll but I don't want to do that. Randy has asked MikeQ not to make the source public, but he might be willing to let me modify it for the SDK but that will also mean MikeQ will have to be willing to give it to me also. If I get the source I can have states and intensities tracked and available to read and also fix the VB6 issues.


--- Quote ---But with the dll, all I know is how many devices are detected - deviceList.count. Can we assume that the device list always stores the devices in order? In my example above with id1 and id3, would id1 always come before id3 in the device list or is this dependent on the order that XP registered them?
--- End quote ---

I'm not exactly sure about this, we might need to do some testing to find out if it's just deviceList.handle[id].


--- Quote ---P.S I don't really care about the hot swap stuff for a LedWiz
--- End quote ---

Yes I don't believe hotswapping is really worth bothering about. I don't imagine people will be unplugging them while software is running.

Howard_Casto:
Hot swapping is quite impossible actually.  Can you image a panel with 32 outputs on it that would actually be small enough to remove on the fly?  ;)

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version