tkinter example, device class