| View previous topic :: View next topic |
| Author |
Message |
Stewie87
Joined: 03 Apr 2008 Posts: 39
|
Posted: Sun Jun 15, 2008 8:52 am Post subject: Request for a technical opinion about a plugin project... |
|
|
Hi to all, I have a question: is there any function that allows me to get the CPU usage percentage (or however CPU usage value)?
Because I gave a quick research to pspsdk but I didn't find it :(
Or, in alternative, exists a simple way to "calculate" it?
Thanks to all for attention and sorry for my bad english ;)
EDIT: function found, now:
| Quote: | Oki, I post here to avoid another topic :)
I have an idea but I'm not very "technical" about CPU frequency and use... so I would appreciate your opinion ^^
My idea is to make a plugin that "take" the CPU usage and set CPU frequency depending it! A CPU setting "on demand" xD
For example: CPU is on 222Mhz and the CPU usage is under 50%... so plugin set CPU frequency on 111Mhz. If CPU usage goes above 80 or 90% plugin set CPU frequency on 222Mhz back. And so on...
Well, this is my idea (in few words) :)
I ask you if this idea has sense (so if this is possible...) but especially if this method is dangerous for CPU (and PSP) life...
Thanks to all ^_^ |
Last edited by Stewie87 on Sun Jun 15, 2008 10:21 am; edited 2 times in total |
|
| Back to top |
|
 |
Pirata Nervo
Joined: 09 Oct 2007 Posts: 409
|
|
| Back to top |
|
 |
whistler
Joined: 04 Mar 2008 Posts: 40
|
Posted: Sun Jun 15, 2008 9:27 am Post subject: |
|
|
grep is your friend:)
grep Cpu /usr/local/pspdev/psp/sdk/include/*.h
that should list all the functions with cpu in the name. as for getting a usage percentage, i'm not sure there's a function for that |
|
| Back to top |
|
 |
Stewie87
Joined: 03 Apr 2008 Posts: 39
|
Posted: Sun Jun 15, 2008 9:41 am Post subject: |
|
|
I know those functions, but I ask for a function that gives me the CPU usage and not the frequency... |
|
| Back to top |
|
 |
Insert_witty_name
Joined: 10 May 2006 Posts: 376
|
|
| Back to top |
|
 |
Stewie87
Joined: 03 Apr 2008 Posts: 39
|
Posted: Sun Jun 15, 2008 9:56 am Post subject: |
|
|
Lol, I searched for "CPU usage" and so that topic did not appear :P
Thank you very very much ^__^ |
|
| Back to top |
|
 |
Stewie87
Joined: 03 Apr 2008 Posts: 39
|
Posted: Sun Jun 15, 2008 10:08 am Post subject: |
|
|
Oki, I post here to avoid another topic :)
I have an idea but I'm not very "technical" about CPU frequency and use... so I would appreciate your opinion ^^
My idea is to make a plugin that "take" the CPU usage and set CPU frequency depending it! A CPU setting "on demand" xD
For example: CPU is on 222Mhz and the CPU usage is under 50%... so plugin set CPU frequency on 111Mhz. If CPU usage goes above 80 or 90% plugin set CPU frequency on 222Mhz back. And so on...
Well, this is my idea (in few words) :)
I ask you if this idea has sense (so if this is possible...) but especially if this method is dangerous for CPU (and PSP) life...
Thanks to all ^_^ |
|
| Back to top |
|
 |
Pirata Nervo
Joined: 09 Oct 2007 Posts: 409
|
Posted: Sun Jun 15, 2008 6:43 pm Post subject: |
|
|
@Stewie oh I misunderstood then, I see you edited your post explaining exactly what you want :p _________________
Upgrade your PSP |
|
| Back to top |
|
 |
whistler
Joined: 04 Mar 2008 Posts: 40
|
Posted: Mon Jun 16, 2008 12:00 am Post subject: |
|
|
| Stewie87 wrote: | Oki, I post here to avoid another topic :)
I have an idea but I'm not very "technical" about CPU frequency and use... so I would appreciate your opinion ^^
My idea is to make a plugin that "take" the CPU usage and set CPU frequency depending it! A CPU setting "on demand" xD
For example: CPU is on 222Mhz and the CPU usage is under 50%... so plugin set CPU frequency on 111Mhz. If CPU usage goes above 80 or 90% plugin set CPU frequency on 222Mhz back. And so on...
Well, this is my idea (in few words) :)
I ask you if this idea has sense (so if this is possible...) but especially if this method is dangerous for CPU (and PSP) life...
Thanks to all ^_^ |
its a good idea but its already been done. in cwcheat set the cpu frequency to -1 and the plugin will dynamically adjust the cpu frequency in relation to the cpu load |
|
| Back to top |
|
 |
Stewie87
Joined: 03 Apr 2008 Posts: 39
|
Posted: Mon Jun 16, 2008 12:14 am Post subject: |
|
|
| whistler wrote: | | Stewie87 wrote: | Oki, I post here to avoid another topic :)
I have an idea but I'm not very "technical" about CPU frequency and use... so I would appreciate your opinion ^^
My idea is to make a plugin that "take" the CPU usage and set CPU frequency depending it! A CPU setting "on demand" xD
For example: CPU is on 222Mhz and the CPU usage is under 50%... so plugin set CPU frequency on 111Mhz. If CPU usage goes above 80 or 90% plugin set CPU frequency on 222Mhz back. And so on...
Well, this is my idea (in few words) :)
I ask you if this idea has sense (so if this is possible...) but especially if this method is dangerous for CPU (and PSP) life...
Thanks to all ^_^ |
its a good idea but its already been done. in cwcheat set the cpu frequency to -1 and the plugin will dynamically adjust the cpu frequency in relation to the cpu load |
Really?! o.O
Well at least my was a good idea xD
Weltall, what algorithm do you use to calculate CPU usage? That suggested by insert_winny don't work in a VSH plugin... |
|
| Back to top |
|
 |
|