Using keyboard LCD for "Message>"

Hints, tips and tricks for newbies

Moderators: Dorian (MJT support), JRL

Post Reply
sfurneaux
Newbie
Posts: 9
Joined: Sat May 09, 2009 2:18 pm

Using keyboard LCD for "Message>"

Post by sfurneaux » Fri Jul 09, 2010 2:42 pm

Hi,

On my mission to send simple status messages to my G15 LCD display while a script is running I've come across the Logitech API in their SDK, along with its documentation.

The DLL is called lglcdapi.dll and according to the SDK manual the first thing that you need to do is initialise with:
lgLcdInit

The lgLcdInit() function initializes the Logitech LCD library. You must call this function prior to any other function of the library.

DWORD WINAPI lgLcdInit(void);

Parameters
None

Return Values
If the function succeeds, the return value is ERROR_SUCCESS.
...
So, I've simply written these 2 lines:

Code: Select all

LibLoad>c:\LgLcdAPI.dll,lcd
LibFunc>lcd,lgLcdInit,T
and I get "Unable to load DLL" :(

I'm such a noob... can anyone point me in the right direction? I'm prepared to persevere but disappointed that I can't even get past this first basic step!

Thanks.
Last edited by sfurneaux on Sat Jul 24, 2010 8:25 am, edited 1 time in total.

gdyvig
Automation Wizard
Posts: 447
Joined: Fri Jun 27, 2008 7:57 pm
Location: Seattle, WA

Post by gdyvig » Fri Jul 09, 2010 9:49 pm

Hi sfurneaux,

The answer may be here:
http://www.mjtnet.com/usergroup/viewtop ... ht=libload

This problem was reported for dlls created with vb.net, which are not supported. The link offers some workarounds.

Gale

sfurneaux
Newbie
Posts: 9
Joined: Sat May 09, 2009 2:18 pm

Post by sfurneaux » Sat Jul 10, 2010 7:57 pm

Gale,

Thanks for the pointer.

My research continues... :)

sfurneaux
Newbie
Posts: 9
Joined: Sat May 09, 2009 2:18 pm

Post by sfurneaux » Mon Jul 12, 2010 3:00 pm

Just FYI, I'm looking into Microsoft SideShow for this functionality now. Seems to be a good avenue to go down since they publish the API for native DLLs and the operating system handles the hardware interfacing itself.

So I might be able to post messages directly from MS or I might need/want to build a simple gadget (with or without a UI, depending).

I'm hoping I'll eventually be able to pass messages from my macro to the LCD (to show variable values, timers or status messages) or even use the soft keys to change the operation of the macro in flight.

I'll post my progress here.

Cheers :wink:

sfurneaux
Newbie
Posts: 9
Joined: Sat May 09, 2009 2:18 pm

Post by sfurneaux » Sun Jul 18, 2010 2:46 pm

(Just thought I'd post an update)

Using the Microsoft.SideShow DLL rather than the Logitech DLL was a better idea as there's a lot of useful info on MSDN and this way it's much more generic so any SideShow compatible display will work.

I modify the contents of a text file at key points in my script then I've got a very simple application running that, when called from within MS, displays the contents of the first 2 lines as "glance" text on the LCD display. This provides the same functionality for which I was using "Message>" but without having the popup on my main screen. :D

My next mission is to teach myself how to do this with the native API with C++ rather than the managed C# code that I've used, then perhaps I can do without the need for the text file and use return codes to control the operation of the macro. (I'm thinking, use the buttons on the SideShow device to pause/exit the macro, jump to a Label etc).

It's a steep learning curve for me but it's onwards and upwards!

Steve

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts