Sony PlayStation2 Study
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

65 lines
1.1 KiB

4 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. /*
  2. # _____ ___ ____ ___ ____
  3. # ____| | ____| | | |____|
  4. # | ___| |____ ___| ____| | \ PS2DEV Open Source Project.
  5. #-----------------------------------------------------------------------
  6. # Copyright 2001-2004, ps2dev - http://www.ps2dev.org
  7. # Licenced under Academic Free License version 2.0
  8. # Review ps2sdk README & LICENSE files for further details.
  9. */
  10. /**
  11. * @file
  12. * Common definitions for SIOR on the EE and IOP
  13. */
  14. #ifndef __SIOR_COMMON_H__
  15. #define __SIOR_COMMON_H__
  16. #include <tamtypes.h>
  17. #define SIOR_IRX 0xC001510
  18. enum {
  19. SIOR_INIT = 1,
  20. SIOR_PUTC,
  21. SIOR_GETC,
  22. SIOR_GETCBLOCK,
  23. SIOR_WRITE,
  24. SIOR_READ,
  25. SIOR_PUTS,
  26. SIOR_PUTSN,
  27. SIOR_GETS,
  28. SIOR_FLUSH
  29. };
  30. struct siorInitArgs {
  31. u32 baudrate;
  32. u8 lcr_ueps;
  33. u8 lcr_upen;
  34. u8 lcr_usbl;
  35. u8 lcr_umode;
  36. };
  37. struct siorReadArgs {
  38. char *buf;
  39. s32 len;
  40. };
  41. struct siorWriteArgs {
  42. const char *buf;
  43. s32 len;
  44. };
  45. union siorCommsData {
  46. u8 data[64];
  47. int result;
  48. struct siorInitArgs init;
  49. struct siorReadArgs read;
  50. struct siorWriteArgs write;
  51. const char *cstr;
  52. char *str;
  53. int c;
  54. };
  55. #endif /* __SIOR_COMMON_H__ */