Typical, just when you ask a question, you get it to work. Following suggestions from https://www.raspberrypi.org/forums/viewtopic.php?t=60088
The problem appears to be that you are trying to connect an X client
to the X display of a different user, and it does not have the correct
I tried running the script without root privileges (...