topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Thursday December 12, 2024, 6:58 pm
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Last post Author Topic: IDEA: an indication that "start-up" is finished  (Read 68136 times)

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 933
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #25 on: January 11, 2007, 05:19 PM »
 :) Try IdleRun v1.0!

I've added affinity to show the correct cpu usage on mutliple core/cpu systems. But I haven't got one, so please telle me if it works! Thanks f0dder!

Skrommel
« Last Edit: January 11, 2007, 08:04 PM by skrommel »

DocSavage

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 62
  • Legend in my own mind
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #26 on: January 12, 2007, 03:51 AM »
Skrommel,
I installed V 1.0 last evening on my dual processor machine & did a couple of restarts. The message appears when expected & only once. The icon shrinks to nothingness when CPU usage is lower than about 10% indicated by Win Task Manager. But the tip box still indicates negative numbers. (right now, -97% while WTM shows near 1%)
I am using these settings:
[Action]
program=winver.exe
message=
exit=1
[Settings]
cputhreshold=10
checkinterval=3
idleduration=30

dk
From believing in Santa to not believing in Santa, from being Santa to looking like Santa, I will never be younger than I am today!

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #27 on: January 12, 2007, 07:42 AM »
Hm, just tried out the app; seems like the affinitiy didn't do the trick (and it might not even be necessary with the timing call you're doing). However, the DllCall to GetSystemTimes looks pretty curious. I'm not really into AHK, but it looks strange - the times returned by GetSystemTimes are 64bit quantities, I would guess the "uint" you pass along means unsigned 32bit, and "VarSetCapacity" also indicates you're reserving 4 bytes of memory... so perhaps the GetSystemTimes call trashes some other memory?
- carpe noctem

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 933
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #28 on: January 12, 2007, 11:30 AM »
 :tellme: Have you tried Process from http://www.beyondlog...util/processutil.htm? It can set the affinity of a process.

Skrommel

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #29 on: January 12, 2007, 04:21 PM »
Setting either thread or process affinity should be enough - thread affinity is "the thing that matters", but thread affinity is masked by process affinity.

Something else must be going wrong somewhere - probably either the 32- vs 64-bit issue, or perhaps a signed/unsigned integer issue? I guess I should grab a copy of AHK and see if I can figure out something :)
- carpe noctem

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 933
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #30 on: January 17, 2007, 06:47 PM »
 :tellme: How about IdleRun v1.1?

DocSavage

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 62
  • Legend in my own mind
    • View Profile
    • Read more about this member.
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #31 on: January 17, 2007, 06:55 PM »
Skrommel,
Forgive my delay.
On my dual processor machine, I still show negative numbers at idle. I just set the settings at -90 & forgot it was not showing true numbers, it still tells me when my machine is at idle.
dk
From believing in Santa to not believing in Santa, from being Santa to looking like Santa, I will never be younger than I am today!

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,776
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #32 on: January 17, 2007, 08:31 PM »
How about IdleRun   v1.1?

Thanks for the effort.  I still see negative numbers :(

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 933
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #33 on: January 18, 2007, 11:47 AM »
 :) Anyone care to try IdleRun v1.2?

Skrommel

cranioscopical

  • Friend of the Site
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 4,776
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #34 on: January 18, 2007, 05:21 PM »
Anyone care to try IdleRun   v1.2?

I say!  I think you nailed it.  It's telling me 14%, windows task manager is saying the same.  Nice going!

jdd

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 214
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #35 on: September 29, 2008, 05:51 AM »
Skrommel,

I am was trying to use IdleRun to run an exe when the cpu goes idle.  Is this one of itss intended purposes?

When I run the script and right click on the tray icon to change the settings, it opens Notepad with an Windows error message that says "The file name, directory name or volume syntax is incorrect".

Also, I opened the script to edit it but I can't seem to figure out which linie is used to input the exe file I want to run.  Are you able to help?

I am using Windows XP Pro.

Thanks,
jdd

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #36 on: September 29, 2008, 06:10 AM »
jdd: you're not supposed to edit the script itself, but the .ini file that it creates on its first run.
It should be on the same folder as IdleRun, but should be named "IdleRun.ini", or something similar.

jdd

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 214
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #37 on: September 29, 2008, 08:36 AM »
I edited the ini file as shown below to include the the location of the program I want to run at idle.  When I run the script and right click on the tray icon to change the settings, it still opens Notepad with an Windows error message that says "The file name, directory name or volume syntax is incorrect".

Is my syntax correct?

[Action]
program=C:\Program Files\Screen Locker\matrix.exe
message=CPU is idle!
exit=1
[Settings]
cputhreshold=5
checkinterval=1
idleduration=60

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #38 on: September 29, 2008, 08:45 AM »
Now that's strange, I've never seen such error.
Maybe you could download the .exe version again and try to run it?

jdd

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 214
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #39 on: September 29, 2008, 09:13 AM »
jgpaiva,

I walked away from the computer for a few minutes and when I returned, it had executed the program I wanted.  I still cant change the settings by right clicking the tray icon though.

May I ask a follow up question?  The whole purpose of my interest is to invoke IdleRun and run a *.exe instead of the screensaver *.scr file.  Is this what will  IdleRun will do?  I haven't had enough time to test it now that it appears to be semi-functional.

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #40 on: September 29, 2008, 10:09 AM »
Yes it can, jdd.. From what I understand, that's the idea.

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 933
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #41 on: September 30, 2008, 04:23 AM »
 :) @jdd: When you first run IdleRun, it creates an ini-file next to the program. This file is edited using the tray menu, but you have to restart IdleRun to invoke the changes (lazy, I know).

cputhreshold=5 is the max load of the CPU.
checkinterval=1 is how often to check tha CPU load.
idleduration=60 is how long the CPU load must be below the threshold.

To run a program using the screensaver, have you tried RunSaver?

Skrommel

jdd

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 214
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #42 on: October 12, 2008, 08:00 PM »
skrommel,

This is a great little program.  I have another small request.  I would like to add another line to the ini file with the purpose indicated below.  I don't know the proper syntax so I have explained its purpose in the fourth line which I called "new item".

cputhreshold=5 is the max load of the CPU.
checkinterval=1 is how often to check tha CPU load.
idleduration=60 is how long the CPU load must be below the threshold
new item = require that any key on the keypad must be touched be touched AFTER the idleduration requirement is fulfilled, but BEFORE the *.exe program is executed.

Thanks,
jdd

jgpaiva

  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #43 on: October 16, 2008, 12:56 PM »
jdd: Do you mean make it wait for a press of a keypad key and then run the executable?

jdd

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 214
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #44 on: October 16, 2008, 09:34 PM »
Yes.

skrommel

  • Fastest code in the west
  • Developer
  • Joined in 2005
  • ***
  • Posts: 933
    • View Profile
    • 1 Hour Software by skrommel
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #45 on: October 18, 2008, 01:01 PM »
 :) Replace the CHECKCPULOAD procedure in IdleRun with the code below.

Skrommel

CHECKCPULOAD:
load:=GETCPULOAD(numberofprocessors)
icon:=load/100*9
Menu,Tray,Tip,%load% `%
IfExist,%icon%.ico
  Menu,Tray,Icon,%icon%.ico
If load>%cputhreshold%
If A_TimeIdlePhysical>=%idleduration%
{
  If program<>
  {
    Input,singlekey,L1,{LControl}{RControl}{LAlt}{RAlt}{LShift}{RShift}{LWin}{RWin}{AppsKey}{F1}{F2}{F3}{F4}{F5}{F6}{F7}{F8}{F9}{F10}{F11}{F12}{Left}{Right}{Up}{Down}{Home}{End}{PgUp}{PgDn}{Del}{Ins}{BS}{Capslock}{Numlock}{PrintScreen}{Pause}
    Run,%program%
  }
  If message<>
    MsgBox,0,%applicationname%,%message%
  If exit=1
    Goto,EXIT
}
Return


jdd

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 214
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #46 on: October 19, 2008, 08:12 AM »
Perfect!  Thank You.   :Thmbsup:

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 40,914
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Read more about this member.
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #47 on: October 21, 2008, 04:08 AM »
Cool stuff...
Skrommel are you updating these things on your web page too?

MilesAhead

  • Supporting Member
  • Joined in 2009
  • **
  • Posts: 7,736
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #48 on: January 25, 2009, 02:11 PM »
I've been trying to find an Idle launcher that takes hard drive activity into account.  I haven't found one yet.  Esp. on Vista the stupid explorer or other background tasks can decide they want to scan the drive for 20 minutes so it's not the time to launch a defragger. :)

I've been trying to find stuff about idle detection but about all I've run across is some white paper about the disk driver interacting with power saver policy yadda yadda.  Seems like some of these defraggers that defrag in the background should be detecting it somehow.  Any clues where I could look if I wanted to take a shot at it?

cealdrighi

  • Participant
  • Joined in 2009
  • *
  • default avatar
  • Posts: 3
    • View Profile
    • Donate to Member
Re: IDEA: an indication that "start-up" is finished
« Reply #49 on: November 08, 2009, 07:46 PM »
In first place, thanks a lot for your tools, I use'pushmonitoroff' as THE solution to assign a code-key to shut off monitor over my IR control remote. its very handfull.

I am looking for an app wich switches on the fly my windows xp 'power management''s profiles when the cpu turns idle or not idle, I mean:

- when cpu is idle (less than 30%) for 5 minutes turn power mgt to  * 0 - Home/Office desktop  (no need for warns);
- when cpu is not idle (more than 30%)  for 5 minutes turn power mgt to * 5 - Optimized for power saving (no need for warns);

could you figure out if I can apply that on 'cpuidle' ? do you know any app capable of it?

It will be handfull to automate turn on/off asus' cool and quite feature - so I will not need to switch manually everytime I load a heavy app or game, or when I load off these apps.

I really don't know if I can request something here, but anyway its just and idea ok?

thanks in advance and regards mate!

« Last Edit: November 08, 2009, 07:53 PM by cealdrighi »