Ok. Back home again. Attached are two items:
control skeleton of attached Lua script file
entire Lua script file
Maybe the control skeleton will be enough to reveal the problem I am having. Maybe not.
If you look through the Lua script file, be aware that it still needs quite a bit of work...