Main > Software Forum

LEDWiz SDK v1.3 Released for developers

<< < (6/6)

headkaze:
It's a shame MikeQ has seemed to disappear, he is no longer answering my e-mails or PM's. I thought MikeQ wouldn't give the source for the dll because Randy didn't want him to, but this is not the case aparently. The ideal solution would be to have the LED states tracked by the dll in a static area of the dll that all applications can access through the dll. You can then just read or set the states with an exported function. Writing a server application will not only slow things down, but require a lot of hard work to write.

The thing is, there dosn't seem to be an awful lot of demand for a solution that supports multiple access to the LEDWiz hardware. I think in general people are happy to have support in their FE, or in some cases they may need a sort of global solution like Howards Mame Hooker application. This basically covers most scenarios I can think of right now.

loadman:
It's on my list to use this.  I really do have a list   ;)

loadman:

--- Quote from: arzoo on March 16, 2007, 11:20:19 pm ---Loadman,
Since the com control accepted the PBA command as a string of comma separated values, I wrote this function to convert the string to a byte array. Just makes it a bit easier to convert from the com to the dll.
--- End quote ---

This was a great idea and I have utilised it for the Led-Wiz Plug-in to use the Dll. Your idea of using that function made sense as I could easily convert the existing code very easily so this allows me to release two versions (Ocx and DLL)  ...

AnyWay........ I do have a question.

As your function Worked so well I decided to make another one for SBA as well.  I have it working but I don't understand why I could not use the 'addr' command for my one?...

Not that it really matters as I got around it (as you can see) but it does puzzle me  :dizzy:

Anyway below you see how I call both these functions  PBA and SBA..


--- Code: ---procedure SendCommand(Device: Integer; Command: string);
// If PBA Command (eg:PBA:48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48)
Begin
if LeftStr(command,4)='PBA:' then
begin
  command := Rightstr(command,Length(command)-4);
  if ConvertPBAString(command,brightness) then
  LWZ_PBA(Device,addr(brightness[0])); // **THIS WORKS GREAT ****
end;

// If SBA Command  (eg:  SBA:255,255,255,255 )
if LeftStr(command,4)='SBA:' then
Begin
  command := Rightstr(command,Length(command)-4); //take SBA element away
  if ConvertSBAString(command,status) then
// LWZ_SBA(Device,addr(status[0]),2);  // ***WHY DOESN'T THIS WORK*****
   LWZ_SBA(Device,status[0],status[1],status[2],status[3],2);
end;
[\code]

--- End code ---

arzoo:

--- Quote from: loadman on April 29, 2007, 07:05:22 am ---AnyWay........ I do have a question.

As your function Worked so well I decided to make another one for SBA as well.  I have it working but I don't understand why I could not use the 'addr' command for my one?...

Not that it really matters as I got around it (as you can see) but it does puzzle me  :dizzy:


--- End quote ---
For some reason, Mike did not code the LWZ_SBA function to accept an array - rather, as you have discovered, you need to pass each of the 4 banks.


--- Code: ---  TLWZ_SBA = Procedure(device: LWZHANDLE; bank0, bank1, bank2, bank3: Cardinal; globalPulseSpeed: Cardinal) cdecl;
--- End code ---

By the way, I also wrote a ConvertSBAString function  ;D

loadman:

--- Quote from: arzoo on May 03, 2007, 08:19:04 am ---
--- Quote from: loadman on April 29, 2007, 07:05:22 am ---AnyWay........ I do have a question.

As your function Worked so well I decided to make another one for SBA as well.  I have it working but I don't understand why I could not use the 'addr' command for my one?...

Not that it really matters as I got around it (as you can see) but it does puzzle me  :dizzy:


--- End quote ---
For some reason, Mike did not code the LWZ_SBA function to accept an array - rather, as you have discovered, you need to pass each of the 4 banks.

--- End quote ---

Thanks   :D

.... If I knew what I was doing I would have worked out that Mike's Dll did not accept an array on that command myself  :banghead:

Navigation

[0] Message Index

[*] Previous page

Go to full version