SRT function now uses registers