2012-07-06 01:02 AM
Hi,
With a STM32, I have a problemto select
either
EEPROM
(
M24LR64-R and M24M02-DR)on the same bus
I2C
.Here are the
''device
select
code
'':For
M24LR64
-R: 1 0 1 0 X 1 1 XIn the order
: 1 0 1 0 = Device type identifier X = E2 1 1 = E1 E0 ( chip enable) X = RWFor
M24M02
-DR:1 0 1
0 1
X
X
X
In the order
: 1 0 1 0 = Device type identifier 1 = E2 ( chip enable) X X = A17 A16 (MSB address bits ) X = RWThe two
address bits
A17
and
A16
for
M24M02
-DRcan not be
used
because they would
pose
a conflict with the
R
-
M24LR64there is
there a way
around the problem
?Thank you for your
response
, #pounds-head-on-desk2012-07-10 06:10 AM
another option
NXP has I²C 'splitters' Erik2012-07-10 08:24 AM
in fact
,my problem
is not from
here
:even by disconnecting
the EEPROM
M24LR64 , Istill can
't access the
address
bitA17 on the M24M02
however A16is ok...
2012-07-10 10:26 AM
in fact
,my problem
is not from
here
:even by disconnecting
the EEPROM
M24LR64 , Istill can
't access the
address
bitA17 on the M24M02
has a look at the datasheet, now I totally I do not understand 8192 bytes in I2
C mode what does A17 have to do with 8k bytes? also there are 2 strappable address pins, why the address conflict? Erik2012-07-11 01:30 AM
M24M02 Memory array : 2 Mb (
256 KBytes
) of EEPROM 2^18 = 262144 Address lines 0..17 required.2012-07-11 01:30 AM
M24M02 Memory array : 2 Mb (
256 KBytes
) of EEPROM 2^18 = 262144 Address lines 0..17 required.2012-07-11 05:21 AM
So
my problem
is I can
use bit
A16but
i can't use
the bit
A17: i use the STM32 library and after the send: I2C_Send7bitAddress(I2C1, device_select , I2C_Direction_Transmitter); the program gets stuck on: I2C_EVENT_MASTER_TRANSMITTER_MODE_SELECTED));only
with the address bit
A17
=1
2012-07-11 05:54 AM
Your problem does not make sense. Are you sure you are addressing an M24M02 device? The A17 bit is simply part of the intrinsic operation of the device. (Also note it is not recommended to drive the hardware input pin E2 dynamically - is it hardwired high or low?)
2012-07-11 06:28 AM
E2 is hardwired high
but A17 bit and A16 bit are selected in the device_selected... when i do: I2C_Send7bitAddress(I2C1, device_select , I2C_Direction_Transmitter); when device select is set: 1010 1000 and 1010 1010 are ok but 1010 1100 or 1010 1110 aren't ok...2012-07-11 06:44 AM
but A17 bit and A16 bit are selected in the device_selected
so you have 4 devices on the bus? if not the above makes no sense Erik
2012-07-11 07:22 AM
I have
just
two
EEPROM...
A17
and
A16
are
sent
during
the
device
_select codebut
are used to
select
a
memory location
in EEPROMbecause
the M24M02 EEPROM
may contain2M bit