Our new official repo is on github
LCD Smartie version 5.6 is released!
Download it now: https://github.com/LCD-Smartie/LCDSmartie/releases

dll refresh interval

Discussing issues that occur during plugin development.

Moderators: _X7JAY7X_, caesar, IFR, mattcro, limbo

Post Reply
rektifier
Posts: 1
Joined: March 20th, 2005, 11:49 am

dll refresh interval

Post by rektifier »

hi everybody! how can I get lcd smartie refresh my dll not as often as it does now? i want it to refresh every 5 min or so.

/mike

limbo
Plugin Author
Posts: 1604
Joined: February 13th, 2005, 7:38 pm
Location: Athens - Greece
Contact:

Post by limbo »

U can use the Getrefreshinterval function
See http://lcdsmartie.sourceforge.net/plugins.html...

Also read the "Warning" at the end of the page

hurley
Posts: 46
Joined: May 26th, 2011, 8:03 am

Re: dll refresh interval

Post by hurley »

I know this is an old thread but..

I'm writing a plugin for which I'd like my users to be able to set the dll refresh interval in a parameter.

I've tried to pass an integer from function1 to GetMinRefreshInterval() method, but it seams to not work.

Is it possible to do this or does LCDsmartie process GetMinRefreshInterval() before the function method?

Thanks for any help. hurley.

limbo
Plugin Author
Posts: 1604
Joined: February 13th, 2005, 7:38 pm
Location: Athens - Greece
Contact:

Re: dll refresh interval

Post by limbo »

I think that it is not supported.
I tried in the past a couple of methods to pass a different time using the refresh interval but the program code seems to check this value only once on the dll load... :?
Maybe it can be altered a bit in a future version of the program but we have to check the stability as well. :D

limbo
Plugin Author
Posts: 1604
Joined: February 13th, 2005, 7:38 pm
Location: Athens - Greece
Contact:

Re: dll refresh interval

Post by limbo »

I think that it is not supported.
I tried in the past a couple of methods to pass a different time using the refresh interval but the program code seems to check this value only once on the dll load... :?
Maybe it can be altered a bit in a future version of the program but we have to check the stability as well. :D

hurley
Posts: 46
Joined: May 26th, 2011, 8:03 am

Re: dll refresh interval

Post by hurley »

Yes it looks that way. I tried a couple of tricks too without success.
No worries, thanks for your help limbo.

dperrow
Plugin Author
Posts: 276
Joined: May 27th, 2011, 2:13 pm
Location: Stirling, Scotland

Re: dll refresh interval

Post by dperrow »

would reading the value from an ini file from the getrefreshinterval function be good enough?

you could possibly check for a change in the ini file value from each dll function call and restart lcdsmartie if it changes?

hurley
Posts: 46
Joined: May 26th, 2011, 8:03 am

Re: dll refresh interval

Post by hurley »

hmm, good thinking dperrow.

I've been thinking about using an ini for user configurable fonts but it didn't occur to me to use one for refresh.

Not as slick as changing a parameter, but an ini should work for refresh interval and at least then users could configure to suit their requirements.

I might try this after I'm done with 0.1.2 of CoreTemp plugin since 0.1.3 will need an ini too.

Cheers :)

hurley
Posts: 46
Joined: May 26th, 2011, 8:03 am

Re: dll refresh interval

Post by hurley »

Well it worked perfectly.

Actually the GetMinRefreshInterval() method makes a great entry point for plugin specific configuration, since it's only called once & before any function() methods.

Looks like we might have turned an issue into a bonus here.

Thanks for the idea dperrow!!

dperrow
Plugin Author
Posts: 276
Joined: May 27th, 2011, 2:13 pm
Location: Stirling, Scotland

Re: dll refresh interval

Post by dperrow »

Actually,
there's a SmartieInit() function for this purpose. That's where I read in my ini file for the MCE_dll. I then stick the values in some global variables but hey, if it works don't fix it!

Glad to be of help,

Dave

Post Reply