AnsweredAssumed Answered

Lot # from UID - am I doing it right?

Question asked by john doe on Jul 4, 2017
Latest reply on Jul 4, 2017 by john doe

    uint32_t word0 = *(uint32_t *)(UID_BASE);
    uint32_t word1 = *(uint32_t *)(UID_BASE + 0x04); // offsets taken from reference manual
    uint32_t word2 = *(uint32_t *)(UID_BASE + 0x08);
    uint64_t lotNum;

 

bits 8:31 on word 1 are bits 23 through bit 0 of the batch number

word2 is bit 55 through bit 24 of the batch number

lotNum is the batch number, I think...

 

lotNum = ((uint64_t)word2 << 24 ) | (word1 >> 8);

Outcomes