maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required) (https://talk.maemo.org/showthread.php?t=62941)

No!No!No!Yes! 2010-09-25 21:37

[Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
Customize Queen BeeCon Widget (>=v1.2) to display:
GPRS Traffic Grapher
WARNING!!! Package gnuplot required; please refer to gnuplot documentation for further details
The Beecon will display a graph with the progressive consumption of Total, Received and Sent GPRS data spent over time. It will also display green, yellow, red color/icons according to % consumption of a maximum specified threshold

http://i.imgur.com/Yc9jC.png
http://i.imgur.com/YK65V.png
http://i.imgur.com/Xi578.png
  1. Install gnuplot package
    Code:

    sudo gainroot
    apt-get install gnuplot

  2. Import Beecon
    Code:

    [queen-beecon-header]
    version=1,000000
    checksum=8785092
    [queen-beecon-exported-instance]
    widgetType=0
    widgetVisible=1
    operationalStatus=0
    hideCanvas=false
    hideClickCanvas=true
    snippetBgRGB=0
    snippetExtBgRGB=#33333333ffff
    beecon_lt0_ImgZoom=0
    beecon_lt0_BgRGB=2
    beecon_lt0_ExtBgRGB=#808080808080
    beecon_lt0_ImgFilename=queen-beecon-syserr.png
    beecon_eq0_ImgZoom=13
    beecon_eq0_BgRGB=3
    beecon_eq0_ExtBgRGB=#0000ffff0000
    beecon_eq0_ImgFilename=queen-beecon-appok.png
    beecon_eq1_ImgZoom=13
    beecon_eq1_BgRGB=4
    beecon_eq1_ExtBgRGB=#ffffffff0000
    beecon_eq1_ImgFilename=queen-beecon-appwrn.png
    beecon_ge2_ImgZoom=13
    beecon_ge2_BgRGB=5
    beecon_ge2_ExtBgRGB=#ffff00000000
    beecon_ge2_ImgFilename=queen-beecon-apperr.png
    beecon_idxge2_ImgZoom=0
    beecon_idxge2_BgRGB=11
    beecon_idxge2_ExtBgRGB=#0000ffffffff
    beecon_idxge2_ImgFilename=queen-beecon-index.png
    widWidth=410
    widHeight=210
    instanceTitle=QBW GPRS Tfx Grapher
    instanceCmd=MAX=600;FROM=20100814;TO=20101013;YEL=90;RED=95;rx=$(gconftool-2 -g /system/osso/connectivity/network_type/GPRS/gprs_home_rx_bytes);tx=$(gconftool-2 -g /system/osso/connectivity/network_type/GPRS/gprs_home_tx_bytes); echo "`date '+%Y%m%d%H%M'` $tx $rx" >> /home/user/.queen_beecon_dir/qbw_gprs_grapher.dat ; echo -e "reset\\n#set style line 1 lt 1 lw 3\\nset lmargin 6\\nset bmargin 1.5\\nset rmargin 1\\nset tmargin 1.5\\nset terminal png size 400,200\\nset xdata time\\nset timefmt \\"%Y%m%d%H%M\\"\\nset output \\"/home/user/.queen_beecon_dir/qbw_gprs_grapher.png\\"\\n# time range must be in same format as data file\\nset xrange [\\"${FROM}0000\\":\\"${TO}2400\\"]\\nset yrange [0:$MAX]\\nset grid\\n#set xlabel \\"Date/Time\\"\\n#set ylabel \\"Load\\"\\n#set title \\"GPRS Grapher\\"\\nset key horiz left top outside\\nplot \\"/home/user/.queen_beecon_dir/qbw_gprs_grapher.dat\\" index 0 using 1:((\\$2+\\$3)/1048576) title \\"Tot\\" with lines lw 3, \\"/home/user/.queen_beecon_dir/qbw_gprs_grapher.dat\\" index 0 using 1:(\\$3/1048576) title \\"Rx\\" with lines lw 3, \\"/home/user/.queen_beecon_dir/qbw_gprs_grapher.dat\\" index 0 using 1:(\\$2/1048576) title \\"Tx\\" with lines lw 3" > /home/user/.queen_beecon_dir/qbw_gprs_grapher.plt; gnuplot /home/user/.queen_beecon_dir/qbw_gprs_grapher.plt;echo " `date '+%H:%M'`";pct="`expr \\( $tx + $rx \\) \\/ 1048576 \\* 100 \\/ $MAX`"; x=0; if [ $pct -gt $YEL ];then x=1;fi; if [ $pct -gt $RED ];then x=2; fi; exit $x;
    rememberMe=
    cmdImgFilename=qbw_gprs_grapher.png
    cmdImgAngle=0
    cmdImgZoom=0
    cmdFgRGB=1
    cmdExtFgRGB=#444444444444
    cmdTextAngle=0
    cmdVisibilityPosition=3
    cmdImgVisibilityPosition=5
    cmdJustify=0
    cmdExtFont=Tahoma 10
    cmdFontName=3
    cmdFontSize=12
    resImgFilename=
    resImgAngle=0
    resImgZoom=0
    resFgRGB=1
    resExtFgRGB=#00007777ffff
    resTextAngle=0
    resVisibilityPosition=1
    resImgVisibilityPosition=7
    resJustify=0
    resExtFont=Nokia Sans bold 11
    resFontName=2
    resFontSize=12
    progressAnimationFrames=4
    progressAnimationTimer=4
    progressAnimationPos=4
    progressAnimationAtClickXY=false
    progressAnimationBasename=queen-beecon-progress
    updOnStartup=false
    updOnClick=true
    updOnDesktop=true
    updOnSight=false
    delayIndex=4
    customIntervalSecs=0
    updNeworkPolicy=0
    updOnDBUS=0
    updOnDBUSBus=0
    updOnDBUSMatchRule=

  3. Edit command and customize:
    Code:

    MAX=600;FROM=20100814;TO=20101013;YEL=90;RED=95;...
    MAX = Threshold for Data Consumption (in MB)
    FROM = Display period FROM date (YYYYMMDD format)
    TO = Display period FROM date (YYYYMMDD format)
    YEL = Yellow alert % Threshold
    RED = Red alert % Threshold

  4. Beecon updates: @Interval:30min, @Click, @Desktop

  5. Beecon collects data, creates plt script for gnuplot and drops png in /home/user/.queen_beecon_dir directory

  6. Enjoy the new GNUPLOT world ...

jackjohn 2011-06-10 02:13

Re: [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
Bro,

iam getting Checksum error.

jackjohn 2011-06-10 03:29

Re: [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
Its work fine now. Anyway how to change the MRTG white color to transparent

jackjohn 2011-06-10 03:31

Re: [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
Bro,

Its work fine now. Anyway how to change the MRTG background white color to transparent

No!No!No!Yes! 2011-06-10 07:56

Re: [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
http://www.manpagez.com/info/gnuplot...nuplot_414.php

jackjohn 2011-06-11 11:10

Re: [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
Bro,

Is there any way to plot the throughput like Qnetman.

http://www.my-maemo.com/software/app...to=2265&faq=37

Robb 2011-06-11 12:00

Re: [Announce] Queen BeeCon Widget - GPRS Traffic Grapher (Package gnuplot required)
 
Great Work! Simply amazing.

How would the script look like to plot the battery charge, volts and percentage?


All times are GMT. The time now is 15:58.

vBulletin® Version 3.8.8