I understand your problem. It's a very good problem to ask about. And I think KM is a great tool to solve this. I can imagine a few different solutions, but for discussion purposes let me just describe the simplest solution.
Step 1. Every five minutes a macro will be triggered and take a screen snapshot and put it into a clipboard. If two consecutive images match more than 99% of their image, we "take action" (see Step 2.)
Step 2: "Take action" could mean something like "write a big black rectangle on the monitor" using the KM action "Custom HTML Prompt." I have used this action a couple of times, and I seem to recall it has a means for naming which monitor it gets displayed to.
I think I can see this being doable in only 4 actions. Is this enough to get you started?
Bear in mind there may be some apps that do not allow their data to be saved by a screencapture. They might have a copy protection restriction.
You've got the fuzz bar on the wrong end. But you also are searching for "the screen" in "the screen". So that should always return TRUE. What you should do is save the screen into a clipboard every few minutes and then see if you can find the clipboard in the screen. If you do, then it's time for the screen saver, (but if you don't, you should probably placed the current screen into the same clipboard. This step is optional.)
Basically, here's what I would do:
Trigger a macro every 5 minutes, which will:
(a) check if the saved clipboard is found in the screen;
(b) if it is found, then start your chosen solution (which could be writing a black box to the iMac screen)
(c) if not found, then do nothing, but probably it's best to save the current screen into your saved clipboard.
I'm willing to write this if you can't figure it out, but figuring it out is half the fun, so you may like trying to write it.