9 years, 3 months ago.

External "mbed" programming device?

How feasible with it be to build an external USB drag n' drop programmer device that can program any mbed compatible processor using the mbed interface chip and it's firmware? I'm thinking about a piece of hardware that has a USB connector and a JTAG connector.

This would make it easy program production boards or other boards without having to deal with the need to mess with JTAG programming programs such as OpenOCD etc... As long as the target board had a JTAG connector properly wired to the processor.

So essentially it would perform the same function as all of the ARM JTAG programmers such as ST LINK etc, but use mbed drag and drop function.

Diagram would look something like this:

/media/uploads/notronrj/programmer.png

Question relating to:

2 Answers

9 years, 3 months ago.

Simply not very feasible.

I have been looking at this for some time.

Each Target will have different flashing areas and amounts of flash and ram, even from the same MCU family. So every time you want to flash a different MCU you will need to build a flash algorithm for that exact MCU. That means flashing the bootloader chip with a new CMSIS-DAP Interface Firmware for each different MCU.

That in itself is no real problem if you have a Keil licence to run the CMSIS-DAP code here:

https://github.com/mbedmicro/CMSIS-DAP

You can then build a different interface bootloader for each MCU and drop that firmware onto the interface MCU as we do when updating it with the MBED firmware.

What would be feasible is if the CMSIS-DAP program was built into MBED in some form so Keil is not needed. But then you would be able to build the firmware for a Target that you can not compile on MBED, so not much point really.

Although its not drag and drop, the most comprehensive way would be to use the Segger J-LINK plus with J-Flash. This is windows driven and contains the flashing parameters for all the ARM cored MCU's. But this will set you back around £500.

Otherwise do what most do and use the platform board as the programmer for you project board. However you will only be able to program that exact Target MCU.

Accepted Answer

"Otherwise do what most do and use the platform board as the programmer for you project board. "

Thanks Paul. Do you have some links where this technique is described? BTW, I'm looking to use the processor in this mbed http://developer.mbed.org/platforms/ST-Nucleo-F401RE/ for my custom board.

Regards, Jim

posted by Jim Norton 13 Jan 2015

Jim, I use the Freescale platforms to jump my code to a project board, you can see an example here:

http://developer.mbed.org/cookbook/Prototype-To-Hardware-KL25Z

I did this some time ago, but to be honest I only use my own hardware now and use the FRDM boards purely as a SWD programmer. I haven't tried yet (something I must do) but it should work just the same for the ST MCU's. Give it a try :)

posted by Paul Staron 14 Jan 2015
9 years, 3 months ago.

Such a device already exists for the LPC1768.

Look at the following page: http://developer.mbed.org/users/ms523/notebook/mbed-programmer/

HI Paul.

I did contact Martin Smith about his programmer and unfortunately he said he can't get it to program other Targets such as Freescale or ST due to the flash memory limitations of the LPC1768. From what I understand the bin file is loaded onto the LPC1768 flash and then transferred to the Target, The more Targets included will use up further flash space. I suppose if it was based on the Mbed LPC1768 then the external flash could be used to hold the bin file before downloading to Target leaving 512k available to the Target MCU flash algorithms. But I don't know how his code works exactly.

posted by Paul Staron 14 Jan 2015