0

I'm trying to implement a visualisation for IoT project using Tkinker Canvas Widget.

enter image description here

What I'm not trying to do is making an animation using something like this:

def animate(self):
    self.__draw_one_frame()
    self.master.after(120, self.animate())

And:

mainloop()

To run the animation.

What I am trying to do is making synchronous request and update on the widget, like this:

  1. draw() method is run externally
  2. Canvas is updated with new animation

I've had really hard time doing this, and I would really appreciate some hints or somebody telling me that it cannot be done with Tkinker and recommending me some other library.

Thanks in advance.

ZbyszekKr
  • 512
  • 4
  • 15

1 Answers1

0

I found a solution over here: Solution

Apparently there is a method root.update() which refreshes the canvas on demand.

Community
  • 1
  • 1
ZbyszekKr
  • 512
  • 4
  • 15