Add ability to terminate or suspend terminal mode #152
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds the ability for terminal mode to recognise a specific escape sequence (ESC+
#_Q!$
) to exit terminal mode and restore regular VDP operation, allowing VDU handling to resume. Exiting terminal mode changes to mode 1.Also allows terminal mode to be suspended using a different escape sequence (ESC+
#_S!$
). This allows programs running inside terminal mode to temporarily suspend terminal serial handling, allowing applications that use terminal mode to then send VDU commands. Terminal mode is resumed usingVDU 23,0,&FF
, i.e. the same command sequence to start terminal mode.When the terminal is suspended, keyboard handling is still sent terminal-style, rather than restoring to VDP protocol keyboard packets. This should allow for programs to be written in CP/M to remain interactive whilst using VDU commands for output.
This code also adds an "emergency exit" key combo to quit out of terminal mode of Ctrl+Alt+F12