[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: nlist() and MiNT itself.



>>PS. If you're wondering what info I'm trying to find.. I've added uptime and
>>load averages to my version of MiNT 1.09 (I'll post the diffs once I know
>>it's working properly). At the moment the only way I can see the
>>loadaverages is to press ctrl-alt-F6.. it's a right pain.
>
>Why don't you implement a system call (say Sloadavg()) to retrieve the
>information?  This method has the advantage of not requiring read
>permission on any special files.

Good thinking Batman!

And Uptime could be Suptime() I suppose.

So as to be source compatable with Unix there'd have to be a routine called
getloadavg() added to the library for the load.. I'm not sure if thet IS a
standard way to get the uptime.

It would be nice if we could use nlist() to look into the kernel though, it
should help to get a proper ps etc. working.

It's facinating what you find when you read /proc/MiNT.000.. it's a pity
it's not MiNT itself!

>--
>entropy -- it's not just a good idea, it's the second law.
>Personal mail:      entropy@gnu.ai.mit.edu
>MiNT library mail:  entropy@terminator.rs.itd.umich.edu

Steve

-- 
---------------------------------------------------------------------------
Computer Systems Administrator, Dept. of Earth Sciences, Oxford University.
E-Mail: steve@uk.ac.ox.earth (JANET) steve@earth.ox.ac.uk (Internet).
Tel:- Oxford (0865) 282110 (UK) or +44 865 282110 (International).