libnile
Loading...
Searching...
No Matches
core.h File Reference
#include <wonderful.h>
#include "hardware.h"
#include <stdbool.h>
#include <stdint.h>

Go to the source code of this file.

Functions

void nile_bank_clear_mask (void)
 Adjust banking registers and clear NILE_SEG_MASK.
void nile_bank_unlock (void)
 Adjust banking registers and unlock NILE_SEG_MASK RAM/ROM0/ROM1.
void nile_bank_lock (void)
 Re-lock NILE_SEG_MASK RAM/ROM0/ROM1.
static void nile_io_unlock (void)
 Unlock nileswan-exclusive registers.
void nile_soft_reset (void)
 Jump back to cartridge IPL0 (soft reset).

Function Documentation

◆ nile_bank_clear_mask()

void nile_bank_clear_mask ( void )

Adjust banking registers and clear NILE_SEG_MASK.

Note that if executing from ROML, this is only guaranteed safe for >=1MB cartridge images, due to the linear address.

◆ nile_bank_lock()

void nile_bank_lock ( void )

Re-lock NILE_SEG_MASK RAM/ROM0/ROM1.

◆ nile_bank_unlock()

void nile_bank_unlock ( void )

Adjust banking registers and unlock NILE_SEG_MASK RAM/ROM0/ROM1.

This variant is safe for <1MB cartridge images.

◆ nile_io_unlock()

void nile_io_unlock ( void )
inlinestatic

Unlock nileswan-exclusive registers.

Definition at line 56 of file core.h.

◆ nile_soft_reset()

void nile_soft_reset ( void )

Jump back to cartridge IPL0 (soft reset).