Booting dircetly into Redlink FW from flash?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Booting dircetly into Redlink FW from flash?

881件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mch0 on Fri Feb 06 05:37:20 MST 2015
Hello,

the usual way to use the Redlink FW is  a two-step approach:
First the MCU of the probe enumerates as a DFU device.
Then the Redlink Server downloads the current Redlink FW into SRAM an the probe re-enumerates as a different HID device (VID 0x21BD, PID 0006) which is the probe FW.

This works quite fine, but if your target MCU also boots into USB at the same time the probe boots, then the host cannot know which device is the probe and which one is the target.

In this scenario it would be desirable to flash the (current) Redlink FW once into the internal flash of the probe MCU and then directly boot from flash.
The probe would then enumerate as the"probe HID" device directly.

Can this be done easily, i.e. is there a Redlink FW that is relocated for start from internal flash?

We plan to deploy quite a lot (40+) of these "hard coded debuggers" for edu purposes in two labs.
The probes are already designed and tested with the LPC4320 (and up) and work fine so far.
AFAIK they could run on some LPC18xx as well. If so, does this require a different Redlink FW?

We just use the JTAG debug interface, no SWD, trace port or other fancy stuff.

Best regards,

Mike
0 件の賞賛
返信
4 返答(返信)

851件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Sun Feb 08 01:23:29 MST 2015
Glad to hear that you now have a solution that works for you. You should take note though that the redlink firmware provided with one version of LPCXpresso may not work with, or may not provide support for some features, when used with a future LPCXpresso release. Thus I would recommend that you update the firmware you have flashed when you update to a new LPCXpresso version.

Also regarding the CMSIS-DAP firmware for LPC-Link2: you are correct that using this firmware you can currently only connect from LPCXpresso to the M4 core inside the LPC43xx parts. Allowing connections via CMSIS-DAP to the M0 core(s) is something we do intend to support in a future release LPCXpresso release though.

Regards,
LPCXpresso Support
0 件の賞賛
返信

851件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mch0 on Sat Feb 07 15:52:06 MST 2015
Update:
I decided to stick with the Redlink FW, because according to the documentation the CMSIS/DAP version cannot debug the multicore targets.

So I just wrote a "bootloader stub" residing in internal flash which copies the current Redlink FW (stored in internal flash as a BLOB also) to SRAM, sets up VTOR and the SP for SRAM operation and then jump to the "new" reset vector, i.e. starts the FW.

Works fine on a LPC4327. Our "microboards" now enumerate immediately as "LPCLINK2 redlink" devices and work as expected with LPCXpresso as JTAG probes.

Thanks for your help and clarification even on a project that is well "out of support scope".  :)

Regards,

Mike


0 件の賞賛
返信

851件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mch0 on Fri Feb 06 06:53:48 MST 2015

Quote: lpcxpresso-support
First of all, redlink is designed to run on known NXP debug probe hardware only. It is only tested on such probes, and we make no guarantees as to its use on other hardware.


I agree, that is our own risk. The current FW runs on the minimalistic board we designed for that purpose.


Quote: lpcxpresso-support

Also redlink firmware will only run LPC43xx, there is no LPC18xx variant.


Thanks for the clarification!


Quote: lpcxpresso-support

But there is no redlink firmware build available that could run from internal flash. Note that you mention LPC4320 - which of course has no internal flash.


My fault, was not formulated well. We populated the first of the probes with a LPC4320 and the next ones with LPC4327 and LPC4370 (since all are pin compatible, thas was a no brainer and left us with some room for experiments).
The board contains just the MCU, no SPIFI for cost and size reasons. The Redlink FW runs on all of them, and I just mentioned the "weakest" of the bunch.


Quote: lpcxpresso-support

If you are using internal flash then the simplest solution might be to try using CMSIS-DAP firmware, which is designed to programmed and run from flash ......



OK, I'll try that and see whether it works at all with our "custom probe board" and if so whether is has any noticable effect on the "debug performance/convenience" with LPCXpresso.
With the current Redlink FW debugging works very well and reliably.
The target is a LPC4370 and while the current projects use only the M4 core, later projects will use at least one M0 core in addition to that.

Thanks for the info,

Mike

0 件の賞賛
返信

851件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Fri Feb 06 06:33:35 MST 2015
First of all, redlink is designed to run on known NXP debug probe hardware only. It is only tested on such probes, and we make no guarantees as to its use on other hardware. Also redlink firmware will only run LPC43xx, there is no LPC18xx variant.

But those points aside, if you hardware had SPIFI flash then you should be able to program the image into that - the LPC43xx bootloader would download it into RAM on startup). LPCScrypt could be used to do this.

But there is no redlink firmware build available that could run from internal flash. Note that you mention LPC4320 - which of course has no internal flash. If you are using internal flash then the simplest solution might be to try using CMSIS-DAP firmware, which is designed to programmed and run from flash ......

http://www.lpcware.com/lpclink2-config-tool

Regards,
LPCXpresso Support
0 件の賞賛
返信