mongoose-os icon indicating copy to clipboard operation
mongoose-os copied to clipboard

(ATECC508A) ATCA.SetConfig fails after UserExtra set

Open carldunham opened this issue 8 years ago • 2 comments

Not sure if this is really a bug or caveat emptor, but it seems that once the UserExtra byte is set to anything other than 0x00, it cannot be set again (enforced by the chip).

Because the ATCA.SetConfig RPC call sends the entire config, nothing after UserExtra will get set. This includes the KeyConfigs, sadly.

It might be helpful to break up SetConfig so that it can be called for individual sections. The atcab_write_bytes_zone() function seems to support this quite nicely.

In any case, dropping this here in case someone else runs into it.

carldunham avatar Apr 04 '17 13:04 carldunham

so, even setting to the same value does not work? bummer. i'll do it, but may not get around to it for a while. in the mean time, PRs welcome. device's ATCA.SetConfig handler is here.

rojer avatar Apr 05 '17 17:04 rojer

Yeah, I guess the code could check to see if it's the same and non-zero, and skip over it. I may do that, will save me 0.75USD. :-)

carldunham avatar Apr 06 '17 02:04 carldunham