- /* Clear all input so only command relative output is displayed */
- slurp_input();
-
- switch(islower(args[0]) ? toupper(args[0]) : args[0]) {
- default:
- printf_filtered("Unknown/Unimplemented adapt command '%s'\n",args);
- break;
- case 'G': /* Go, begin execution */
- write(adapt_desc,args,strlen(args));
- write(adapt_desc,"\r",1);
- expect_prompt();
- break;
- case 'B': /* Break points, B or BR */
- case 'C': /* Check current 29k status (running/halted) */
- case 'D': /* Display data/registers */
- case 'I': /* Input from i/o space */
- case 'J': /* Jam an instruction */
- case 'K': /* Kill, stop execution */
- case 'L': /* Disassemble */
- case 'O': /* Output to i/o space */
- case 'T': /* Trace */
- case 'P': /* Pulse an input line */
- case 'X': /* Examine special purpose registers */
- case 'Z': /* Display trace buffer */
- write(adapt_desc,args,strlen(args));
- write(adapt_desc,"\r",1);
- expect(args); /* Don't display the command */
- display_until("# ");
- break;
- /* Begin commands that take input in the form 'c x,y[,z...]' */
- case 'S': /* Set memory or register */
- if (strchr(args,',')) { /* Assume it is properly formatted */
- write(adapt_desc,args,strlen(args));
- write(adapt_desc,"\r",1);
- expect_prompt();
- }
- break;
+ switch (islower (args[0]) ? toupper (args[0]) : args[0])
+ {
+ default:
+ printf_filtered ("Unknown/Unimplemented adapt command '%s'\n", args);
+ break;
+ case 'G': /* Go, begin execution */
+ write (adapt_desc, args, strlen (args));
+ write (adapt_desc, "\r", 1);
+ expect_prompt ();
+ break;
+ case 'B': /* Break points, B or BR */
+ case 'C': /* Check current 29k status (running/halted) */
+ case 'D': /* Display data/registers */
+ case 'I': /* Input from i/o space */
+ case 'J': /* Jam an instruction */
+ case 'K': /* Kill, stop execution */
+ case 'L': /* Disassemble */
+ case 'O': /* Output to i/o space */
+ case 'T': /* Trace */
+ case 'P': /* Pulse an input line */
+ case 'X': /* Examine special purpose registers */
+ case 'Z': /* Display trace buffer */
+ write (adapt_desc, args, strlen (args));
+ write (adapt_desc, "\r", 1);
+ expect (args); /* Don't display the command */
+ display_until ("# ");
+ break;
+ /* Begin commands that take input in the form 'c x,y[,z...]' */
+ case 'S': /* Set memory or register */
+ if (strchr (args, ','))
+ { /* Assume it is properly formatted */
+ write (adapt_desc, args, strlen (args));
+ write (adapt_desc, "\r", 1);
+ expect_prompt ();