+ } else if(!strncmp(queryName, "Rcmd,",4)) {
+ // Rcmd uses the wrong separator
+ char *separator = strstr(packet, ","), *params = "";
+ if(separator == NULL) {
+ separator = packet + strlen(packet);
+ } else {
+ params = separator + 1;
+ }
+
+
+ if (!strncmp(params,"7265",4)) {// resume
+#ifdef DEBUG
+ printf("Rcmd: resume\n");
+#endif
+ stlink_run(sl);
+
+ reply = strdup("OK");
+ } else if (!strncmp(params,"6861",4)) { //half
+ reply = strdup("OK");
+
+ stlink_force_debug(sl);
+
+#ifdef DEBUG
+ printf("Rcmd: halt\n");
+#endif
+ } else if (!strncmp(params,"7265",4)) { //reset
+ reply = strdup("OK");
+
+ stlink_force_debug(sl);
+ stlink_reset(sl);
+ init_code_breakpoints(sl);
+ init_data_watchpoints(sl);
+
+#ifdef DEBUG
+ printf("Rcmd: reset\n");
+#endif
+ } else {
+#ifdef DEBUG
+ printf("Rcmd: %s\n", params);
+#endif
+
+ }
+