libws libws
WSwan hardware library for the Wonderful toolchain
|
#include <stdint.h>
#include <wonderful.h>
Go to the source code of this file.
Functions | |
static uint32_t | ws_ptr_to_linear (const void __far *src) |
void | ws_portcpy (uint16_t port, const void __far *src, uint16_t count) |
Copy memory data to I/O ports, in order. | |
__attribute__ ((no_assume_ds_data, no_assume_ss_data)) void ws_busywait(uint16_t us) | |
Busy wait. | |
Various utility functions for working with the WonderSwan hardware.
Definition in file util.h.
__attribute__ | ( | (no_assume_ds_data, no_assume_ss_data) | ) |
Busy wait.
This is not recommended - use only when necessary! Not halting the CPU can lead to higher power consumption. The recommended approach is configuring an interrupt handler and using cpu_halt() - which will then sleep until any interrupt occurs.
us | Approximate number of microseconds. |
void ws_portcpy | ( | uint16_t | port, |
const void __far * | src, | ||
uint16_t | count ) |
Copy memory data to I/O ports, in order.
port | Destination port. |
src | Source pointer. |
count | Count, in bytes. |