Ajout de graphs en pourcentage pour une meilleure lecture des quantites
d'encres restantes. darcs-hash:20061017004127-9e428-dd8342baa721dc67198d8bb4578f0361a62af28f.gz
This commit is contained in:
parent
49985807f9
commit
9ec8576784
1 changed files with 26 additions and 2 deletions
|
@ -8,6 +8,7 @@ import hptools
|
|||
|
||||
dico_courbes_gen = {
|
||||
'car' : {'titre' : "Etat des cartouches",
|
||||
'vlabel' : "nb de pages restantes",
|
||||
'lower-limit' : 0,
|
||||
'upper-limit' : 30000,
|
||||
'dico' : {
|
||||
|
@ -15,8 +16,19 @@ dico_courbes_gen = {
|
|||
'car_cya' : ("enterprises.11.2.3.9.4.2.1.4.1.10.5.1.1.2.0","Cartouche cyan","00ffff"),
|
||||
'car_mag' : ("enterprises.11.2.3.9.4.2.1.4.1.10.5.1.1.3.0","Cartouche magenta","ff00ff"),
|
||||
'car_yel' : ("enterprises.11.2.3.9.4.2.1.4.1.10.5.1.1.4.0","Cartouche jaune","ffff00")
|
||||
}},
|
||||
'car-p' : {'titre' : "Etat des cartouches",
|
||||
'vlabel' : "pourcentage restant",
|
||||
'lower-limit' : 0,
|
||||
'upper-limit' : 100,
|
||||
'dico' : {
|
||||
'car_p_bla' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.18.1.0","Cartouche noir","000000"),
|
||||
'car_p_cya' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.18.2.0","Cartouche cyan","00ffff"),
|
||||
'car_p_mag' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.18.3.0","Cartouche magenta","ff00ff"),
|
||||
'car_p_yel' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.18.4.0","Cartouche jaune","ffff00")
|
||||
}},
|
||||
'tam' : {'titre' : "Etat des tambours",
|
||||
'vlabel' : "nb de pages restantes",
|
||||
'lower-limit' : 0,
|
||||
'upper-limit' : 40000,
|
||||
'dico' : {
|
||||
|
@ -25,7 +37,18 @@ dico_courbes_gen = {
|
|||
'tam_mag' : ("enterprises.11.2.3.9.4.2.1.4.1.10.5.1.1.7.0","Tambour d'imagerie magenta","ff00ff"),
|
||||
'tam_yel' : ("enterprises.11.2.3.9.4.2.1.4.1.10.5.1.1.8.0","Tambour d'imagerie jaune","ffff00"),
|
||||
}},
|
||||
'tam-p' : {'titre' : "Etat des tambours",
|
||||
'vlabel' : "Pourcentage restant",
|
||||
'lower-limit' : 0,
|
||||
'upper-limit' : 100,
|
||||
'dico' : {
|
||||
'tam_p_bla' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.37.5.0","Tambour d'imagerie noir","000000"),
|
||||
'tam_p_cya' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.37.6.0","Tambour d'imagerie cyan","00ffff"),
|
||||
'tam_p_mag' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.37.7.0","Tambour d'imagerie magenta","ff00ff"),
|
||||
'tam_p_yel' : ("enterprises.11.2.3.9.4.2.1.4.1.10.1.1.37.8.0","Tambour d'imagerie jaune","ffff00"),
|
||||
}},
|
||||
'kit' : {'titre' : "Etat des kits images",
|
||||
'vlabel' : "nb de pages restantes",
|
||||
'lower-limit' : 0,
|
||||
'upper-limit' : 150000,
|
||||
'dico' : {
|
||||
|
@ -39,6 +62,7 @@ dico_courbes_gen = {
|
|||
arg = sys.argv[0].split('_')[1]
|
||||
dico_courbes = dico_courbes_gen[arg]['dico']
|
||||
titre = dico_courbes_gen[arg]['titre']
|
||||
vlabel = dico_courbes_gen[arg]['vlabel']
|
||||
lower_limit = dico_courbes_gen[arg]['lower-limit']
|
||||
upper_limit = dico_courbes_gen[arg]['upper-limit']
|
||||
#########
|
||||
|
@ -51,9 +75,9 @@ except :
|
|||
if arg == "config" :
|
||||
print 'host_name laserjet'
|
||||
print 'graph_category consommables'
|
||||
print "graph_args --base 1000 --lower-limit %i --upper-limit %i" % (lower_limit,upper_limit)
|
||||
print "graph_args --lower-limit %i --upper-limit %i" % (lower_limit,upper_limit)
|
||||
print 'graph_title %s' % titre
|
||||
print "graph_vlabel nb de pages restantes"
|
||||
print "graph_vlabel %s" % vlabel
|
||||
for fieldname in dico_courbes.keys():
|
||||
#print "%s.draw LINE2" % fieldname
|
||||
print "%s.label %s" % (fieldname,dico_courbes[fieldname][1])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue