You can perform a factory reset with the SMS Utilities <b>restore</b> rule. If the rule hasn't been disabled or changed in any way, all you need to do is send an SMS message to the {{#switch: {{{series}}} | TRB14x|TRB2xx|TRB5=gateway|#default=router}} containing the text:
Replace {{#switch: {{{series}}} | TRB14x|TRB2xx|TRB5=<i><gateway_password></i> | #default=<i><router_password></i>}} with your actual password. You can find more information on SMS Utilities rules <b>[[{{{name}}} Mobile Utilities|here]]</b>.