This approach removes the burden from any simulator code to perform instruction execution postlude before calling sim_process_event and prelude activites when sim_process_event returns.
Remote Console commands are now executed from the same simulator context as if entered from the initial sim> prompt.
- Accept input comments
- Allow leading and trailing spaces in remote console input commands
- Force prompt to be "sim> " or "SIM> " when in a master mode console session. "SIM> " used during single command mode.
- Enhance performance of single command mode input processing by processing all available input characters before actually flushing output buffers
TMXR API extension to add tmxr_input_pending_ln that reports the existence of additional input data
TMXR also now conforms to revised sim_sock API changes
John Kichury revived Startrek II running under DCC Basic which originally ran on the Digital Computer Controls (DCC) D-116 DG Nova clone
This program (or the Basic interpreter) requires console input with even parity.
SET TTI EVEN
will now enable that.
This capability will allow a GDB RSB stub to be created to support dynamic debugging of code running in a simulator.
This capability will also allow a complete front panel emulation system to operate a simulator.
This capability is engaged in a simulator by:
sim> set remote telnet=remoteconsoleport#
sim> set console telnet=consoleport#
sim> set remote master
Master mode will provide a TCP session which accepts SCP commands that allow full control of the simulator.
Ideas based on Dave Bryan's console halt efforts.
sim> SEND {<mux>:line} {DELAY=n,}"string"
Where <mux> is the name of the device pointed to by the TMXR structure. If <mux>:line isn't specified, then the console device is implicitly being referenced.
Delay is optional and once set persists for subsequent SEND operations to the same device. Delay defaults to 1000. The DELAY value is a minimum number of instructions which must execute before the next character in the provided string will be injected to the console port. The DELAY value has effect between the characters delivered as well. "string" requires quotes and within the quoted string, common C escape character syntax is available (\r\r\t, etc.).
Each device (console, and each line in each mux) has a separate value for DELAY.
An arbitrary number of 'expect' conditions can be defined. The command syntax is:
sim> EXPECT {<mux>:line} {[cnt]} "matchstring" {actioncommand {; actioncommand ...}}
Where <mux> is the name of the device pointed to by the TMXR structure. If <mux>:line isn't specified, then the console device is implicitly being referenced.
"matchstring" requires quotes and within the quoted string, common C escape character syntax is available (\r\r\t, etc.). The quotes used can be single or double quotes, but the closing quote must match the opening quote. The match string might be extended to allow the use of perl style regular expressions in the "matchstring" when a -R switch is specified on the command line.
sim> EXPECT "Enter Color: " SEND "Red\r"; g
A specific 'expect' condition can be removed with:
sim> NOEXPECT {<mux>:line} "matchstring"
All 'expect' conditions can be removed with:
sim> NOEXPECT {<mux>:line}
'expect' conditions can be examined with:
sim> SHOW EXPECT {<mux>:line}
Expect rules are one-shots (i.e. they disappear once a match has occurred) unless they are explicitly described as persistent with the -P switch.
The -C switch is available when defining expect rules. The effect of a rule defined with the -C flag is that when an expect match occurs for that rule, ALL rules are cleared for that device (console or <mux>:line).
We're not absolutely sure that all of the changes are correct - in particular the treatment of record marks in add/compare - but they do make the diagnostics pass, which they didn't before.
Bob asked for variable tab stops on the typewriter, and those are implemented as well. The routines were general enough that I put the SET/SHOW processors in sim_console.c, so I'm enclosing that and its header file.
Conflicts:
I1620/i1620_cpu.c
sim_console.c
sim_console.h
- Avoid assignments of void * values. Cast all memory allocation return values to appropriate types.
- Add output to sim_log where missing in various places.
- Fixed issue with lost file positions after a restore for devices which leverage the UNIT_SEQ flag.
sim> set debug -r -a -t -p somefile
-a produces seconds.msec time format
-t produces hh:mm:ss.msec time format
-r causes time values displayed to be relative to the wall clock time when the 'set debug' command was issued
-r by itself will cause default of -t
-a and -t can both be specified if desired
-p adds display of current PC value to the debug timestamp output
sim> show debug