+//! Start normally, not JTAG.
+void jtag430_stop(){
+ debugstr("Exiting JTAG.");
+ jtagsetup();
+
+ //Known-good starting position.
+ //Might be unnecessary.
+ //SETTST;
+ CLRTST;
+ SETRST;
+ delay(0xFFFF);
+
+ //Entry sequence from Page 67 of SLAU265A for 4-wire MSP430 JTAG
+ CLRRST;
+ delay(0xFFFF);
+ SETRST;
+ //P5DIR&=~RST;
+ //delay(0xFFFF);
+
+}
+