| 数据搜索系统,热门电子元器件搜索 |
|
MPR121 数据表(PDF) 49 Page - Freescale Semiconductor, Inc |
|
|
|||||||||||||||||||||||||||||
MPR121 数据表(HTML) 49 Page - Freescale Semiconductor, Inc |
|
49 / 57 page ![]() MPR121 Sensors Freescale Semiconductor 49 MESSAGE FORMAT FOR WRITING THE MPR121 A write to the MPR121 comprises the transmission of the MPR121’s keyscan slave address with the R/W bit set to 0, followed by at least one byte of information. The first byte of information is the command byte. The command byte determines which register of the MPR121 is to be written by the next byte, if received. If a STOP condition is detected after the command byte is received, the MPR121 takes no further action (Figure 53) beyond storing the command byte. Any bytes received after the command byte are data bytes. Figure 53. Command Byte Received Any bytes received after the command byte are data bytes. The first data byte goes into the internal register of the MPR121 selected by the command byte (Figure 54). Figure 54. Command and Single Data Byte Received If multiple data bytes are transmitted before a STOP condition is detected, these bytes are generally stored in subsequent MPR121 internal registers because the command byte address generally auto-increments. MESSAGE FORMAT FOR READING THE MPR121 MPR121 is read using MPR121's internally stored register address as address pointer, the same way the stored register address is used as address pointer for a write. The pointer generally auto-increments after each data byte is read using the same rules as for a write. Thus, a read is initiated by first configuring MPR121's register address by performing a write (Figure 53) followed by a repeated start. The master can now read 'n' consecutive bytes from MPR121, with first data byte being read from the register addressed by the initialized register address. Figure 55. Reading MPR121 OPERATION WITH MULTIPLE MASTER The application should use repeated starts to address the MPR121 to avoid bus confusion between I2C masters.On a I2C bus, once a master issues a start/repeated start condition, that master owns the bus until a stop condition occurs. If a master that does not own the bus attempts to take control of that bus, then improper addressing may occur. An address may always be rewritten to fix this problem. Follow I2C protocol for multiple master configurations. SAA P 0 SLAVE ADDRESS COMMAND BYTE Acknowledge from MPR121 R/W Acknowledge from MPR121 D15 D14 D13 D12 D11 D10 D9 D8 Commandbyte is storedonreceipt of STOP condition SA AA P 0 SLAVE ADDRESS COMMAND BYTE DATA BYTE Acknowledge from MPR121 R/W 1byte Auto-increment memory word address D15 D14 D13 D12 D11 D10 D9 D8 D1 D0 D3 D2 D5 D4 D7 D6 How command byte and data byte map into MPR121's registers Acknowledge from MPR121 Acknowledge from MPR121 SA A P 1 SLAVE ADDRESS DATA BYTE R/W nbytes auto-increment memory word address D1 D0 D3 D2 D5 D4 D7 D6 Acknowledge from MPR121 Acknowledge from master SA A 0 Acknowledge from MPR121 R/W Acknowledge from MPR121 D15 D14 D13 D12 D11 D10 D9 D8 Command byte is stored on receipt of STOP condition SLAVE ADDRESS COMMAND BYTE Repeated Start Stop |
|
链接网址 |
| ALLDATASHEET是否为您带来帮助? [ DONATE ] |
关于 Alldatasheet | 广告服务 | 联系我们 | 隐私政策 | 数据表链接 | 链接交换 | 制造商名单 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |