ST register is not hardcoded into template file anymore. This will make it easier to add new registers, I hope.