New pages
From WSdev Wiki
Jump to navigationJump to search
- 16:39, 20 October 2024 WonderWitch/FreyaBIOS/System (hist | edit) [549 bytes] Asie (talk | contribs) (Created page with "The System interrupt provides assorted system-related functionality. == Types == === Suspend/resume structure === This structure is stored in SRAM block 3, offset <code>$7E00</code> (core 1) and <code>$BF00</code> (core 0). {| class="wikitable" |- ! Offset !! Size !! Contents |- | $0000 || 16384 || Copy of RAM area <code>$0000</code> - <code>$3FFF</code> |- | $4000 || 2 || Stack segment? |- | $4002 || 2 || Data segment? |- | $4004 || 224 || Copy of IO ports <code>$00...")
- 19:13, 19 October 2024 WonderWitch/Memory map (hist | edit) [3,182 bytes] Asie (talk | contribs) (Created page with "== Memory map == {| class="wikitable" |+ WonderWitch memory map ! Address ! ASCII, 1 screen ! ASCII, 2 screens ! Shift-JIS, 1 screen ! Shift-JIS, 2 screens |- | style="text-align: center;" | 0x0000 | colspan="4" style="text-align: center;" | Interrupt vectors |- | style="text-align: center;" | 0x0100 | colspan="4" style="text-align: center;" | ? |- | style="text-align: center;" | 0x0E00 | rowspan="7" style="text-align: center;" | | rowspan="5" style="text-align: center;...")
- 12:51, 19 October 2024 WonderWitch/IL/IlibIL (hist | edit) [591 bytes] Asie (talk | contribs) (Created page with "IlibIL is a library used to load other indirect libraries present on the system. == Functions == === open === <code>int open(const char far *name, IL far *buffer);</code> Load the specified IL <code>name</code> from <code>/rom0</code> or <code>/kern</code>. The IL header is copied to the provided <code>buffer</code> with addresses appropriately relocated to match the IL's location in ROM. === open_system === <code>int open_system(const char far *name, IL far *buffe...")
- 12:01, 19 October 2024 WonderWitch/IL/ResumeIL (hist | edit) [456 bytes] Asie (talk | contribs) (Created page with "== ResumeIL == ResumeIL is a library which augments the process suspend/resume functionality of the built-in ProcIL library to also archive the memory areas <code>0x4000 - 0xBFFF</code> (WSC expanded/4bpp tile memory) and <code>0xFE00 - 0xFFFF</code> (WSC palette memory). This is done by copying this memory to <code>/ram0/resume.dat</code>. === Limitations === - This approach only allows suspending and resuming one process.")
- 11:19, 19 October 2024 WonderWitch/FreyaBIOS/Timer (hist | edit) [1,837 bytes] Asie (talk | contribs) (Created page with "The Timer interrupt provides an abstraction layer for the WonderSwan's timers, as well as the on-cartridge RTC. == Types == === RTC fields === The RTC field indexes match the order of fields returned by the RTC chip. Note that FreyaBIOS transparently converts the values to and from BCD. {| class="wikitable" |- ! Index !! Data !! Format |- | 0 || Year || 0 - 99; 0 is assumed to be the year 2000. |- | 1 || Month || 1 - 12 |- | 2 || Date...")
- 18:02, 18 October 2024 WonderWitch/Process (hist | edit) [2,531 bytes] Asie (talk | contribs) (Created page with "== Memory layout == Process memory is stored in SRAM banks 3 (process 0 - typically used by FreyaOS), 2 (process 1) and 1 (process 2). The entire bank is available to the process. === Process control block === The process control block contains information about the running process. It is stored in the first 96 bytes of data. {| class="wikitable" |+ Process control block structure |- ! Offset !! Length !! Contents |- | 0 || 4 || Compiler ID, zero-terminated string; s...")
- 15:53, 18 October 2024 WonderWitch/IL (hist | edit) [2,441 bytes] Asie (talk | contribs) (Created page with "Indirect libraries (IL) are a FreyaOS feature designed to work around the 64KB segment limit of applications by offloading helper functionality to separate library binaries. == Calling convention == All functions exposed by an IL use the standard 8086 C calling convention - cdecl. * The stack is allocated and cleaned by the caller. * <code>AX</code>, <code>BX</code>, <code>CX</code>, <code>DX</code> can be modified freely by the callee. All other registers must be res...")
- 14:21, 17 October 2024 WonderWitch/Filesystem (hist | edit) [1,507 bytes] Asie (talk | contribs) (Created page with "== Mount points == {| class="wikitable" |+ FreyaOS mount points |- ! Path !! File data location !! File table location !! File table size (entries) !! Description |- | <code>/rom0</code> || ROM (384 KB) || SRAM bank 3, $16F2 || 128 || |- | <code>/ram0</code> || SRAM bank 0 (64 KB) || SRAM bank 3, $06F2 || 64 || |- | <code>/</code> || || SRAM bank 3, $02F2 || 16 || |} == File table entry format == {| class="wikitable" |+ Header contents |- ! Offset !! Length !! Conten...")
- 07:57, 15 August 2024 NEC V30MZ interrupts (hist | edit) [1,561 bytes] Asie (talk | contribs) (Created page with "The NEC V30MZ provides six of the eight interrupts provided by the 80186. == Interrupts == === INT 0 - Divide Error === This interrupt is emitted as the result of a DIV<sup>IDIV</sup> or DIVU<sup>DIV</sup> instruction. === INT 1 - Single Step/Break === This interrupt is emitted if the single step flag is set after executing an instruction. (The instruction which changed the single step flag is ignored.) The single step flag is cleared for the duration of the interru...")
- 09:36, 5 August 2024 NEC V30MZ registers (hist | edit) [2,116 bytes] Asie (talk | contribs) (Created page with "= NEC V30MZ registers = * Four 16-bit general-purpose registers, with their (low, high) components accessible as individual 8-bit sub-registers: ** '''AX'''<sup>AW</sup> ('''AL''', '''AH''') - the ''accumulator'' register, ** '''BX'''<sup>BW</sup> ('''BL''', '''BH''') - the ''base'' register, ** '''CX'''<sup>CW</sup> ('''CL''', '''CH''') - the ''count'' register, ** '''DX'''<sup>DW</sup> ('''DL''', '''DH''') - the ''data'' register, * Four additional 16-bit registers: *...")
- 09:36, 5 August 2024 NEC V30MZ flags (hist | edit) [2,326 bytes] Asie (talk | contribs) (Created page with " = NEC V30MZ flags = == Layout == The V30MZ processor features a 16-bit flag register: 15 bit 8 7 bit 0 ---- ---- ---- ---- m111 odit sz0a 0p1c | |||| || | | | | |||| || | | +- Carry (CF<sup>CY</sup>) | |||| || | +--- Parity (PF<sup>P</sup>) | |||| || +------ Auxillary Carry (AF<sup>AC</sup>) | |||| |+-------- Zero (Z) | |||| +--------- Sign (S) | |||+------------ Single Step<sup>Break</sup> (TF<sup>BRK</sup>)...")
- 20:37, 30 July 2024 WonderWitch/FreyaBIOS/Bank (hist | edit) [1,885 bytes] Asie (talk | contribs) (Created page with "The Bank interrupt provides an abstraction layer for accessing the WonderWitch cartridge's flash and RAM. == Interrupts == === INT $18/AH=$00 - bank_set_map === * AH = $00 * BX = Bank region * CX = Number of bank to map to region Bank regions: * 0 = SRAM (1000:xxxx) * 1 = ROM0 (2000:xxxx) * 2 = ROM1 (3000:xxxx) === INT $18/AH=$01 - bank_get_map === * AH = $01 * BX = Bank region Return: * AX = Number of bank mapped to region === INT $18/AH=$02 - bank_read_byte =...")
- 13:42, 27 July 2024 WonderWitch/FreyaBIOS/Communication (hist | edit) [2,160 bytes] Asie (talk | contribs) (Created page with "The Communication (comm) interrupt provides an abstraction layer and helpers for the WonderSwan's serial port. == Interrupts == === INT $14/AH=$00 - comm_open === * AH = $00 Opens the serial port. Note that the baud rate must be set before calling <code>comm_open</code>. === INT $14/AH=$01 - comm_close === * AH = $01 Closes the serial port. === INT $14/AH=$02 - comm_send_char === * AH = $02 * BL = Character (byte) to send. Return: * AX = Return code....")
- 08:34, 27 July 2024 WonderWitch/FreyaBIOS/Text (hist | edit) [4,571 bytes] Asie (talk | contribs) (Created page with "The Text interrupt provides a text output display using one of the WonderSwan's screens. == Interrupts == === INT $13/AH=$00 - text_screen_init === * AH = $00 Initializes a text window (see INT $13/AH=$01) with the following default settings: * X, Y = 0, 0 * width, height = 28, 18 * starting tile = 512 - font tile count (in ASCII mode) * starting tile = 512 - (width x height) (in Shift-JIS and mixed modes) === INT $13/AH=$01 - text_window_init === * AH = $01 * BL...")
- 16:08, 24 July 2024 WonderWitch/FreyaBIOS/Key (hist | edit) [1,213 bytes] Asie (talk | contribs) (Created page with "The Display interrupt provides helper functions for accessing the WonderSwan's keypad. == Interrupts == === INT $11/AH=$00 - key_press_check === * AH = $00 Return: * AX = A bitmask containing the currently held keys. <pre> 15 bit 8 7 bit 0 ---- ---- ---- ---- .... 4321 4321 bas. |||| |||| ||| |||| |||| ||+- Start |||| |||| |+-- A |||| |||| +--- B |||| ++++----- X1/X2/X3/X4 ++++----------- Y1/Y2/Y3/Y4 </pr...")
- 20:27, 23 July 2024 WonderWitch/FreyaBIOS/Display (hist | edit) [6,741 bytes] Asie (talk | contribs) (Created page with "The Display interrupt provides an abstraction layer and helpers for the WonderSwan's display hardware. Note that features specific to the WonderSwan Color are implemented using libwwc, which is linked statically with the user program and thus not part of the BIOS call surface. == Interrupts == === INT $12/AH=$00 - display_control === * AH = $00 * BX = Display Control value === INT $12/AH=$01 - display_st...")