To kill it, issue tim.deinit()
http://docs.micropython.org/en/latest/e ... Timer.html
As for feeding it, I think you're talking about watchdog timers (WDT)
http://docs.micropython.org/en/latest/e ... e.WDT.html. You created a virtual timer and issued mode=Timer.PERIODIC which will cause it to run until deinit() is called (or a software reset is issued).
"If I repeat the code, I get ANOTHER timer!! "
Well that's how Python works
Each time you call a constructor an object is created. Say I have a class MyClass and issue the following:
Code: Select all
a = MyClass()
a.bamboozle() # call some method
a = MyClass()
A second instance of MyClass is created and assigned to a. The first instance is "out of scope": it cannot now be accessed and will eventually be garbage collected. However this may not apply to virtual timer objects: I don't know the implementation but it's possible that an underlying object reference still exists causing them to live on indefinitely. I would issue deinit before letting a virtual timer go out of scope.