15 posts / 0 new
Last post
Andrey_Kiselnikov
Offline
Last seen: 3 months 18 hours ago
Joined: 2018-02-05 08:17
OTP memory protection

Hi, does DA14585 have any protection features to prevent reading OTP memory and cloning devices by unauthorized manufacturers?

Device: 
PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi Andrey_Kiselnikov,

Hi Andrey_Kiselnikov,

If the JTAG bit is disabled in the OTP header, then the OTP is fully protected and cannot be accessed. Please, check the Figure 12: BootROM Sequence from the DA14585 datasheet.

Thanks, PM_Dialog

Andrey_Kiselnikov
Offline
Last seen: 3 months 18 hours ago
Joined: 2018-02-05 08:17
Thank you very much.

Thank you very much.

log2view
Offline
Last seen: 1 week 3 days ago
Joined: 2019-01-22 06:54
Hmm. I have a same question.

Hmm. I have a same question.
At page 45 of DA14585 datasheet (4.4.3 BootROM Sequence)

The BootROM code identifies whether the chip is in Development mode of Normal mode by reading
the “Application Programmed” flags from the OTP header....
If the predefined value is identified this ensures that the OTP is functional and that the application
code has been programmed. However, if the predefined value is not identified, either the OTP is not
programmed (all zeros) or the OTP memory is not operational (random data).
In the first case, the system enters Development mode where the application can be developed and
values can be calibrated. In the second case, the BootROM code recognizes the OTP to be
malfunctioning due to power issues (e.g. battery life is ending and thus the LDO cannot generate the
required voltages)
and continues to activate the peripherals so that the system is still usable and can
be debugged
.

So, if I attach a weak power supply at startup, I can make JTAG enabled and have access to all memory? Is it right?

PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi log2view,

Hi log2view,

As it is mentioned in this thread, if the JTAG bit is disabled in the OTP header, then the OTP is fully protected and CANNOT be accessed either with the recommended power supply or a weaker power supply. If you apply a weaker power as a power supply and if the JTAG bit is disabled in the OTP header, you CANNOT make JTAG enabled and have ΝΟ access to all memory.

Thanks, PM_Dialog

log2view
Offline
Last seen: 1 week 3 days ago
Joined: 2019-01-22 06:54
..if the JTAG bit is disabled

..if the JTAG bit is disabled in the OTP header..

but what happened, when BootROM don't recognize right header,
according to datasheet:

to be malfunctioning due to power issues (e.g. battery life is ending and thus the LDO cannot generate the required voltages)

?????

PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi log2view,

Hi log2view,

Could you please clarify you question? You suppose that if the battery life is ending and thus the LDO cannot generate the required voltages, the JTAG will be enabled? If yes, as I mentioned in my previous post, in no case this will be happened, and you won’t be able to access the OTP if the JTAG is disabled. Apply weaker power as a power supply will not enable the JTAG.

Thanks, PM_Dialog

log2view
Offline
Last seen: 1 week 3 days ago
Joined: 2019-01-22 06:54
I don't suppose anything,

I don't suppose anything, just read datasheet, page 45 of DA14585 datasheet (4.4.3 BootROM Sequence). Which say:
- if the OTP memory is not operational (random data), the system is still usable and canbe debugged.
- as one of case the OTP memory is not operational is the LDO cannot generate the required voltages

Can you comment this case?

PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi log2view,

Hi log2view,

Please check the Figure 12: BootROM Sequence from the datasheet. Since the bootROM reads the “Application Flags” field from the OTP header, if this flag is programmed, the chip is development mode, otherwise it’s in normal mode. If the chip is in normal mode and the application flag is equal to 0x0000 this means that the OPT is unprogrammed, but you could burn and use the OTP.

Thanks, PM_Dialog

log2view
Offline
Last seen: 1 week 3 days ago
Joined: 2019-01-22 06:54
OK. But what will happened

OK. But what will happened due OTP malfunction when :
a) "OTP Control Value OK?" = false;
b) "Application Programmed Flag #1" and "Application Programmed Flag #2" have garbage;
c) "Application Programmed Flag #1" = "Application is in OTP" and "Application Programmed Flag #2" = garbage
?

PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi log2view,

Hi log2view,

  1. If the OTP control is false, then the OTP set up to true, and you will go to development mode.
  2. Both of the applications flag should be correctly programmed. Otherwise, you will get a HW or ore the OPT is not programmed but operational.
  3. I am not able to understand what you mean.

Thanks, PM_Dialog

log2view
Offline
Last seen: 1 week 3 days ago
Joined: 2019-01-22 06:54
OTP control is false, then

OTP control is false, then the OTP set up to true, and you will go to development mode

So, you acknowledge that due to power issues OTP can be malfunctioning and system can go to development mode?

PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi log2view,

Hi log2view,

Could you please clarify a bit more your last question?

Thanks, PM_Dialog

log2view
Offline
Last seen: 1 week 3 days ago
Joined: 2019-01-22 06:54
How can I clarify more my

How can I clarify more my question...
Is it true:
1. OTP can be malfunctioning due to power issues (e.g. battery life is ending)?
2. (OTP Control Value OK?" can be false) during boot process when OTP is malfunctioning?

PM_Dialog
Offline
Last seen: 20 hours 3 min ago
Staff
Joined: 2018-02-08 11:03
Hi log2view,

Hi log2view,

If the OTP memory is not operational (random data) the BootROM code recognizes the OTP to be malfunctioning due to power issues and continues to activate the peripherals so that the system is still usable and can be debugged.

Thanks, PM_Dialog