Skip to content

Conversation

@davidrg
Copy link
Owner

@davidrg davidrg commented Nov 21, 2025

Right now it should correctly compute the VT420 checksum for any region of the display that the host has written to completely. If any cells in the DECRQCRA region are erased, then the checksum will be incorrect as erased cells should not be included. Additionally, colour information is not currently included in the checksum - that still needs to be done too. And lastly, the checksum is only valid for the latin1 charset - for other VT420/520 charsets further work will need to be done.

So, still to be done:

  • Exclude erased cells from the checksum (this will require K95 to track erased cells)
  • Support VT525 colour in the checksum
  • When page 0 is specified, compute a checksum of all pages
  • Support all of the other VT420/525 charsets beyond latin1 (optional - there isn't really any practical value in doing it, but it would be nice to be able to say DECRQCRA is complete and never have to revisit it in the future).
  • Might be nice to describe the algorithm in the control sequences manual too.

Right now it should correctly compute the checksum for any region of the display that the host has written to completely. If any cells in the DECRQCRA region are erased, then the checksum will be incorrect as erased cells should not be included.

Additionally, colour information is not currently included in the checksum - that still needs to be done too.

And lastly, the checksum is only valid for the latin1 charset - for other VT420/520 charsets further work will need to be done.
@davidrg davidrg linked an issue Nov 21, 2025 that may be closed by this pull request
This is required for DECCARA and DECRARA which do not affect erased cells when in stream mode, and also by DECRQCRA which excludes erased cells from the checksum.

As it's only the three VT420 control sequences that pay attention to whether a cell is in the erased state or not, this change hasn't been fully rolled out to other emulations which all ignore this attribute and may or may not always clear it appropriately when a cell is written. Mostly its the protected field stuff that may still need further work.
It wasn't checking that the character specified was within the valid range, and it wasn't translating from the currently selected remote character set to the local one. When in UTF-8, no translation is applied and the entire base multilingual plane is allowed.

Also adjusted DECERA so that it only erases non-erased cells.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

DECRQCRA improvements

2 participants