X-Git-Url: http://git.rot13.org/?p=goodfet;a=blobdiff_plain;f=client%2FGoodFETGlitch.py;h=56f30754290675c0b5390b420235d451837a4e8f;hp=99241079953754de0c703f77a3a1ac15f8a888ff;hb=1f8e984b38e60a3b2aa0609864f05250cc8df673;hpb=11043432e6e4a058a219abd492b46cc644f35329 diff --git a/client/GoodFETGlitch.py b/client/GoodFETGlitch.py index 9924107..56f3075 100644 --- a/client/GoodFETGlitch.py +++ b/client/GoodFETGlitch.py @@ -38,7 +38,7 @@ title "Success", \ class GoodFETGlitch(GoodFET): def __init__(self, *args, **kargs): - print "Initializing GoodFET Glitcher." + print "# Initializing GoodFET Glitcher." #Database connection w/ 30 second timeout. self.db=sqlite3.connect("glitch.db",30000); @@ -146,7 +146,18 @@ class GoodFETGlitch(GoodFET): g('set term png'); g('set output "timevcc.png"'); g(script_timevcc); - + def points(self): + c=self.db.cursor(); + c.execute("select time,vcc,gnd,glitchcount,count from glitches where lock=0 and count>0;"); + print "time vcc gnd glitchcount count"; + for r in c: + print "%i %i %i %i %i" % r; + def npoints(self): + c=self.db.cursor(); + c.execute("select time,vcc,gnd,glitchcount,count from glitches where lock=0 and count=0;"); + print "time vcc gnd glitchcount count"; + for r in c: + print "%i %i %i %i %i" % r; #GnuPlot sucks for large sets. Switch to viewpoints soon. # sqlite3 glitch.db "select time,vcc,count from glitches where count=0" | vp -l -d "|" -I