I2C Services: Difference between revisions
PlasmaGrass (talk | contribs) add link between 0x00150080 , IR service, and ZL + ZR + Cstick |
|||
(One intermediate revision by one other user not shown) | |||
Line 87: | Line 87: | ||
| WriteCommand8 (u8 devid, u8 cmdid) | | WriteCommand8 (u8 devid, u8 cmdid) | ||
|- | |- | ||
| | | 0x000700C0 | ||
| | | | ||
| WriteRegister16 (u8 devid, | | WriteRegister16 (u8 devid, u8 regid, u16 regdata) | ||
|- | |- | ||
| 0x000800C2 | | 0x000800C2 | ||
Line 99: | Line 99: | ||
| u8 ReadRegister8 (u8 devid, u8 regid) | | u8 ReadRegister8 (u8 devid, u8 regid) | ||
|- | |- | ||
| | | 0x000A0080 | ||
| | | | ||
| u16 ReadRegister16 (u8 devid, | | u16 ReadRegister16 (u8 devid, u8 regid) | ||
|- | |- | ||
| 0x000B00C2 | | 0x000B00C2 | ||
Line 117: | Line 117: | ||
| 0x000E00C2 | | 0x000E00C2 | ||
| | | | ||
| | | WriteRegisterBuffer (u8 devid, u8 regid, unused (bufsize?), (bufsize << 14) <nowiki>|</nowiki> 0x402, void* buffer) | ||
|- | |- | ||
| 0x000F00C0 | | 0x000F00C0 | ||
| | | | ||
| | | ReadRegisterBuffer (u8 devid, u8 regid, min(bufsize, 0x20)), +0x180: (bufsize << 14) <nowiki>|</nowiki> 2, void* buffer | ||
|- | |- | ||
| | | 0x001000C0 | ||
| | | | ||
| ReadEEPROM (u8 devid = 14, u16 blockid, min(bufsize >> 1, 0x10)), +0x180: (bufsize << 15) <nowiki>|</nowiki> 2, u16* buffer | |||
|- | |- | ||
| 0x001100C2 | | 0x001100C2 | ||
| | | | ||
| WriteRegisterBuffer(u8 devid, | | WriteRegisterBuffer(u8 devid, u8 regid, buffersize, u8 *buff) | ||
|- | |- | ||
| 0x001200C2 | | 0x001200C2 | ||
| | | | ||
| ReadRegisterBuffer(u8 devid, | | ReadRegisterBuffer(u8 devid, u8 regid, buffersize, u8 *buff) | ||
|- | |- | ||
| 0x00130040 | | 0x00130040 | ||
Line 148: | Line 148: | ||
|} | |} | ||
Commands 0x00130040..0x00150080 are only usable with the New3DS i2c module: on Old3DS the actual command-handler function for each of these commands just return an error. Commands 0x00140082 and 0x00150080 are used by [[NFC_Services|NFC]] module. | Commands 0x00130040..0x00150080 are only usable with the New3DS i2c module: on Old3DS the actual command-handler function for each of these commands just return an error. Commands 0x00140082 and 0x00150080 are used by [[NFC_Services|NFC]] module. Command 0x00150080 is also used for reading ZL, ZR, and C-stick data by [[IR Services]]. |