X-Git-Url: https://git.llucax.com/z.facultad/66.09/etherled.git/blobdiff_plain/113ca660652d693a5cd06c258e8fed2104d9fff0..3f85b3197c02a63c0f7f057c0d92a3c98a98fdb7:/cliente/cetherled.py?ds=inline diff --git a/cliente/cetherled.py b/cliente/cetherled.py index 936d9b7..c242769 100755 --- a/cliente/cetherled.py +++ b/cliente/cetherled.py @@ -28,7 +28,7 @@ import os import gtk from simplegladeapp import SimpleGladeApp from simplegladeapp import bindtextdomain -from dispatcher import Dispatcher +#from dispatcher import Dispatcher from led import Led import etherled @@ -63,6 +63,13 @@ class MainWindow(SimpleGladeApp): def on_btn_enviar_clicked(self, widget, *args): self.device.matrix = self.leds2matrix() + def on_btn_recibir_clicked(self, widget, *args): + matrix = self.device.matrix + for row in xrange(16): + for col in xrange(16): + self.tabla[row,col].prendido = matrix[row,col] + etherled.protocol._print_matrix(matrix) + def on_main_window_delete_event(self, widget, event, *args): self.quit() @@ -71,10 +78,6 @@ class MainWindow(SimpleGladeApp): for row in xrange(16): for col in xrange(16): matrix[row,col] = int(self.tabla[row,col].prendido) - #print int(self.tabla[row,col].prendido), - print (row,col), - print - print etherled.protocol._print_matrix(matrix) return matrix