Yesterday, I have held a webinar with element14 that talked about the benefits of MDK.
Here's the conversation log:
Speakers: Jürgen Langfeld (J) and Christopher Seidl (C)
J: Hello and welcome to the webinar “Benefits of MDK”. My name is Jürgen Langfeld and I work for element14 as a technical advisor in Munich. I’m here with Christopher Seidl from ARM who will tell us more about the benefits of MDK compared to free tools that are out there in the market. Hello, Christopher!
C: Hi Jürgen! Thanks for inviting me today!
J: Let me quickly introduce element14. Farnell Element14 is a high-service distributor of technology products and solutions for electronic system design, maintenance and repair in Europe, America and Asia Pacific. As a digital enterprise, we bring together the latest products, services and development software, all connected to an industry leading online engineering community, ELEMENT14. Through our community, purchasers and engineers can access peers and experts, a wide range of independent technical information and proprietary tools.
Our multi-channel focus ensures we can meet the varying needs of customers and includes an extensive global network of transactional websites and more traditional sales channels. To keep pace with changing technology, our engineers actively identify and source innovative niche manufacturers providing choice and competitive advantage for today’s most in-demand application areas, supported by a global supply chain and an inventory profile in which we invest and develop.
Well, whether researching a new technology, designing an electronic product, or looking for parts to repair an existing system, Farnell Element14 is the trusted global source for engineering solutions.
Christopher, as element14 has many different silicon vendors on the line card, how many devices are you supporting with MDK?
C: Currently, we support over 3750 devices from all major silicon vendors.
J: That’s impressive! Tell me more about MDK!
C: The Keil MDK microcontroller development kit consists of MDK-Core, which is made up of the µVision IDE and debugger. The µVision IDE combines project management, run-time environment, build facilities, source code editing, and program debugging in a single powerful environment. µVision is easy-to-use and accelerates your embedded software development. The µVision Debugger provides a single environment in which you may test, verify, and optimize your application code. The debugger includes traditional features like simple and complex breakpoints, watch windows, and execution control and provides full visibility to device peripherals. It also contains advanced capabilities such as the component viewer and the event recorder, as well as full instruction trace using when using our ULINKpro debug and trace adapter.
Software Packs add device support and software components that you can use as building blocks for your application. These software components are provided by ARM, silicon vendors and middleware companies.
CMSIS, the Cortex Microcontroller Software Interface Standard, is provided as a software pack itself. It is a vendor independent collection of API definitions, libraries, utilities, and methods that simplify and accelerate the creation of microcontroller applications. CMSIS is provided free-of-charge by ARM and its software components can be used in any open source and commercial projects.
Software programmers benefit from RTOS, DSP-Libraries, consistent access to core peripherals, and enhanced debug visibility.
J: Which compiler are you using under the hood?
C: MDK is using the ARM Compiler which is considered as the reference compiler for the ARM architecture. It provides very efficient code and has excellent optimization options, which can be easily configured from within µVision. You can also make use of Microlib, a set of libraries that have been highly optimized for use on the Cortex-M architecture. It is possible to achieve reductions in flash footprint of up to 40% compared to the standard libraries when using Microlib.
J: Many of our customers require a compiler that they can use for functional safety applications. Do you have a certified compiler available?
C: MDK offers two versions of the ARM compiler: The proven ARM Compiler 5 which is certified for by TÜV for functional safety applications offering and which offers long term support and maintenance. The new ARM Compiler 6 is based on the LLVM compiler technology and offers superior codes size and performance. It also adds support for the latest C++ standards, such as C++11 and C++14.
J: I am often asked for middleware from our customers to accelerate their development. What do you offer here?
C: Our MDK Middleware provides royalty-free, tightly-coupled software components that are specifically designed for communication peripherals in microcontrollers. It supports TCP/IP networking with both, IPv4 and IPv6, USB host and device, and a file system component that lets you work with files in storage devices such as RAM, Flash, various memory cards, or USB memory devices. The graphics component enables you to develop flexible graphical user interfaces for LCD displays, while the mbed software components enable IoT applications. mbed TLS provides secure communication using SSL/TLS, whereas mbed Client connects your device to an mbed Device Server. MDK Middleware is provided as part of the MDK-Professional or MDK-Plus editions in binary format.
J: I see that you have two IDEs. You have already talked about the µVision IDE. What is DS-MDK?
C: DS-MDK combines the Eclipse-based DS-5 IDE and debugger with CMSIS-Pack technology and uses software packs to extend device support for devices based on 32-bit ARM Cortex-A processors or heterogeneous systems based on 32-bit ARM Cortex-A and ARM Cortex-M processors. Heterogeneous devices combine the best of both worlds. This means that you can run a sophisticated Linux application on the Cortex-A core and have a real-time application running on the Cortex-M core. DS-MDK is part of MDK-Professional.
J: Can you tell me more about CMSIS as a standard? All silicon vendors are supporting this, right? How can our customers benefit from CMSIS?
C: CMSIS is widely adopted in the industry and offers a unified feature set when talking about system startup, processor core access, and peripheral definitions. CMSIS-CORE makes it easy to get started with a new device or to migrate software across microcontrollers. CMSIS-RTOS is an API that enables consistent software layers with middleware and library components. Our reference implementation CMSIS-RTOS RTX runs on every Cortex-M device and is easy to learn and use. And we are working on a version of the popular FreeRTOS using the CMSIS-RTOS API. This should be available quite soon. Interfacing microcontroller peripherals with middleware or generic application code can be challenging as each device is different. Ready-to use CMSIS-Driver interfaces are today available for many microcontroller families and avoid cumbersome and time consuming driver porting. Developing a real-time digital signal processing (DSP) system is not trivial as the DSP algorithms heavily rely on complex mathematical operations that are even time-critical. The CMSIS-DSP library is a rich collection of DSP functions that are optimized by ARM for the various Cortex-M processor cores. CMSIS-Packdescribes a delivery mechanism for software components, device parameters, and evaluation board support. Users can benefit from code templates that help them to get started quickly.
J: That all sounds very nice, but most of our customers are using the toolchains they get freely from their silicon vendor. How do you compete with these freely available tools?
C: That is a valid question. Let me show you for example the superior compiler performance using an example project: I have here a demo project for the LPCXpresso 5411x development platform. It is using CMSIS-RTOS RTX5 and is compiled with gcc, using the LPCXpresso IDE. The resulting code size with gcc is 10.3 KB and 2.9 KB RAM. Now, let’s switch to MDK and use ARM Compiler 5 to build the project. We can see that for these memory constrained devices, the code size is better, only 9.6 KB ROM and 2.6 KB RAM which consists of the read-write data and the zero initialized data. This means that you get more functionality into your chip.
J: Great! Our customers are often concerned about code size. They always look for the smallest device that they can use in their projects due to price restrictions.
C: We can even reduce the code size! ARM Compiler 6 offers the smallest code size that you can get. As I said this is the latest compiler from ARM that is available with MDK. Now let’s take a look at the results. They are much better, only 7 KB ROM and 2.2 KB RAM. This means that you get more code into the same device. This can save a lot of money when going to mass production and justifies paying a little extra on the development tool!
J: That is really impressive, but I’m not yet convinced. What else do you have in stock?
C: I have briefly told you about our superior debug capabilities. Let’s take a look at another example: I have here a web server application running on an STM32F7 discovery board. This application is using our middleware for setting up the web server and the TCP/IP communication using IPv4 and IPv6. Often, embedded devices are headless, which means that you do not have a display to show you information of what’s going on. This can be tricky especially for networking applications, when you don’t know if your device has received an IP address or not. This is no problem when using the component viewer that gives you access to variables and structures of software components. As you can see here, our device has received an IP address. Also, you see the netmask, default gateway, and the DNS servers that have been configured by the DHCP server.
J: Having this information is nice, but what about dynamic software behavior?
C: For that, we have the event recorder. It uses event annotations in the user application code or software component libraries, for example our network component, to provide event timing and data information while the program is executing. This event information is stored in an event buffer on the target system that is continuously read by the debug unit and displayed in the Event Recorder window of the MDK debugger. During program execution, the µVision debugger reads the content of the event buffer and displays this information. Just like here. These links take you directly to the documentation, so that you can check for more information on a specific event, in case you are not sure what it does. You might have noticed that we got some buffer overflows as the amount of messages is quite large. The on-board ST-Link is great for simple run-stop debugging, but runs into limitations quite fast. Our ULINK family of debug adapters offers superior performance with up to 800 Mbps streaming trace. To overcome the bottleneck here, we can reduce the number of messages, by filtering for events, that we are specifically interested in. This filter is applied as soon as you start running the code again.
J: You said user application code – does that mean that the user can also take advantage of this?
C: Of course! This comes in very handy, especially if you reuse a lot of code in different company locations or in various projects.
J: This is of course a big advantage compared to free tooling! How do I find more information about this?
C: MDK is a really integrated solution. It offers you F1 help that takes you to the relevant documentation when used on a function name for example . But you can also use the links from the manage run-time environment window that is using the information from the software packs. Both methods are using the information from the software packs to display the relevant documentation.
J: What other resources do you have available? How do you help programmers who are new to ARM to get started?
C: Our learning page on keil.com/learn offers lots of content for all levels of expertise. If you are new to ARM, have a look at the fundamentals and the start programming section. Our getting started guide is targeted towards new customers and shows how to install and use MDK. If you are more experienced and want to get started with our middleware, have a look at the examples that are available here and which can be used as a starting point for your own application.
J: Now I can see your benefits. What about switching devices? My customers sometimes need to switch from one vendor to the other. Do you support that as well?
C: Using a vendor tool, you are always locked in and it is hard to escape. You cannot simply switch to another toolchain. With MDK, you just install the device support pack for the new target and switch your project to it. This works in every edition of MDK.
J: Awesome! Can you tell me more about the different editions of MDK?
C: Our MDK-Lite edition is freely available but limited to a code size of 32 KB. If this is sufficient for you, you can even use it in commercial products. The Cortex-M edition supports all ARM Cortex-M based devices up to Cortex-M7 without any code size limitation. The MDK-Plus edition adds support for a subset of our middleware that is sufficient for most software projects. MDK-Professionalcontains the full middleware with the mbed components and support for IPv6 networking and also contains models for programmers who need to start writing code for the latest ARMv8-M based microcontrollers as ARM Cortex-M23 and M33. Also, this edition comes with DS-MDK for programming heterogeneous devices.
J: And all editions can be purchased via element14! Let me quickly summarize what I have learned today about MDK. MDK provides the widest device support for all major silicon vendors and offers middleware for TCP/IP networking, USB host and device, as well as file I/O and graphics. The new ARM Compiler 6 provides the smallest code size and best performance and adds support for the latest C++ standards. The superior debug capabilities of µVision help you to reduce your development time and to get to market faster.
element14 will showcase MDK at its booth at the upcoming embedded world 2017 in Nuremberg. Please visit us in hall 3 at booth 221.
C: Oh, that’s just around the corner from ARM! We are also in hall 3 at booth 342.
J: Christopher, thanks for answering my questions.
C: You’re welcome!