9 years, 8 months ago.

Using mBed with my products ???

Dear guys, I´m new at mBed world. I need to clear something. I must migrate my current produtcs to ARM/Cortex controllers. I can start from zero: brand new board using Cortex-M3 (for example) + KEIL/IAR compiler. Or may be, start using the full mBed APIs. My doubt is: in order to use mBed APIs, do I need to use a hardware solution already done, such as that mBed board with LPC1768? That is, I can forget the project with my own LPC layout and use this board instead? I´m asking because all the examples I´m reading at the FAST AND EFFECTIVE EMBEDDED SYSTEMS DESIGN book, assumes that my hardware is running with the mBed board with LPC1768. I´m sorry if my doubt sounds so stupid but please, have in mind I´m new at this world. I would appreciate a lot if somebody clear this to me because I´m starting to draw the schematics. Another doubt is regarding the way to update the firmware. With the mBed board with LPC1768, I just have to drop the BIN file "on the PEN-board". How to proceed with my own hardware in order to keep this same philosofy? Regards, Xavier.

5 Answers

9 years, 8 months ago.

Welcome Xavier!

If you already have a layout and it is using one of the mBed supported micro controllers, such as the LPC1768 or any of the other ones found on the platforms page then you don't need a new layout so long as you have access to SWD programing pins. You will need to buy the corresponding development board, follow the mbed instructions on how to flash it with the latest mbed firmware, and then use that board as the programmer.

Accepted Answer

Hi Krzysztof! Now it is becoming clear to me. Your tip is very interesting. And the way you are using your "mBed" board as well. I´m gonna study a bit more the other answers but be sure I will consider your "hardware" trick. Regards, Xavier.

posted by XAVIER ALBORNOZ 09 Apr 2015

Xavier, I don't quite follow. I personally have only used the mbed platform for prototyping and have yet to manufacture anything on scale, but as far as I am aware the only cost of the mbed platform is buying a compatible development board to use for programing. Once you have that you can use your own LPC1768 circuit. In my case I have been using the KL25Z. I have my own PCB for my project which is filled with application specific components. I program this board using the SWD pins from the FRM-KL25Z board as laid out in this guide.

posted by Krzysztof Sitko 09 Apr 2015

Hi Krzysztof! Now it is becoming clear to me. Your tip is very interesting. And the way you are using your "mBed" board as well. I´m gonna study a bit more the other answers but be sure I will consider your "hardware" trick. Regards, Xavier.

posted by XAVIER ALBORNOZ 10 Apr 2015
9 years, 8 months ago.

You can use your own hardware and still develop software with mbed libs online or offline. See here for more on hardware and programming/flashing options.

Hi Wim! I thank you so much for your info! There´s a lot to read at the link you suggested. But taking a fast look, it seems it will be possible to keep going with both solutions: using my own hardware (this way I save money) along with the mBed libs. Let me study a bit more. Anyway, I thank you so much for your tip! Regards, Xavier.

posted by XAVIER ALBORNOZ 09 Apr 2015
-deleted-
9 years, 8 months ago.

Welcome Xavier,

I also want to achieve my own hardware design. I have started the following notebook page which might help you. http://developer.mbed.org/users/ebowles/notebook/freescale-bootloader-fota-firmware-over-the-air---/

My interest is to use a Freescale MCU because I need max RAM. I will be following your progress with keen interest.

9 years, 8 months ago.

Hola Xavier,

You can do that absolutely. For example, my path into mBed was like this:

1. I bought a board from HotMCU, this one in fact: http://www.hotmcu.com/lpc1768minidk2-development-board-28-tft-lcd-p-12.html?cPath=1_21

2. I bought one of their programmers. This one: http://www.hotmcu.com/usbminijtagex-jlink-jtagswd-debuggeremula%E2%80%8Btor-p-46.html?cPath=3_25

3. In the compiler, start a project with the LPC1768 mbed board selected. Code and compile. Program the BIN file to the target board using their programmer. Just make sure you set up the programmer, tell it which MCU you are using. From there, I accepted the defaults and it worked.

4. Done. Funciona. Just check the schematic and you should probably use the "real" pin names, not the mbed pin names. For example, instead of referring to pin "p5" as "p5", you need to check the schematic, and use "P0_9" instead.

Hi Jason. Thanx a lot for your suggestions. And the site you suggested has many interesting solutions. Regards, Xavier.

posted by XAVIER ALBORNOZ 10 Apr 2015
9 years, 8 months ago.

The 1768 has 32k RAM + 2 sections 16K each for USB and Ethernet....but available for other uses in your program.
Use attribute((section("AHBSRAM1"))) or attribute((section("AHBSRAM2")))
Example:
short operation_array[2000] attribute((section("AHBSRAM1"))); is a array allocated outside the first 32k
This is the coding for the online compiler and offline Gcc Arm.