AN3057
Application note
How to manage simultaneous I²C and RF data transfers with
the M24LRxx-R and M24LRxxE-R devices
1
Introduction
The M24LRxx-R or M24LRxxE-R is an EEPROM device designed to be accessed via two
different interfaces: a wired I²C interface and a standard contactless ISO 15693 RFID
interface.
Figure 1.
Typical application of an M24LRxx-R or M24LRxxE-R dual interface EEPROM
Application master
SDA
I²C bus
SCL
M24LRxx
ISO 15693 RF
ISO 15693 RF
Application board
ai17547v2
ST has published various supporting application notes explaining how the RF interface
works and the basic principles of passive RFID technology. These documents are available
from:
www.st.com/dualeeprom.
The possibility of using two different interfaces to control the dual-interface EEPROM implies
two host controllers: a microcontroller with an I²C bus and an ISO 15693 RFID reader. Due
to their nature, these two host controllers are not synchronized, which means that both
controllers might try to access the M24LRxx-R or M24LRxxE-R concurrently.
To manage this kind of situation, the M24LRxx-R or M24LRxxE-R has a built-in circuitry able
to handle possible concurrent communications and powering activities from the RF and I²C
sides.
This application note describes how the M24LRxx-R or M24LRxxE-R arbitration circuitry
operates.
Table 1
lists the products concerned by this application note.
Table 1.
Applicable products
Type
Dual interface EEPROMs
Applicable products
M24LRxx-R, M24LRxxE-R
Note:
The standard M24LRxx-R and energy-harvesting M24LRxxE-R devices will be referred to
as M24LRxx devices throughout the document.
Doc ID 16239 Rev 4
1/15
www.st.com
October 2012
Contents
AN3057
Contents
1
2
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
RF - I²C arbitration mechanism description . . . . . . . . . . . . . . . . . . . . . . 5
2.1
2.2
Communications and power supply conditions . . . . . . . . . . . . . . . . . . . . . 5
Communication arbitration when the RF and I²C channels are
both active . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
2.2.1
2.2.2
2.2.3
I²C busy states . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
RF busy states . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Arbitration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3
Recommendations when developing the M24LRxx
application software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
3.1
Issuing a command through the I²C channel . . . . . . . . . . . . . . . . . . . . . . . 9
3.1.1
3.1.2
3.1.3
I²C request while the RF channel is busy . . . . . . . . . . . . . . . . . . . . . . . . 9
I²C requests and RF time slots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
An I²C request was interrupted . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
3.2
Issuing a command through the RF channel . . . . . . . . . . . . . . . . . . . . . . 13
4
Revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
2/15
Doc ID 16239 Rev 4
AN3057
List of tables
List of tables
Table 1.
Table 2.
Table 3.
Table 4.
Table 5.
Applicable products . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Four possible combinations of power supply sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Possible cases of communication arbitration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
M24LRxx status according to command and V
CC
supply. . . . . . . . . . . . . . . . . . . . . . . . . . 13
Document revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Doc ID 16239 Rev 4
3/15
List of figures
AN3057
List of figures
Figure 1.
Figure 2.
Figure 3.
Figure 4.
Figure 5.
Figure 6.
Figure 7.
Figure 8.
Figure 9.
Figure 10.
Typical application of an M24LRxx-R or M24LRxxE-R dual interface EEPROM . . . . . . . . . 1
I²C read command busy state. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
I²C write command busy state . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
RF read command busy state. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
RF write command busy state . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
RF Stay Quiet command busy state . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Example of an Inventory command where the M24LRxx is decoded in
Slot 13. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
I²C polling when the RF channel is processing a command . . . . . . . . . . . . . . . . . . . . . . . . . 9
M24LRxx state transition diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Optimal hardware schematic of an M24LRxx application . . . . . . . . . . . . . . . . . . . . . . . . . . 12
4/15
Doc ID 16239 Rev 4
AN3057
RF - I²C arbitration mechanism description
2
RF - I²C arbitration mechanism description
The M24LRxx arbitration circuitry is twofold. It contains:
●
●
a power management unit that handles the power coming potentially from the RF or the
I²C side
a communication arbitration unit that tackles potential concurrent communications from
the RF and the I²C sides
2.1
Communications and power supply conditions
The power supply management unit has been designed to allow for flexibility, especially
when both the RF power and the wired power line are active at the same time.
The basic principle is:
●
●
When supplied only from the RF side:
–
–
the M24LRxx can be accessed only by the RF reader
the M24LRxx will serve the first decoded command (either RF or I²C) and will not
decode any command from the other interface (either I²C or RF) until the first
decoded command is complete.
Four possible combinations of power supply sources
V
CC
0 V or not
connected
0 V or not
connected
RF field
Off
On
Actions
The M24LRxx is reset.
RF data transfers: yes
I²C data transfers: no
RF data transfers: yes
I²C data transfers: yes
(see
Section 2.2: Communication
arbitration when the RF and I²C channels
are both active
for details).
RF data transfers: no
I²C data transfers: yes
When supplied from both the V
CC
pin and the RF field:
Table 2.
Possible
cases
Case 1
Case 2
Case 3
On
(1)
On
Case 4
1.
On
(1)
Off
V
CC
is “On” when the value is between V
CC
min and V
CC
max. Please refer to the M24LRxx datasheet for
full details.
Doc ID 16239 Rev 4
5/15