0% found this document useful (0 votes)
511 views

Altair Embed Quickstart - UG

Altair Embed quick start guide

Uploaded by

Prakash Arul
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
511 views

Altair Embed Quickstart - UG

Altair Embed quick start guide

Uploaded by

Prakash Arul
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 18

Intellectual Property Rights Notice:

Copyrights, Trademarks, Trade Secrets, Patents & Third Party Software Licenses
Altair Embed® 2020 Copyright 1986-2020.
The Platform for Innovation™
Altair Engineering Inc. Copyright © 1986-2020. All Rights Reserved.

Special Notice: Pre-release versions of Altair software are provided ‘as is’, without warranty of any
kind. Usage of pre-release versions is strictly limited to non-production purposes.

Altair HyperWorks™ - The Platform for Innovation™


Altair AcuConsole™ ©2006-2020
Altair AcuSolve™ ©1997-2020
Altair ElectroFlo™ ©1992-2020
Altair ESAComp™ ©1992-2020
Altair Feko™ ©1999-2014 Altair Development S.A. (Pty) Ltd., ©2014-2020 Altair Engineering Inc.
Altair Flux™ ©1983-2020
Altair FluxMotor™ ©2017-2020
Altair HyperCrash™ ©2001-2020
Altair HyperGraph™ ©1995-2020
Altair HyperLife™ ©1990-2020
Altair HyperMesh™ ©1990-2020
Altair HyperStudy™ ©1999-2020
Altair HyperView™ ©1999-2020
Altair Virtual Wind Tunnel™ ©2012-2020
Altair HyperXtrude™ ©1999-2020
Altair Manufacturing Solver™ © 2011-2020
Altair MotionSolve™ ©2002-2020
Altair MotionView™ ©1993-2020
Altair Multiscale Designer™ ©2011-2020
Altair OptiStruct™ ©1996-2020
Altair Radioss™ ©1986-2020
Altair Seam™ © 1985-2019 Cambridge Collaborative, Inc., © 2019-2020 Altair Engineering Inc.
Altair SimLab™ ©2004-2020
Altair SimSolid™ ©2015-2020
Altair nanoFluidX™ ©2013-2018 Fluidyna GmbH, © 2018-2020 Altair Engineering Inc.
Altair ultraFluidX™ ©2010-2018 Fluidyna GmbH, © 2018-2020 Altair Engineering Inc.
Altair WinProp™ ©2000-2020
Altair ConnectMe™ ©2014-2020
Plus other products from the Altair solidThinking Platform.

Altair Packaged Solution Offerings (PSOs)


Altair Automated Reporting Director™ ©2008-2020
Altair GeoMechanics Director™ ©2011-2020
Altair Impact Simulation Director™ ©2010-2020
Altair Model Mesher Director™ ©2010-2020
Altair NVH Director™ ©2010-2020
Altair Squeak and Rattle Director™ ©2012-2020
Altair Virtual Gauge Director™ ©2012-2020
Altair Weight Analytics™ ©2013-2020
Altair Weld Certification Director™ ©2014-2020
Altair Multi-Disciplinary Optimization Director™ ©2012-2020

Altair solidThinking - Where Innovation Takes Shape™


Altair Inspire™ ©2009-2020 including Altair Inspire Motion, Altair Inspire Structures, and Altair Inspire Print3D
Altair Inspire Extrude Metal ©1996-2020 (formerly Click2Extrude® - Metal)
Altair Inspire Extrude Polymer ©1996-2020 (formerly Click2Extrude® - Polymer)
Altair Inspire Cast ©2011-2020 (formerly Click2Cast®)
Altair Inspire Form ©1998-2020 (formerly Click2Form®)
Altair Inspire Render ©1993-2016 Solid Iris Technologies Software Development One PLLC, © 2016-2020 Altair Engineering Inc
(initial release-Q3 2019, formerly Thea Studio)

Getting Started with Embed 2


Altair Inspire Studio ©1993-2020 (formerly ‘Evolve’)
Altair Compose® ©2007-2020 (formerly solidThinking Compose®)
Altair Activate® ©1989-2020 (formerly solidThinking Activate®)
Altair Embed® ©1989-2020 (formerly solidThinking Embed®)
o Altair Embed SE ©1989-2020 (formerly solidThinking Embed® SE)
o Altair Embed / Digital Power Designer ©2012-2020
Altair SimLab™ ©2004-2020
Altair One™ ©1994-2020

Altair PBS Works™ - Accelerating Innovation in the Cloud™


Altair® PBS Professional® ©1994-2020
Altair Control™ ©2008-2020; (formerly PBS Control)
Altair Access™ ©2008-2020; (formerly PBS Access)
Altair Accelerator™ ©1995-2020; (formerly NetworkComputer)
Altair Accelerator™ Plus ©1995-2020; (formerly WorkloadXelerator)
Altair FlowTracer™ ©1995-2020; (formerly FlowTracer)
Altair Allocator™ ©1995-2020; (formerly LicenseAllocator)
Altair Monitor™ ©1995-2020; (formerly LicenseMonitor)
Altair Hero™ ©1995-2020; (formerly HERO)
Altair Software Asset Optimization (SAO) ©2007-2020

Note:
Compute Manager™ ©2012-2017 is now part of Altair Access
Display Manager™ ©2013-2017 is now part of Altair Access
PBS Application Services™ ©2008-2017 is now part of Altair Access
PBS Analytics™ ©2008-2017 is now part of Altair Control
PBS Desktop™ ©2008-2012 is now part of Altair Access, specifically Altair Access desktop, which also has Altair Access web and
Altair Access mobile
e-Compute™ ©2000-2010 was replaced by “Compute Manager” which is now Altair Access
Altair SmartWorks™ - Innovation Intelligence®
Altair intellectual property rights are protected under U.S. and international laws and treaties. Additionally, Altair software is
protected under patent #6,859,792 and other patents pending. All other marks are the property of their respective owners.
ALTAIR ENGINEERING INC. Proprietary and Confidential. Contains Trade Secret Information.
Not for use or disclosure outside of Altair and its licensed clients. Information contained in Altair software shall not be decompiled,
disassembled, “unlocked”, reverse translated, reverse engineered, or publicly displayed or publicly performed in any manner. Usage
of the software is only as explicitly permitted in the end user software license agreement. Copyright notice does not imply
publication.
Third party software licenses
AcuConsole contains material licensed from Intelligent Light (www.ilight.com) and used by permission.
Software Security Measures:
Altair Engineering Inc. and its subsidiaries and affiliates reserve the right to embed software security mechanisms in the Software
for the purpose of detecting the installation and/or use of illegal copies of the Software. The Software may collect and transmit
non-proprietary data about those illegal copies. Data collected will not include any customer data created by or used in connection
with the Software and will not be provided to any third party, except as may be required by law or legal process or to enforce our
rights with respect to the use of any illegal copies of the Software. By using the Software, each user consents to such detection and
collection of data, as well as its transmission and use if an illegal copy of the Software is detected. No steps may be taken to avoid
or detect the purpose of any such security mechanisms.

Getting Started with Embed 3


Contents
What is Embed .................................................................................................................................................... 5
Supported hardware ........................................................................................................................................... 5
Getting started with Embed ............................................................................................................................... 6
Embed window ............................................................................................................................................... 7
Block libraries .................................................................................................................................................. 8
Exploring, executing, and debugging the Chip Temp sample diagram............................................................... 9
Compiling the source diagram ...................................................................................................................... 11
Downloading and debugging ........................................................................................................................ 15
Setting diagram parameters ......................................................................................................................... 17
Running the diagram and viewing results .................................................................................................... 17
Where to go from here ..................................................................................................................................... 18
Videos ........................................................................................................................................................... 18
Sample diagrams ........................................................................................................................................... 18

Getting Started with Embed 4


What is Embed
Altair Embed™, commonly referred to as Embed, is a visual environment for Model-Based Firmware
Development of embedded control systems. It combines an intuitive graphical interface with a content-rich
environment to help you design real-time applications targeting a broad variety of platforms, including
Arduino®; ARM®-Linux® Raspberry Pi™; Texas Instruments™; and STMicroelectronics® microcontrollers.
Embed is an extension of Embed SE, a visual environment for modeling and simulating dynamic systems,
but without the ability to generate code. Embed Basic is a limited edition of Embed: it contains all the
modeling, simulation, and code generation capabilities of Embed but restricts block diagram size to no more
than 100 blocks. It is tailored to academics, makers, and hobbyist, and embedded developers interested in
building proof-of-concept applications. For the complete family of Altair Embed products and the features
they include, click here.

Supported hardware
Embed supports the following microcontrollers:
• Arduino Leonardo, Mega2560, and Uno
• ARM-Linux Raspberry Pi Zero, Zero W, 1A+, 2B+, 2B, 3A+, 3B, 3B+, and 4B series
• STMicroelectronics STM32 F0x, F3x, F4x, G0x, G4x, and L4x series
• Texas Instruments C2407, Delfino™, F280x, F28xx, F282xx, MSP430™, Piccolo™, and ARM Cortex™
M3 series

Getting Started with Embed 5


The Altair Embed product family
The Altair Embed product family includes the Basic, Professional, and Simulation-Only (SE) Editions.
Feature Embed Basic Embed Professional Embed Simulation-Only (SE)

Block diagram size limited to 


100 blocks

Drag-and-drop block diagram   


construction with 120+
standard blocks
Continuous, discrete, and   
hybrid simulations
Conditional execution of   
subsystems
Interactive, batch, auto-   
restart, and single-step
execution modes
Fixed, adaptive, and stiff   
integration algorithms
Visualization with interactive   
plots and stripCharts, 3D
animation, 3D plots, and polar
plots
Analysis and linearization   
with Bode, root locus, and
frequency domain plots
OpenVision block set   
State Charts block set   
Fixed Point block set  
Digital Motor Control block  
set
Data I/O using National   
Instruments and
Measurement Computing
boards
Data I/O with an OPC server   
Data I/O with an RS 232   
device
Data I/O with UDP   
Data I/O with a PCAN USB   
Controller Area Network
(CAN) device
Code generation  
Arduino Leonardo, Mega  
2560, and Uno target support

Getting Started with Embed 6


Feature Embed Basic Embed Professional Embed Simulation-Only (SE)
ARM-Linux Raspberry Pi Zero,  
Zero W, 1A+, 1B+, 2B, 3A+,
3B, 3B+, 4B target support
STMicroelectronics STM32 F0,  
F3, F4, G0, G4, L4 target
support
Texas Instruments C2000,  
ARM Cortex M3, MSP430
target support
Generic MCU target support  
JTAG communication link  
Serial communication link  

Getting started with Embed


Embed window

Start Embed by clicking on . The Embed window appears.

A: The Title bar includes the name of the currently open diagram. As you develop diagrams with hierarchy
and drill down into the hierarchy, you can look at the title bar to see where you are in the diagram.
B: The Menu bar contains drop down menus for all commands and blocks. You can customize the menu bar
with your own menu items, commands, and blocks using the Edit > Preferences > Menu Directories
command.
Getting Started with Embed 7
Commands and blocks can also be accessed from the block browser, toolbar, pop-up menus, and short-cut
keyboard commands. For example, to open a new diagram, you select File > New from the menu, or you
can click the toolbar button.
C: Customizable Toolbar buttons are shortcuts for commonly used editing, simulation, and debugging
functions.
D: The Block browser mirrors the menu bar and provides a convenient way to insert blocks into a diagram,
manage diagrams, and execute commands.
E: The Status bar keeps track of the number of blocks in your diagram, along with key simulation
information including the simulation range, step size, elapsed simulation time, and currently selected
integration algorithm.
F: The Work area is where you build your models.

Block libraries
In Embed, blocks are your basic design component. You can choose from over 200 mathematical,
engineering, and scientific blocks, allowing you to realize system models of any degree of complexity.
Embed also includes the following blocks specifically for designing embedded controllers.
• Fixed-Point block library
• Arduino Leonardo, Mega 2560, and Uno peripheral block libraries
• Raspberry Pi peripheral block libraries
• STMicroelectronics STM32 peripheral block libraries
• Texas Instruments C2407, Delfino, F280x, F28xx, F282xx, MSP430, Piccolo, and ARM Cortex M3
peripheral block libraries
• Texas Instruments digital motor control (DMC) block libraries
• Blocks for communicating with the target and performing analog and digital I/O operations with the
analog and digital ports on the target device
If your requirements extend beyond the standard block and toolbox libraries, you can create custom blocks
in C, C++, Fortran, and Pascal and add them to the Blocks menu for use in other models.

Getting Started with Embed 8


Exploring, executing, and debugging the Chip
Temp sample diagram
This section gets you started using Embed by stepping you through the Chip Temp on F28069 diagram. This
diagram measures the temperature in centigrade of the Piccolo F28069. The ADC channel 5 is redirected
from an external pin to the on-chip temperature sensor. The compound block Turn On Ch 5 Temp
Conversion performs the redirection.
To access the chip temperature model
1. Click Examples > Embedded > Piccolo > ADC.
2. Select Chip Temp on F28069.
The following diagram appears:

3. Right-click Chip Temperature on F28069 to move down one level of hierarchy.

The above diagram reads ADC channel 5 and applies an offset and gain to convert the reading to
degrees centigrade. It also executes the code contained in Turn on Ch 5 Temp Conversion, which
switches ADC 5 from an external pin to the internal temperature sensor. Note that Turn on Ch 5 Temp
Conversion is triggered by the built-in variable $firstPass. This means that the block and its contents are
Getting Started with Embed 9
executed once at boot time.
4. Right-click Turn on Ch 5 Temp Conversion to move down one level of hierarchy.

The above diagram enables the internal temperature sensor on ADC A5. The Extern Read
(*(int*)0x3D7E82L) and Extern Write (*(int*)0x3D7E85L) blocks write directly to the hardware registers.
To enforce the order of execution, Embed executes parallel flows in top-down order. The ePWM block
sends Start of Conversion pulses to the ADC A5.

Getting Started with Embed 10


This code also enables the ePWM block to send Start of Conversion pulses to the ACD A5.

Compiling the source diagram


Before you can compile the source diagram, move back up to the top level of the diagram.
To compile the source diagram
1. At the top level of the diagram, select the compound block Chip Temperature on F28069.
The compound block turns red.

Getting Started with Embed 11


2. Click Tools > Code Gen.
The C Code Generation dialog box appears.

3. Activate Use selected compound edge pins for data exchange. This lets you debug the target
executable.
4. Click Compile to generate C code and compile it with Code Composer.
The following DOS window appears.

Getting Started with Embed 12


The above window displays the output of the Code Composer compiling and linking the diagram.
5. You can check to make sure the compile (cl2000) and link (link2000) are error free, and then press any
key to continue.

Getting Started with Embed 13


6. Click Browse in the C Code Generation dialog box to examine the generated C-code.

Getting Started with Embed 14


Downloading and debugging
After compiling the source diagram, you can download and debug it using the companion debug diagram
Chip Temp on F28069-d.
To download and debug
1. Click Examples > Embedded > Piccolo > ADC.
2. Select Chip Temp on F28069 –d.
The following diagram appears:

Getting Started with Embed 15


3. Right-click F28x Config.
The F28x Properties dialog box appears.

4. Make sure that the proper JTAG linkage is selected.

Getting Started with Embed 16


Setting diagram parameters
You set the main run rate of the diagram for both simulation and generated code for the target in the
System Properties dialog box. For simulation purposes, you can also set the integration algorithm and
duration of the simulation.
To set parameters
1. Choose System > System Properties.
The System Properties dialog box appears.

2. The above dialog box is for the Chip Temp on F28069-d debug diagram. Notice the options used in the
debug diagram:
• Start: 0; End: 10 provides a 10 second interval on plots.
• Time Step: 0.005 provides a 200 Hz update rate to data and plots.
• Run in Real Time causes the diagram to execute in real time, so that Embed runs in sync with the
target.
• Auto Restart causes Embed to run continuously until you stop it.
• Retain State causes Embed to refrain from initializing blocks on restart and prevents reload of the
OUT file.

Running the diagram and viewing results


When you simulate the diagram, Embed downloads and runs the OUT file you created when you compiled
the source diagram. After it starts running on the target, Embed provides:
• Interactive inputs: In this case, a 1Hz square wave to the GPIOs to blink on-board LEDs on the TI
controlSTICK or controlCARD
• Interactive plots of on-chip outputs: In this case, raw ADC A5 reading and adjusted temperature in
centigrade

Getting Started with Embed 17


To run the diagram
• Choose System > Go, or click Go in the toolbar.
The diagram runs until you click Stop in the toolbar.

Where to go from here


There are dozens of videos and sample diagrams available that demonstrate basic and advanced operations
you can perform on your hardware. There is also an online Forum where you can ask questions, get
answers, and promote conversations among Embed users.

Videos
The online Learning Center includes a series of short videos that introduce key concepts that are useful
when programming your hardware.

Sample diagrams
Your Embed software includes dozens of fully documented sample diagrams. These diagrams illustrate both
simple and complex models spanning a broad range of engineering disciplines.
To access the diagrams, click on Examples > Embedded. The two main subcategories are Digital Motor
Control and Digital Power Systems. If you know the chip you're targeting, you can see target-specific
examples in the target subcategory.

Getting Started with Embed 18

You might also like