PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
sior.h File Reference
#include <stdarg.h>
#include <irx.h>
#include <sior-common.h>
+ Include dependency graph for sior.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define sior_IMPORTS_start   DECLARE_IMPORT_TABLE(sior, 1, 1)
 
#define sior_IMPORTS_end   END_IMPORT_TABLE
 
#define I_sio_init   DECLARE_IMPORT(4, sio_init)
 
#define I_sio_putc   DECLARE_IMPORT(5, sio_putc)
 
#define I_sio_getc   DECLARE_IMPORT(6, sio_getc)
 
#define I_sio_getc_block   DECLARE_IMPORT(7, sio_getc_block)
 
#define I_sio_write   DECLARE_IMPORT(8, sio_write)
 
#define I_sio_read   DECLARE_IMPORT(9, sio_read)
 
#define I_sio_puts   DECLARE_IMPORT(10, sio_puts)
 
#define I_sio_putsn   DECLARE_IMPORT(11, sio_putsn)
 
#define I_sio_gets   DECLARE_IMPORT(12, sio_gets)
 
#define I_sio_flush   DECLARE_IMPORT(13, sio_flush)
 
#define I_sio_printf   DECLARE_IMPORT(14, sio_printf)
 
#define I_sio_vprintf   DECLARE_IMPORT(15, sio_vprintf)
 

Functions

void sio_init (u32 baudrate, u8 lcr_ueps, u8 lcr_upen, u8 lcr_usbl, u8 lcr_umode)
 
int sio_putc (int c)
 
int sio_getc (void)
 
int sio_getc_block (void)
 
size_t sio_write (const char *buf, size_t size)
 
size_t sio_read (char *buf, size_t size)
 
int sio_puts (const char *str)
 
int sio_putsn (const char *str)
 
char * sio_gets (char *str)
 
void sio_flush (void)
 
int sio_printf (const char *format,...)
 
int sio_vprintf (const char *format, va_list)
 

Detailed Description

IOP-side SIO remote service.

Definition in file sior.h.

Macro Definition Documentation

◆ sior_IMPORTS_start

#define sior_IMPORTS_start   DECLARE_IMPORT_TABLE(sior, 1, 1)

Definition at line 45 of file sior.h.

◆ sior_IMPORTS_end

#define sior_IMPORTS_end   END_IMPORT_TABLE

Definition at line 46 of file sior.h.

◆ I_sio_init

#define I_sio_init   DECLARE_IMPORT(4, sio_init)

Definition at line 48 of file sior.h.

◆ I_sio_putc

#define I_sio_putc   DECLARE_IMPORT(5, sio_putc)

Definition at line 49 of file sior.h.

◆ I_sio_getc

#define I_sio_getc   DECLARE_IMPORT(6, sio_getc)

Definition at line 50 of file sior.h.

◆ I_sio_getc_block

#define I_sio_getc_block   DECLARE_IMPORT(7, sio_getc_block)

Definition at line 51 of file sior.h.

◆ I_sio_write

#define I_sio_write   DECLARE_IMPORT(8, sio_write)

Definition at line 52 of file sior.h.

◆ I_sio_read

#define I_sio_read   DECLARE_IMPORT(9, sio_read)

Definition at line 53 of file sior.h.

◆ I_sio_puts

#define I_sio_puts   DECLARE_IMPORT(10, sio_puts)

Definition at line 54 of file sior.h.

◆ I_sio_putsn

#define I_sio_putsn   DECLARE_IMPORT(11, sio_putsn)

Definition at line 55 of file sior.h.

◆ I_sio_gets

#define I_sio_gets   DECLARE_IMPORT(12, sio_gets)

Definition at line 56 of file sior.h.

◆ I_sio_flush

#define I_sio_flush   DECLARE_IMPORT(13, sio_flush)

Definition at line 57 of file sior.h.

◆ I_sio_printf

#define I_sio_printf   DECLARE_IMPORT(14, sio_printf)

Definition at line 58 of file sior.h.

◆ I_sio_vprintf

#define I_sio_vprintf   DECLARE_IMPORT(15, sio_vprintf)

Definition at line 59 of file sior.h.

Function Documentation

◆ sio_init()

void sio_init ( u32  baudrate,
u8  lcr_ueps,
u8  lcr_upen,
u8  lcr_usbl,
u8  lcr_umode 
)

Definition at line 31 of file sior.c.

◆ sio_putc()

int sio_putc ( int  c)

Definition at line 41 of file sior.c.

◆ sio_getc()

int sio_getc ( void  )

Definition at line 47 of file sior.c.

◆ sio_getc_block()

int sio_getc_block ( void  )

Same as sio_getc, but blocking. Note that getc should be blocking by default. Ho well.

Definition at line 52 of file sior.c.

◆ sio_write()

size_t sio_write ( const char *  buf,
size_t  size 
)

Definition at line 57 of file sior.c.

◆ sio_read()

size_t sio_read ( char *  buf,
size_t  size 
)

Definition at line 64 of file sior.c.

◆ sio_puts()

int sio_puts ( const char *  str)

Definition at line 71 of file sior.c.

◆ sio_putsn()

int sio_putsn ( const char *  str)

Definition at line 77 of file sior.c.

◆ sio_gets()

char * sio_gets ( char *  str)

Will block until it recieves
or \r.

Definition at line 83 of file sior.c.

◆ sio_flush()

void sio_flush ( void  )

Flushes the input buffer.

Definition at line 89 of file sior.c.

◆ sio_printf()

int sio_printf ( const char *  format,
  ... 
)

Definition at line 103 of file sior.c.

◆ sio_vprintf()

int sio_vprintf ( const char *  format,
va_list  args 
)

Definition at line 93 of file sior.c.