sdk-world v2026.11.05
PS2 SDK - world tier (copyleft-allowed, non-essential packages)
Loading...
Searching...
No Matches
mmce_sio2.h
Go to the documentation of this file.
1
5#ifndef MMCE_SIO2_H
6#define MMCE_SIO2_H
7
8#include <tamtypes.h>
9#include <thbase.h>
10
11extern iop_sys_clock_t timeout_200ms;
12extern iop_sys_clock_t timeout_1s;
13extern iop_sys_clock_t timeout_2s;
14
15extern u8 mmce_sio2_use_alarm;
16
17int mmce_sio2_init();
18
19//Remove hooks and deinit
20void mmce_sio2_deinit();
21
22//Lock SIO2 for execlusive access
23void mmce_sio2_lock();
24
25//Unlock SIO2
26void mmce_sio2_unlock();
27
28//Assign port
29void mmce_sio2_set_port(int port);
30
31//Get currently assigned port
32int mmce_sio2_get_port();
33
34//Update PCTRL1_WAIT_CYCLES_AFTER_ACK_LOW value
35void mmce_sio2_update_ack_wait_cycles(int cycles);
36
37//Enable/disable setting alarms for transfer timeouts
38void mmce_sio2_set_use_alarm(int value);
39
40//RX TX PIO single transfer (1-256 bytes)
41int mmce_sio2_tx_rx_pio(u8 tx_size, u8 rx_size, u8 *tx_buf, u8 *rx_buf, iop_sys_clock_t *timeout);
42
43//RX DMA n * 256
44int mmce_sio2_rx_dma(u8 *buffer, u32 size);
45
46//RX DMA n * 256, PIO remainder
47int mmce_sio2_rx_mixed(u8 *buffer, u32 size);
48
49//TX DMA n * 256, PIO remainder
50int mmce_sio2_tx_mixed(u8 *buffer, u32 size);
51
52#endif