[PD] show "used or free system memoy" from within pd-extended (Ubuntu 8.04) -nogui - is this possible?

IOhannes m zmoelnig zmoelnig at iem.at
Fri Feb 27 14:21:39 CET 2009


Ingo Scherzinger wrote:
> Thank you IOhannes,
> 
>> something like:
>> % cat /proc/meminfo | egrep "^MemFree:" | awk '{print $2}'
>> should do the trick
>> (note that [shell] is not so good with such things; put the above (or
>> better) command in a shellscript which you run using [shell])
> 
> I tried this. But as you mentioned without a script it doesn't work because
> pd doesn't seem to accept the "{" and "}" characters.

but what's wrong with a script?
oh, and you could just omit the 3rd part with the fancy braces; in this
case you would have to parse the line yourself, e.g. using
[route MemFree:]

> 
> However by further searching the net I just found very simple command that
> works with [shell] "free". I don't know why this is not documented in my
> linux command book?

i don't know, because yout linux command book cannot list each and every
tool possibly installed on one of the flavours of linux? (or unix?)

a good ressource for finding what's available is usually man/apropos.
% apropos free | grep -i memory
gives me 24 hits, among them "free (1)"

oh, btw, i think that the output of "cat /proc/meminfo" is easier to
parse than that of "free"....

> 
> 
>>> You are probably right about that. However my system freezes in such a
>> case
>>> - no matter whether it's caused by pd or linux.
>> i do not doubt that.
>> but why did you blame Pd then? it doesn't really matter whether it's
>> caused by Obama or by linux either....
> 
> You're absolutely right about that.
>   ... it's just that I'm running pd when it happens! :(

yes, but it didn't happen 5 years ago when bush was president.
i guess it only happens since Obama became president.

mgfa.sdr
IOhannes




More information about the Pd-list mailing list