updating RTI code and adding v2