This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi all,
I want to change boot configuration for Software Controlled Firmware Update Process.
I will use one boot mode select pin (0x0F - GPIO15)
BOOTPINCONFIG Bit Fields 0x5AFFFF0F
I am plannig to use Flash Boot (0x03 - BOOT_DEF0) and SCI Boot (0x01 BOOT_DEF1) modes.
BOOTDEF Bit Fields for Low 0xFFFF0103, for High 0xFFFFFFFF
I'm trying to be careful because of OTP locations can be written only once.
-----
1- There are Z1 and Z2 zones for BOOTPINCONFIG and BOOTDEF bit fields.
According to this thread Z1 has higher priority than Z2. ( I could not find this rule in the TRM. I would appreciate it if you could show me)
So logical way to write OTP is, firstly program Z2 bit fields. If problem occurs, program Z1 bit fields. Z2 bit fields will be ignored.
Please correct me, if I am wrong.
-----
2- I read TI E2E threads about writing OTP and Application report (SPRACN1).
I think there is 3 way to writing OTP. (with sysconfig, with Project Properties -> Debug -> Flash Settings, with code snippets which are mentioned Application reports SPRACN1)
I have separate questions about these methods.
- about sysconfig method
After building "led1_ex1_blinky" project with above DCSM settings, "dcsm.asm" and "dcsm.cmd" files are generated.
Are these files enough to write OTP ?
Do we need to merge "dcsm.cmd" and already existing "2838x_RAM_Ink_cpu1.cmd" file ?
Do we need to merge "dcsm.asm" and already existing "f2838x_codestartbranch.asm" file ?
Do we need to add any code to "led_ex1_blinky.c" for writing OTP memory (as in SPRACN1) ?
- about Project Properties -> Debug -> Flash Settings method
Are these settings enough to writing OTP memory ?
Do we need a separate code for writing OTP ?
If we don't need any code, this method is much easier than the others.
-----
3- Is it possible to try boot mode configuration changes without writing OTP memory ?
I saw threads about Emulation. But I could not understand.
For TMS3202838x Emulation Register addresses like below
EMUBOOTPINCONFIG 0x0000 0D00
EMUBOOTDEF-LOW 0x0000 0D04
EMUBOOTDEF-HIGH 0x0000 0D05
These addresses have values attached below
If I write 0x5AFFFF0F to the EMUBOOTPINCONFIG and 0xFFFF0103 to the EMUBOOTDEF-LOW address, is it possible to try boot mode configuration temporarily ?
Best regards,
Mehmet
Hello Mehmet.
For Question 1: Yes, Z1 takes priority over Z2. Your approach is correct
For Question 3: You need to setup the EMU locations as below:
0xD00 = 0x0203;
0xD01 = 0x5A01;
0xD02 = 0;
0xD03 = 0;
0xD04 = mode;
0xD05 = mode;
0xD06 = mode;
0xD07 = mode;
Question 2: This is a C2kWare question. Maybe creating a separate E2E thread on this would help.
-Kedar
I don't understand why you wrote 0x5A010203 ?
I just want to use only GPIO15
so I must write 0x5AFFFF0F, am I right ?
Thanks
Also,
According to TRM page 706 ( SPRUII0E )
"It is recommended to use Z1-BOOTPINCONFIG first and then if OTP configurations need to be altered, switch to using Z2-BOOTPINCONFIG."
Are you sure Z1-BOOTPINCONFIG higher priority than Z2-BOOTPINCONFIG ?
Hi All,
With single GPIO (GPIO15 - 0x0F) 2 boot mode available.
- Flash Boot mode (0x03)
- SCI Boot mode (0x01)
EMUBOOTPINCONFIG = 0x5AFFFF0F
EMUBOOTDEF-LOW = 0xFFFF0103
EMUBOOTDEF-HIGH = 0xFFFFFFFF
EMU Setup attached below.
After CPU Reset,
- When GPIO15 == 0 MCU boot from Flash
- When GPIO15 == 1 MCU boot from SCI
With this setup, emulation works correctly.
Also
According to TRM page 706 ( SPRUII0E ); Z2 takes priority over Z1. So writing to Z2-GPREG will override the Z1-GPREG settings.
-Mehmet.