Difference between revisions of "OSWRCR"
m (1 revision) |
m (Added 68000.) |
||
(2 intermediate revisions by one other user not shown) | |||
Line 5: | Line 5: | ||
==Specification== | ==Specification== | ||
{| cellpadding="0" cellspacing="0" | {| cellpadding="0" cellspacing="0" | ||
− | | | + | | 6502 || Z80 || 6809 || PDP11 || 80x86 || 32016 || ARM || 68000 || RISC-V || align="left" | '''On entry:''' || align="left" | '''On exit:''' |
|- align="center" valign="top" | |- align="center" valign="top" | ||
− | | A || A || A || R0 || AL || R1 || R0 || align="left" | || align="left" | = &0D | + | | A || A || A || R0 || AL || R1 || R0 || D0 || A0 || align="left" | || align="left" | = &0D |
|} | |} | ||
Line 26: | Line 26: | ||
* 80x86 Entry Address: &FFEC from BBC BASIC | * 80x86 Entry Address: &FFEC from BBC BASIC | ||
* 32000 Entry Address: none | * 32000 Entry Address: none | ||
− | * | + | * PDP11 Entry Address: MOV #&0D,R0:EMT &04 |
* ARM Entry Address: SWI &10D "OS_WriteI"+13 | * ARM Entry Address: SWI &10D "OS_WriteI"+13 | ||
+ | * 68000 Entry Address: MOV #&10D,A0:TRAP 12 | ||
+ | * RISC-V Entry Address: MOV #&0D,A0:ECALL &AC0004 | ||
==Implementations== | ==Implementations== | ||
Although undocumented, the code at the entry point exists in the 6502 and Z80 MOS | Although undocumented, the code at the entry point exists in the 6502 and Z80 MOS | ||
and the 80x86 BASIC runtime due to the way the entry code is written. BBC BASIC | and the 80x86 BASIC runtime due to the way the entry code is written. BBC BASIC | ||
− | on other platforms | + | on other platforms does not emulate this entry point. |
-- [[User:Beardo|beardo]] 00:53, 14 June 2007 (BST) | -- [[User:Beardo|beardo]] 00:53, 14 June 2007 (BST) |
Latest revision as of 20:36, 17 September 2023
An unofficial entry point to the MOS that sends a carriage return to the current output stream(s).
Specification
6502 | Z80 | 6809 | PDP11 | 80x86 | 32016 | ARM | 68000 | RISC-V | On entry: | On exit: |
A | A | A | R0 | AL | R1 | R0 | D0 | A0 | = &0D |
Prints an ASCII carriage return (CR) via OSWRCH to the currently selected output stream(s). This is an undocumented system call and is platform dependent.
Compare with OSNEWL, an official call to print a newline sequence.
Calling from BBC BASIC
- BASIC does not call OSWRCR
Entry points
- BBC BASIC Entry Address: none
- 6502 Entry Address: &FFEC
- Z80 Entry Address: &FFEC
- 6809 Entry Address: &FFEC
- 80x86 Entry Address: &FFEC from BBC BASIC
- 32000 Entry Address: none
- PDP11 Entry Address: MOV #&0D,R0:EMT &04
- ARM Entry Address: SWI &10D "OS_WriteI"+13
- 68000 Entry Address: MOV #&10D,A0:TRAP 12
- RISC-V Entry Address: MOV #&0D,A0:ECALL &AC0004
Implementations
Although undocumented, the code at the entry point exists in the 6502 and Z80 MOS and the 80x86 BASIC runtime due to the way the entry code is written. BBC BASIC on other platforms does not emulate this entry point.
-- beardo 00:53, 14 June 2007 (BST)