Hello
Sorry for the late, but I don't know why, I had not notified by e-mail than an answer was done on my post:smileyconfused:.
I will try to respond on all your point
1) I'm using two different linker file (In KDS i'm using two different Build configuration) according I compile directly in flash with the debbuger or with the Boot.
The difference are on these lines.
With debbuger ( intflash_ddrdara.ld)
vectorrom (RX): ORIGIN = 0x00000000, LENGTH = 0x00000400
cfmprotrom (R): ORIGIN = 0x00000400, LENGTH = 0x00000020
rom (RX): ORIGIN = 0x00000420, LENGTH = 0x000FFBE0 /* Code + Const data */
With Bootloader (intflash_ddrdara_boot.ld):
vectorrom (RX): ORIGIN = 0x00020000, LENGTH = 0x00000400
cfmprotrom (R): ORIGIN = 0x00020400, LENGTH = 0x00000020
rom (RX): ORIGIN = 0x00020420, LENGTH = 0x000DFBE0 /* Code + Const data */
I don't know if I relocate the vector table with my MQX configuration. Are they a specific parameter or a way to know that?
MQX_ROM_VECTORS = 0. Find attached config file
2) i am using the USB host bootloader for the K60 based on the AN4368 adapted to the K70
TWR-K70 MSD HOST Bootloader based on AN4368 source code
I even added a correction described here
Kinetis K70: Bootloader with USB?
The linker of my application shift the code to the 0x2 000 after the flashed bootlader (See attached linker file intflash_ddrdara_boot.ld)
I relocated the vector table? I think yes but I don't remember the way. I think the bootloader do it correctly.
3) - Where is the application loaded? - In this case you have the bootloader?
Following are my use cases:
a) compile the application with the linker file intflash_ddrdara.ld where the code is palced at 0x0, flash it with the debbuger (P&E Multilink universal) With KDS
- After flash in the KDS "Debug" view, I click on "Run\Resume" -> All work correctly
- Board is power Off/On (debug session on KDS is out) -> Problem occurs, Ethernet not work
b) compile the application with the linker file intflash_ddrdara_boot.ld where the code is palced at 0x2 0000. Flash the K70 USB Host bootlader with teh P&E Multilink. Unplug the JTag, Power Off/On the board, the bootloader wait USB key to flash the application. I insert the USB key with the .S19 of my application. After that, the board is power Off/On.
The Boot start and jump to the application (0x2 0000) -> All work correctly
-How do you check if the application should enter in bootloader mode or jump to the app?
The bootlader send data on a serial port. I can se on an HyperTerminal the state of the bootloader. (Started , Wait USB Key, flashing, jump to the application)
-Does this happen always when you make POR at any time? Or in specific cases? - Have you tried POR without the debugger attached?
See above (case a) and b)
- What happen if you reset the application using reset pin?
With this question, I complete my test and made the following
A-1) Compile the application with intflash_ddrddata.ld (soft located at 0x0 0000)
A-2) Flash the compiled application with the P&E Multilink universal
A-3) In Kds, on debug view, make RUN/Resume: My application start and the ethernet is operational
A-4) In Kds, on debug view, click on "restart a process...." and then RUN/Resume: My application restart and the ethernet is operational
A-5) Unplug the JTAG link between my board and the P&E Multilink (Nothing append)
A-6) Link Pin 10 and 19 of the JTAG connector (GND and Reset) and remove => My board not start. I haven't way to know if any code begin. It seem NO
A-7) Power Off/On the board: My application start but Ethernet not work
A-8) Link Pin 10 and 19 of the JTAG connector (GND and Reset) and remove =>My application start but Ethernet not work
B-1) Compile the application with intflash_ddrdata_boot.ld (soft located at 0x2 0000)
B-2) Flash the bootloader with the P&E universal multilink the boot start
B-3) Unplug the JTAG link between my board and the P&E Multilink (Nothing append)
B-4) Link Pin 10 and 19 of the JTAG connector (GND and Reset) and remove (To test like done on A-6) => Boot restart correcrly (In the same use case, (A-6) my application not start...)
B-5) USB key is plugged and flash begin
B-6) At the end of flash, a jump is done to my application. Application start and Ethernet WORK
B-7) Link Pin 10 and 19 of the JTAG connector (GND and Reset) and remove => My application start and Ethernet work correctly
B-8) Power Off/On=> My application start and Ethernet work correctly
B-9) Link Pin 10 and 19 of the JTAG connector (GND and Reset) and remove => My application start and Ethernet work correctly
- Do you have any of our evaluation borad? The behavior is the same here?
I'm using a specific home board. But the µC with the RAM and flash is the Sqm4 board (Schema provided SQM4_K70_v22_SCH.pdf)
Sorry for the long response but I try to explain the more detail without be ambigus.
Thank for your help:smileyhappy: