script works - bugfixes from testing the script on the hardware, documentation updates