Multiple ATECCX08A on I2C Bus

Go To Last Post
5 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

 

Hi,

 

Having adopted the ATECC108A and ATECC508A security chip to be used with Atmega2560 and other Arduino compliant AVR chips. The cryptoauth API works very well. Configuring the chips, setting up configure_zone and dats_zone are behaving as expected. All API calls work as expected. 

 

Now I intend to chain several ATECCX08A chips on the I2C bus. According to the documentation this is possible. There is even a I2C slot ready to be rewritten as part of the config_zone. Only how this exactly going to work is undocumented. I've already tried to reset the I2C device address via ACES Studio. Without success.

 

I would be thankful for any hint how to reset the predefined I2C device address, which is 0xC0 for all ATECCX08A devices.

 

Tom

Last Edited: Mon. Dec 28, 2015 - 01:44 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

This question might be more appropriate here: http://community.atmel.com/forum...

 

* Agreed and moved. Moderator*

Last Edited: Mon. Dec 28, 2015 - 01:45 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

 

Ok, so found the reason why the multiple ATECCX08 devices on one I2C bus didn't work out as expected:

 

1. Indeed, one can change the device address from within the config data zone. It is byte 16 in the config_zone that has to be rewritten.

 

2. Take care not to use a device address that sets the least significant ( furthest to the right ) bit to 1. Otherwise you change a I2C write packet to a I2C read packet. This was the first mistake I've made.

 

3. The cryptoauth API defines that the device_address gets defined with the API commands "eccX08p_set_device_id" and/or eccX08p_init. The normal way the device gets initialized from within eccX08_i2c.c . But there are two more places where the device address gets defined: 

3.1.: in my own Arduino library and

3.2.: the device address is also hardcoded inside of the file eccX08_config.h

 

Rewriting the files and definitions accordingly to enable to call the I2C methods with a flexible device address resultet in making the code working as expected. 

 

Tom

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Tom,

I finally logged into the forum.  Technically, I should have been moderating this all along, but hey...

 

Glad you figured out the I2C addressing issue.  I work with the device everyday and I still get it wrong every now and then.  When we designed the eccX08_config code, the intent was for the customer to change the address here. 

 

Let us know if you have any other questions.

 

Steve

Steve Jarmusz

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

I think I am also in the same situation you are in. I need to have 2 crypto chips.

I could access the chips with different address directly by manipulating the address in eccX08_config.h. Can you share or suggest on what changes need to be done to make the library to work with different addresses.

Thanks,

Anand