PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
padInit.c File Reference
#include "types.h"
#include "freepad.h"
#include "stdio.h"
#include "thevent.h"
#include "thbase.h"
#include "intrman.h"
#include "vblank.h"
#include "sifman.h"
#include "sio2Cmds.h"
#include "sysmem.h"
#include "padData.h"
+ Include dependency graph for padInit.c:

Go to the source code of this file.

Functions

u32 sif_buffer[4] __attribute__ ((aligned(4)))
 
static void TransferThread (void *arg)
 
u32 padSetupEEButtonData (u32 port, u32 slot, padState_t *pstate)
 
static void DmaSendEE (void)
 
static u32 GetThreadsStatus (padState_t *state)
 
static void DeleteThreads (padState_t *state)
 
static void MainThread (void *arg)
 
s32 VbReferThreadStatus (vblankData_t *vData)
 
int VblankStart (void *arg)
 
int VblankEnd (void *arg)
 
s32 padInit (void *ee_addr)
 

Variables

int pad_port
 
int pad_slot
 
u32 mainThreadCount2
 
u32 pad_portdata [2]
 
padState_t padState [2][4]
 
u32 openSlots [2]
 
vblankData_t vblankData
 
int padman_init
 
void * pad_ee_addr
 
int thpri_hi
 
int thpri_lo
 
SifDmaTransfer_t sifdma_td [9]
 
int vblank_end = 0
 
u32 frame_count = 0
 
int sifdma_id = 0
 
u32 vblankStartCount = 0
 
s32 mainThreadCount = 0
 

Detailed Description

IOP pad driver

Definition in file padInit.c.

Function Documentation

◆ __attribute__()

u32 sif_buffer[4] __attribute__ ( (aligned(4))  )

Definition at line 1 of file pvrdrv.h.

◆ TransferThread()

static void TransferThread ( void *  arg)
static

Definition at line 48 of file padInit.c.

◆ padSetupEEButtonData()

u32 padSetupEEButtonData ( u32  port,
u32  slot,
padState_t pstate 
)

Definition at line 60 of file padInit.c.

◆ DmaSendEE()

static void DmaSendEE ( void  )
static

Definition at line 250 of file padInit.c.

◆ GetThreadsStatus()

static u32 GetThreadsStatus ( padState_t state)
static

Definition at line 385 of file padInit.c.

◆ DeleteThreads()

static void DeleteThreads ( padState_t state)
static

Definition at line 426 of file padInit.c.

◆ MainThread()

static void MainThread ( void *  arg)
static

Definition at line 436 of file padInit.c.

◆ VbReferThreadStatus()

s32 VbReferThreadStatus ( vblankData_t vData)

Definition at line 624 of file padInit.c.

◆ VblankStart()

int VblankStart ( void *  arg)

Definition at line 644 of file padInit.c.

◆ VblankEnd()

int VblankEnd ( void *  arg)

Definition at line 669 of file padInit.c.

◆ padInit()

s32 padInit ( void *  ee_addr)

Definition at line 677 of file padInit.c.

Variable Documentation

◆ pad_port

int pad_port

Definition at line 27 of file padInit.c.

◆ pad_slot

int pad_slot

Definition at line 28 of file padInit.c.

◆ mainThreadCount2

u32 mainThreadCount2

Definition at line 29 of file padInit.c.

◆ pad_portdata

u32 pad_portdata[2]

Definition at line 30 of file padInit.c.

◆ padState

padState_t padState[2][4]

Definition at line 33 of file padInit.c.

◆ openSlots

u32 openSlots[2]

Definition at line 34 of file padInit.c.

◆ vblankData

vblankData_t vblankData

Definition at line 35 of file padInit.c.

◆ padman_init

int padman_init

Definition at line 36 of file padInit.c.

◆ pad_ee_addr

void* pad_ee_addr

Definition at line 37 of file padInit.c.

◆ thpri_hi

int thpri_hi

Definition at line 38 of file padInit.c.

◆ thpri_lo

int thpri_lo

Definition at line 39 of file padInit.c.

◆ sifdma_td

SifDmaTransfer_t sifdma_td[9]

Definition at line 40 of file padInit.c.

◆ vblank_end

int vblank_end = 0

Definition at line 42 of file padInit.c.

◆ frame_count

u32 frame_count = 0

Definition at line 43 of file padInit.c.

◆ sifdma_id

int sifdma_id = 0

Definition at line 44 of file padInit.c.

◆ vblankStartCount

u32 vblankStartCount = 0

Definition at line 45 of file padInit.c.

◆ mainThreadCount

s32 mainThreadCount = 0

Definition at line 46 of file padInit.c.