Trying to write non blocking code, failing

Here:

you are not updating the timestamp.

If you write functions instead of putting everything in loop(), you can make static variables all named the same, instead of coming up with a thousand names for global variables. Remember to declare constants as const, it'll save some memory.