Brendan wrote: There is also no calling convention, and you decide where each routine's entry point expects to find input parameters and leaves output parameters. People that don't understand these differences end up writing bad code (code restricted by limitations that exist for compiler generated code but don't exist in assembly).
To clarify: a calling convention is, from the perspective of assembly language, exactly that: a protocol that is used to make communication between procedures easier. While they are often needed in assembly code that is to be called from high-level languages, for straightforward assembly code that does not present an outside interface, they aren't necessary.
This does not mean they aren't useful at all in assembly; if you stick to a calling convention - of which there are often several for a given CPU type - then using your code as a library is easier. However, that's simply a matter of convenience to the user of an API, and even then there is some wiggle room as long as all the calling code is in assembly. The key here is not to blindly follow a set rulebook, but to document the interfaces in detail. A calling convention saves you the trouble of doing this, but as Brendan said, it can come at a cost of inefficiencies in the code. You have to weigh the tradeoffs.
Brendan wrote:For the code I posted (and the code you posted) there's no support for:
Again, to clarify: the example code Brendan gave (as I understand it) does only one thing, namely, it copies a series of bytes to alternating bytes at a specific point in the video text buffer. The features he lists are all things you will need to implement yourself, which in turn will mean understanding how the video text buffer works. The wiki has a number of relevant pages on the subject:
At the very least, implementing a cursor will require a pointer variable holding the current writing position in the text buffer. However, the text buffers themselves are just sets of linear glyph-attribute pairs; there are no inherent concepts of 'row', 'column', 'newline', 'advancing', 'scrolling', and so forth. All of these things are features you will need to implement in code and in data structures of your own choosing.