SC18IM700 read internal register not work correctly

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SC18IM700 read internal register not work correctly

Jump to solution
1,256 Views
j_otisk
Contributor I

Dear engineers, I have application with SC18IM700 and I want to read register 0x0A to confirm I2C ACK. When I read its content it returns first answer too early (not waiting for P char on bus) and then returns still in loop until restart. Is this bug or should be read instruction in different format? analyzer screen is attached.

0 Kudos
1 Solution
1,162 Views
reyes
NXP TechSupport
NXP TechSupport

Hi,

 

There is a note in the SC18IM700 datasheet that I think describes the behavior you are seen about the response immediately after you set the register you want to read, in section 7.1.3 on page 5 is mentioned:

Remark: Write and read from the internal 18IM register is processed immediately as soon as the intended register is determined by 18IM.

 

Yes, you cannot use 2 SC18IM700 in the same bus if you are trying to read the internal registers due to the addressing possibilities on this device.

 

Maybe you can use a switch or multiplexer to select which SC18IM700 you want to communicate on the bus, here is an option:

https://www.nxp.com/docs/en/data-sheet/NX3L1G3157.pdf

 

Regards,

Jose

NXP Semiconductors

View solution in original post

5 Replies
1,162 Views
reyes
NXP TechSupport
NXP TechSupport

Hi,

The host issues the internal register read command by sending an R character followed by the registers to be read. The frame is then terminated with a P character.

So, 0x52, then 0x0A, and then 0x50, you are correct in the image you sent.

 

Once the command is issued, SC18IM700 will access its internal registers and returns the contents of these registers to the host.

 

Write and read from the internal 18IM register is processed immediately as soon as the intended register is determined by 18IM.

 

The response you are getting is correct (0xF0) for register 0x0A.

 

Try to read all the internal registers from 0x00 to 0x0A and see if the loop issue solves.

Regards,

Jose

0 Kudos
1,162 Views
j_otisk
Contributor I

Dear Jose,

problem partially solved. On rs485 are two SC18IM700. Because SC18IM700 is not waiting to P char and starts to transmitt after register address is sent the second SC18IM700 see following on bus: 0x52 0x0A 0xF0 which tell it to read 0x0A and 0xF0 which is interpreted as last valid register which is 0x0A. First SC18IM700 see this and reply too, this continues forever.

Well when we ignore fact that without any addressing posibility is nonsense to read any internal register when there are two SC18IM700 on same RS485 bus (so my original idea is not possible anyway), loop is created because of obvious bug: SC18IM700 didn't wait for P char when reading internal register.

If you can confirm this we should report some official bug to include it in errata maybe.

0x0A read result with single SC18IM700 on bus:

uart read4.jpg

0 Kudos
1,163 Views
reyes
NXP TechSupport
NXP TechSupport

Hi,

 

There is a note in the SC18IM700 datasheet that I think describes the behavior you are seen about the response immediately after you set the register you want to read, in section 7.1.3 on page 5 is mentioned:

Remark: Write and read from the internal 18IM register is processed immediately as soon as the intended register is determined by 18IM.

 

Yes, you cannot use 2 SC18IM700 in the same bus if you are trying to read the internal registers due to the addressing possibilities on this device.

 

Maybe you can use a switch or multiplexer to select which SC18IM700 you want to communicate on the bus, here is an option:

https://www.nxp.com/docs/en/data-sheet/NX3L1G3157.pdf

 

Regards,

Jose

NXP Semiconductors

1,162 Views
j_otisk
Contributor I

Hi,

thank  you. Yes that is indeed there but I was sure it is intended to reply after P char which focused me away from this warning.

Thank you for advice I was able to do what I need by back reading mandatory registers in i2c slave devices instead of checking SC18IM700 . This allows me putting multiple SC18IM700  on same bus without any problem because i2c is addresable.

0 Kudos
1,162 Views
j_otisk
Contributor I

Dear Jose,

thank you for answer. I tried what you said but problem is that SC18IM700  will start to reply immediately after receiving register address, see attached image.

When I tried to ready internal register 0x02 I just sent 0x52, 0x02 and register was returned as 1 byte correctly (no P char was sent), subsequent communication works without problem. This is not according to datasheet. commands to read and write to i2c bus works as expected.

When I tried same method to read 0x0A register then again loop is started and register content is returned endlessly. Problem is that I'm using RS485 so there is not full duplnex, once loop is started I'm unable to interrupt it because bus is bussy.

Looks like bug, what you think?

uart read3.jpguart read2.jpg

0 Kudos