Thank you for answer, but at the same time I have to confess myself I am mostly embedded so I am closer to assembler and ANSI C but not to the OOP
This is my first apk in OOP (Python) and target is RaspberryPi4, I write and test code on PC Python, then just transfering file to RPi.
I think I feel what you write about threading - probably different priority of different piece of code. Like interrupts in embedded.
My code now looks like this:
mycode executed repeatedly is here
Now looking at my code I am horrified: Would this calling its own function make stack pointer to overflow in time? I think it is also called “RAM leaking” ? (this on_timer() is inside the only one class I have)
I had before something like this (I had to find it again, it looks really to be this):
But this was only running on PC and on RPi it was crashing!? So I abandoned threading.
Can you pls give me a direction what to do where to find a good explanation how can I make “stupid” loop in time intervals?