Notices


Reply
Thread Tools
HumanPenguin's Avatar
Posts: 270 | Thanked: 170 times | Joined on Jul 2007 @ Atlanta, GA + Oxford UK
#11
Originally Posted by biggzy View Post
Thanx guys, that was what i wanted.
You can also change the size of the widget with a slider in settings. IE all that extra space in noobmonkeys screenshot is the default size of the widget you can shorten it and reduce the space taken. Very nice little widget by all acounts.
 
biggzy's Avatar
Posts: 547 | Thanked: 461 times | Joined on Aug 2009 @ UK
#12
iv also got some free memory widgets (rootfs, mass mem and mem card), is there any command to use so i can have 1 showing free RAM? thanx



Command to show free mass memory: df -h | awk ' $1 == "/dev/mmcblk0p1" {print $4"B"}'

Command to show free memory on mem card: df -h | awk ' $1 == "/dev/mmcblk1p1" {print $4"B"}'
__________________
Nokia N900 - It's what computers have become.
My Web Site
Twitter

Last edited by biggzy; 2010-03-09 at 13:55.
 

The Following User Says Thank You to biggzy For This Useful Post:
noobmonkey's Avatar
Posts: 3,203 | Thanked: 1,391 times | Joined on Nov 2009 @ Worthing, England
#13
Originally Posted by HumanPenguin View Post
You can also change the size of the widget with a slider in settings. IE all that extra space in noobmonkeys screenshot is the default size of the widget you can shorten it and reduce the space taken. Very nice little widget by all acounts.
hehe i just have it that size to match the others - removed it now because i don't need the date - thats what my watch is for

Tis very customisable though
__________________
----------- Follow me on Twitter here
----------- My Photography Website and Blog is here
----------- Author of the N900 Health Check Application ----------- New Version in Extras Devel (Dec 2010 - 2.9.10)
----------- Are you on the N900 World Map? - http://pininthemap.com/maemo - masterpin: shotgun
----------- What apps do you want to see on the n900 or in MeeGo in the future? -
 
HumanPenguin's Avatar
Posts: 270 | Thanked: 170 times | Joined on Jul 2007 @ Atlanta, GA + Oxford UK
#14
well there are a few ways to get free memory. the most useful for this widget would be

head -n 2 /proc/meminfo | tail -n 1

this will give you free mem in one line.

More informative is the command free that will give you more info on how it is allocated.

the command I gave is chopping one line out of the meminfo file. from an xterm type

cat /proc/meminfo

To see it all.

the field I have taken above is memfree. But I do not think that is very useful due to the way linux uses memory. Someone who knows more about the linux memory model nay be able to provide more useful info.
 

The Following 2 Users Say Thank You to HumanPenguin For This Useful Post:
amorek13's Avatar
Posts: 245 | Thanked: 32 times | Joined on Oct 2009 @ CT USA
#15
would there be a command that could pull time form world clock so it could display on desktop using the desktop widget?
 
biggzy's Avatar
Posts: 547 | Thanked: 461 times | Joined on Aug 2009 @ UK
#16
Originally Posted by HumanPenguin View Post
well there are a few ways to get free memory. the most useful for this widget would be

head -n 2 /proc/meminfo | tail -n 1

this will give you free mem in one line.
Thanx, works a treat, but is there anyway to show it without it displaying the words 'MemFree:' so it only displays the actual free ram in kb/mb and no text, thanx again.
__________________
Nokia N900 - It's what computers have become.
My Web Site
Twitter
 
HumanPenguin's Avatar
Posts: 270 | Thanked: 170 times | Joined on Jul 2007 @ Atlanta, GA + Oxford UK
#17
yes but you will have to let me get to my home PC (very late UK time tonight.) To play with it.

If someone else comes up with it meanwhile cool.

Work PC is windows so cant really experiment much.
 
HumanPenguin's Avatar
Posts: 270 | Thanked: 170 times | Joined on Jul 2007 @ Atlanta, GA + Oxford UK
#18
not the most elegent solution but it should work.

head -n 2 /proc/meminfo | tail -n 1 | fold -w 15 | tail -n 1

Basically we are cutting the line in half and selecting only the second half. This would be simpler with regular expressions but Id have to remind my self how to use all that again. Someone will prolly post with a easier solution.
 

The Following User Says Thank You to HumanPenguin For This Useful Post:
HumanPenguin's Avatar
Posts: 270 | Thanked: 170 times | Joined on Jul 2007 @ Atlanta, GA + Oxford UK
#19
Originally Posted by amorek13 View Post
would there be a command that could pull time form world clock so it could display on desktop using the desktop widget?
Yes but you will need wget to be installed. (command line tool to pull in data over the web.)

this would give you a number of other useful features so I will look into it.

Point me to the site you would like the world clock info to come from and I will play tonight.

At some point I will look into writting my own widgets. But I think ill wait for the QT update in the UK. This way it will last through meego etc.
 

The Following 2 Users Say Thank You to HumanPenguin For This Useful Post:
afaq's Avatar
Posts: 1,038 | Thanked: 1,408 times | Joined on Feb 2010 @ London
#20
Ive tried the command for the date in the widget and i get an "invalid command" error on my widget.

i checked and i copied it correctly. anyone know what i could be doing wrong?
 
Reply


 
Forum Jump


All times are GMT. The time now is 03:06.