FPGA design and verification in mechatronic applications

by Darrell A. Teegarden, Mentor Graphics Corp. , TechOnline India - October 13, 2009

The VHDL-AMS language is an undiscovered asset for FPGA designers--a powerful tool to define and verify requirements in a non-digital context

The value of modern systems, such as automotive and aerospace vehicles, has become heavily influenced by their electronic content. Consequently, selecting the right electronic components and choosing the optimal design methodology is vital in developing a successful product. The flexibility of new components, such as FPGA devices, is intriguing. The potential of these devices, however, cannot be fully (and safely) utilized without incorporating the latest design and verification methodologies.

FPGA devices are already heavily used in aerospace applications. The widespread use of FPGA devices in automotive applications, however, has not yet arrived—but trends reported by mainstream automotive suppliers indicate that the potential advantages of these devices have not gone unnoticed1. The capacity of these devices to implement and integrate both software and digital-hardware functionality—on a single component—is very attractive. Certain challenges remain, such as ensuring that these devices are compatible with harsh automotive environments and are compliant with the exacting reliability requirements of the industry. The biggest challenge in utilizing FPGA devices, however, may be one of methodology.

Design methodologies for automotive and aerospace applications must consider the complexities of mechatronic2 systems. Even something as simple as an electronic throttle control system (see Figure 1) is a sophisticated combination of feedback control systems, analog and digital circuitry, multi-physics sensors and actuators—all controlling an electromechanical physical device (an engine throttle body in this example). The importance of unambiguous, verifiable system requirements to the success of these electronic products cannot be overemphasized.


Figure 1. Electronic throttle control system (click on image to enlarge).
{pagebreak}FPGA designers are familiar with HDL-based, requirements-driven design methodologies for digital electronics. But how can requirements be expressed for a system that, while it contains digital elements, is fundamentally non-digital? Fortunately, an executable HDL exists that extends the capabilities of the digital VHDL language with continuous time, differential and algebraic equations, multi-physics, transfer functions (both s and z domain), energy conserving analog circuit capabilities (like SPICE), statistical distributions for parametric variations, and functions expressed in software C code. This language is the IEEE Std. 1076.1 VHDL-AMS3 language. VHDL-AMS is the perfect language for providing continuity in design and verification at all levels: functional specifications; architectural partitions; and component implementations (see Figure 2).


Figure 2. Multi-Discipline design and verification with VHDL-AMS (click on image to enlarge).

The VHDL-AMS language standard was completed in 1999. The description of this language sounds ideal, so why aren't more designers using the language today? Simply put, implementing the standard has been very difficult technically. Now, however, after years of development, several different tool suppliers are providing simulators that can efficiently execute the VHDL-AMS language. The long-awaited promise of this language standard and the resultant methodology is now a reality.

Digital designers at major automotive suppliers, such as Magneti Marelli1, have confirmed significant benefits by using the VHDL-AMS language. Since VHDL-AMS is a pure superset of the VHDL language, the designer starts with all of the well-known benefits of HDL design and verification. Then, using the extensions provided by VHDL-AMS, the design can be thoroughly analyzed by incorporating the impact of the neighboring engineering disciplines: analog electrical engineering (Kirchoff's current and voltage laws), ADC, and DSP circuits; control system transfer functions; mechanical engineering (Newton's and Bernoulli's laws); and extensibility any other desired engineering or physics discipline. {pagebreak}To be specific, VHDL-AMS allows expression of simultaneous, nonlinear differential and algebraic equations in any model; the model creator need only express the equations and let the simulator solve them in time or frequency domain. Domain knowledge from any engineering discipline can be encapsulated in reusable libraries5 that are accessible by any member of the design team. It is then possible for the digital developer to start with a clear, executable specification that incorporates all of the requirements (including non-digital) and to use the same specification as a virtual verification environment. Since VHDL-AMS supports the concept of component statistical distributions6, it is also practical to verify that the digital design will operate in the context of tolerance and manufacturing variation, which drive the "non-digital" characteristics of mechatronic systems. A reference book for the VHDL-AMS language, The System Designer's Guide to VHDL-AMS: Analog, Mixed-Signal and Mixed-Technology Modeling, provides an extensive modeling example using the VHDL-AMS language to represent various aspects of an unpiloted aerial vehicle (UAV). The UAV example includes models focusing on mixed-signal, mixed-technology, power electronics, communications, and the overall system. See Figure 3 for an overview of the system model provided in the book. See Figure 4 for an example of a simple gain block written in the VHDL-AMS language, such as for the potentiometer that is shown in Figure 3. Note that the AMS extensions provide for declaration of ports of type "quantity" and a section in the architecture for equations that use the "==" operator. This allows creation of continuous time-domain relationships for model ports (in contrast to discrete events in "normal" VHDL). These models can be mixed freely with digital VHDL models " the VHDL-AMS language is a pure superset of VHDL " allowing for a very rich modeling environment in which to specify and verify sophisticated systems.


Figure 3. UAV System Model from The Designer's Guide to VHDL-AMS. (click on image to enlarge).

The VHDL-AMS language is an undiscovered asset for FPGA designers—a powerful tool to define and verify requirements in a non-digital context.

Figure 4. VHDL-AMS code for a simple "gain" model
{pagebreak} 1 Michael Gabrick, Rick Nicholson, Frank Winters, Bruce Young, Jim Patton, FPGA Considerations for Automotive Applications, 2006 SAE World Congress, Detroit, Michigan, April, 2006. http://delphi.com/pdf/techpapers/2006-01-0368.pdf

2 Mechatronics is the synergistic combination of mechanical engineering, electronic engineering and software engineering. The purpose of this interdisciplinary engineering field is the study of automata from an engineering perspective and serves the purposes of controlling advanced hybrid systems. The word itself is a portmanteau of 'Mechanics' and 'Electronics'. http://en.wikipedia.org/wiki/Mechatronics

3 P. Ashenden, G. Peterson, D. Teegarden, The System Designer's Guide to VHDL-AMS: Analog, Mixed-Signal and Mixed-Technology Modeling. San Francisco: Morgan Kaufman Publishers, September 2002. www.mkp.com/vhdl-ams.

4 Magneti Marelli Reduces Design and Simulation Time Using Mentor Graphics SystemVision for Safety Function Simulation, http://www.mentor.com/products/sm/news/magneti_marelli.cfm.

5 The German consortium VDA FAT-AK30 provides an extensive VHDL-AMS library for the purpose of facilitating model-based collaboration between automotive manufacturers and suppliers. http://fat-ak30.eas.iis.fraunhofer.de/index_en.html

6 The Society of Automotive Engineers (SAE) recently standardized the mechanism for specification of statistical distributions for VHDL-AMS language usage in automotive applications. See SAE standard J2748 at www.sae.org. {pagebreak}Darrell A. Teegarden has over 20 years of experience in development of HDL-based models and software tools. He currently manages the SystemVision VHDL-AMS related tool development for the System Level Engineering division at Mentor Graphics Corporation in Wilsonville, Oregon. Darrell is an IEEE member and holds a B.S., Chemical Engineering from Oregon State University and an M.S., Electrical Engineering from Stanford University. He is a co-author of The System Designer's Guide to VHDL-AMS: Analog, Mixed-Signal, and Mixed-Technology Modeling.

Comments

blog comments powered by Disqus