Skip to Main Content Skip to Search
Product Documentation

Getting Started

Overview

Embedded Coder software provides an interface between MATLAB and the Green Hills MULTI IDE software. The software enables you to

while using the MATLAB numerical analysis and simulation functions.

Embedded Coder software connects MATLAB and Simulink with Green Hills MULTI integrated development and debugging environment from Green Hills. The software enables you to use MATLAB and Simulink to debug and verify embedded code running on many microprocessors that Green Hills MULTI software supports, such as the ARM, Freescale MPC7400, Blackfin, and NEC V850 families.

Using the software, you can perform the following tasks and others related to Model-Based Design:

Embedded Coder software includes an IDE Project Generator component. With the IDE Project Generator component, you can generate a complete project file for Green Hills MULTI software from Simulink models, using C code generated with Embedded Coder software. Thus, you can use both Simulink Coder and Embedded Coder software to generate generic ANSI C code projects for Green Hills MULTI from Simulink models. You can then build and run the code on supported processors.

The following list suggests some of the uses for Embedded Coder software:

Software Structure and Components

Components

Embedded Coder software comprises these components

IDE Automation Interface

The IDE Automation Interface component enables you to use MATLAB functions and methods to communicate with the Green Hills MULTI IDE software. With the MATLAB functions, you can perform the following program development tasks:

The IDE Automation Interface component provides the following functionality in the Debug component—methods and functions for project automation, debugging, and data manipulation.

IDE Project Generator

The IDE Project Generator component is a collection of methods that use the Green Hills MULTI API to create projects in Green Hills MULTI and generate code. With the interface, you can do the following:

Verification

Verifying your processes and algorithms is an essential part of developing applications. The components of Embedded Coder software provide the following verification tools.

Configuring Your Software

Embedded Coder software requires some information about your MULTI installation before you can use the software to develop projects in MULTI from MATLAB. To configure the interface between MATLAB and MULTI, provide the information in the following table. Embedded Coder software provides a GUI-based configuration utility to help you configure the software and interface.

GUI ParameterConfiguration InformationDescription
DirectoryMULTI installation folderIdentifies the path to your Green Hills software.
ConfigurationPrimary processorIdentifies the processor on which you are developing.
Debug serverDebug server typeSpecifies the type of debug server to use.
Host nameHost nameSpecifies the name of the machine that runs your IDE Link service.
Port numberPort numberSpecifies the port for communicating with the host and IDE Link service. The service listens on this port.

Configuring Embedded Coder Software.  You must configure your installation before you start working with the software and MULTI.

To generate code for Blackfin processors, the software supports only the Green Hills version of the Blackfin compiler.

Follow these steps to open the Embedded Coder configuration utility:

  1. Enter ghsmulticonfig at the MATLAB prompt.

    The Embedded Coder Configuration dialog box opens, as shown in the following figure.

  2. In the Directory field, enter the path to the executable file multi.exe for your Green Hills® MULTI® installation. To search for the file, click Browse.

  3. From the Configuration list, select your primary processor. Embedded Coder software supports a variety of processors. Choose one that matches your development platform. In many cases, the processor_standalone.tgt variants, such as ppc_standalone.tgt, work well. Refer to your Green Hills MULTI documentation for more information about the configuration options for processors.

  4. Enter the debug server string in Debug server. The string you enter sets specific values for processors, such as the board support library and whether the processor is big or little endian.

    The standard input string is debugconnection. To use a processor simulator, such as the MPC7448 simulator, enter the string

    simppc -cpu=ppc7448 -fast -dec-rom_use_entry

    Your MULTI documentation provides more information about the debug server options and how to use them. You can find more debug server string for simulators in the reference material for ghsmulticonfig.

      Note   If you use a custom board, add the -bsp option to the Debug server string to specify your processor. For example, add -bsp=mpc7448 if you use the MPC7448 EVB.

  5. In Host name, enter the name of the machine that is going to run the IDE Link service. When you construct a ghsmulti object, the ghsmulti function starts the IDE Link service. To launch the service, the function needs to know where the service will run. The Host name string identifies that location. The default value is localhost, meaning the service runs on the local machine. No other input is valid.

  6. Enter the port number for the service in Port number.

    Port number 4444 is the default port value. To change the port used, enter a different value in this field. Verify that the port you enter is available. If the port number you enter is not available, the IDE Link service does not start. Thus, you get an error message in MATLAB when you try to construct a ghsmulti object.

  7. Select or clear Show server status window to specify whether the IDE Link service status appears in the task bar. The default value is to show the service status. Clearing Show server status window hides the status in the task bar. Select this option as a best practice. Keeping this option selected enables the software to shut down the communication services for Green Hills MULTI completely.

  8. Click OK to complete the configuration process and close the dialog box.

Configuring Green Hills MULTI to use Full Folder Paths

When you install MULTI to use with the software, MULTI sets the Show Paths option to use relative file paths. So that projects and programs build accurately, configure MULTI to use full folder paths. Follow these steps to change the configuration in MULTI.

  1. Start MULTI from your desktop.

  2. Switch to the Project Manager tool.

  3. Select View > Show Paths > Full Paths.

  


Related Products & Applications

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS