IAR Visual State
Efficient graphical modeling and code generation with cross-platform host support on Linux and Windows
01
C,C++, C# or Java source code
IAR Visual State is a tool for design and code generation that runs on Linux (Ubuntu) and Windows. It is used to graphically design state machines (based on UML) and generate C,C++, C# or Java source code. It is also suited for low code development in embedded systems and app’s development.
02
Shorten your time to market
The design and code generation tool IAR Visual State helps you bring order to your design and speed up your project. Because the tool is made for embedded systems, it enables you to use state machines in an easy and intuitive way, with no unnecessary features to maneuver among.
03
Tightly integrated with IAR Embedded Workbench
The generated source code files by IAR Visual State are handled automatically by IAR Embedded Workbench IDE when you include the project connection file in the IDE project. The C-SPYLink plugin enables high-level state machine model feedback directly to the IAR C-SPY Debugger including graphical animation in the state machine diagram and the possibility to set breakpoints at state machine level instead of C level.
04
Compact and Quality code
IAR Visual State generates very compact C/C++ code, 100% consistent with your design and also MISRA C compliant. Advanced verification and validation tools are included in the tool and documentation can be automatically generated out of the Unified Modeling Language (UML subset) state machine design.
Product overview
See the latest version of IAR Visual State in action and learn how to get started with the graphical modeling tool in this video.
Latest releases
We are constantly updating and refining our tools with new features, new device support and extended capabilities.
Latest version: 11.1.1
- New user interface
This release contains a new user interface that unifies editing and all other tools into the same application. - Windows and Linux Support
The product is available for both Microsoft Windows and Linux - Updated user documentation
Version 10.1
- Update to Documenter
The transitions out from initial, shallow history, and deep history states are now listed as part of the region these states are in.
Update to Documenter
The Documenter uses PNG files for images now rather than EMF files. - Update to CCoder and HCoder
The Classic Coder, and the Hierarchic Coder now has an extra option so the chosen variant name can be automatically appended to the chosen output paths. - Adds support for generation of Java and C# output.
- The latest release contains smaller corrections and fixes.
What type of license do you need?
Our tools are available in a flexible license model to suit your company needs. Together with our support and update agreements, you get the support you need in multiple time zones and multiple languages. Send a request for quote or contact sales to get started.
Stand-alone
- Personal license
- Locked to a specific PC
- Works without network connection
Mobile
- Personal license with flexibility
- Locked to a USB dongle
- Works without network connection
- Protects license from hardware failure
Want to know more?
We are present worldwide to help you wherever you are, and we are happy to answer any questions you might have about our products.
Get quote
Want to use this product in your development projects? Our sales team is here to guide you to the right solution for you. Complete this form and we will get back to you with a price quote tailored for your needs. We look forward to your request!
User guides and FAQ
General user guide
FAQ
Can I use IAR Visual State for high-integrity systems?
IAR Visual State is an excellent tool for many design tasks dealing with functional safety. For example, the IEC-61508 standard on functional safety explicitly recommends state machines as one design method to meet higher SIL levels.
By designing a system of state machines in IAR Visual State, you can take advantage of the formal verification to find issues in your design that are virtually impossible to write full coverage test suites for. Examples of what can be found are deadlock situations, unreachable design parts, never consumed input etc.
Why do you use a subset of UML—why not a different model syntax?
The state machine subset of UML is easy to learn, clean, and with well-defined semantics. UML is also a part of many software engineers' toolboxes and is widely taught at schools and universities, flattening the learning curve even more. The well-defined semantics makes it suitable for tight automatic code generation without the need for the designer to guide the code generation to resolve ambiguities etc.
How does IAR Visual State and other UML tools compare?
IAR Visual State is a pure state machine tool. The added benefits of integrated formal verification, testing, and validation tools, together with a well-proven code generator, meaning that for many applications, you do not need anything else. On the other hand, if you are already using a full UML tool for your general design activities, you will still benefit from IAR Visual State if you have parts of the design expressed as complex state machine systems. Thanks to the powerful testing and verification facilities of IAR Visual State, you will gain productivity and quality from day one.
What is the learning curve for the state machine subset of UML and IAR Visual State?
Assuming you are an experienced C developer, and you know how to write ISRs and device drivers, you should be able to pick up UML syntax and basic IAR Visual State operation in one day. On day two you will have command of basic Validator operations such as stepping through states, setting breakpoints, animation, scripting. You will be using IAR Visual State productively in real world applications in just a few days. If you already have some familiarity with UML and automatic code generation, you will be up and running even faster! To help you become an even more efficient user of IAR Visual State, IAR Systems offers training courses.
Can I use IAR Visual State to create applications that can run on a PC?
Yes. IAR Visual State is a good choice for all state machines, regardless of hardware platform. If only parts of your application consist of state machines, it is easy to integrate the generated code into the surrounding application. For moderately complex to very complex state machine systems, you will notice a tremendous increase in productivity and a decrease in quality issues. IAR Visual State is used as an internal development tool in the tool itself!
What kind of code is generated by the IAR Visual State code generator?
Two options are available: One extremely compact table-based mode and one for generating a straightforward translation of the state machine into readable C code. Which representation you choose depends on your specific application requirements regarding speed and size tradeoffs and the need to examine the generated code manually.
Is the code generated by IAR Visual State portable?
Yes. The generated code makes no assumptions about any compiler-specific features or uses any construct that is not fully ISO/ANSI conformant.
Can the code be tailored to my specific target platform and compiler?
Yes. The code generator can be configured to use compiler-specific keywords to place state machine code and data in memory areas of your choosing. The size of data entities can be forced to 16- or 32-bit to match your target architecture for speed purposes, even if the model only requires 8-bit representation. There are numerous choices to configure the code generator to balance the needs of the MCU target, the compiler, and coding standards.
How can I use IAR Visual State with my interrupts?
The IAR Visual State engine deals with events, and an event can be seen as an abstraction of something that happens in the environment. This makes it natural to map an interrupt to an IAR Visual State event if the interrupt should influence the state machine. A typical IAR Visual State application runs the state machine engine as part of the main loop if there is an event to process. How the interrupt routine communicates with the state machine engine is up to you. But implementation methods range from letting the interrupt routine set a flag that the main loop can detect to using a fully featured RTOS queue or semaphore. The structure of your application is the same as usual. If an interrupt service routine generates input to the system of state machines, the routine puts an appropriate event into the state machine event queue and returns.
Can I debug my application with feedback on the design level?
Yes, you can. If you are a user of IAR Embedded Workbench, you can choose to use the C-SPY Link facility to get high-level design model feedback directly in the C-SPY Debugger. The functionality includes graphical animation in the state diagram when executing, the possibility to set breakpoints at the state machine level instead of the C level, and trace and log functionality. If you use a non-IAR build chain or cannot use a hardware debug solution with C-SPY, you can use the RealLink facility to communicate state machine data over a separate communication channel.
How can I use IAR Visual State with my RTOS?
Use IAR Visual State to design the control logic of a task or part of a task. Integrate your tasks with respective priorities into the system with the RTOS in the same manner, you would if you were coding the application by hand. To split the IAR Visual State code to run in different tasks, you split the IAR Visual State state machines into different IAR Visual State systems. An IAR Visual State system is a collection of state machines designed as a unit and can run as a unit and possibly have a rather tight coupling to each other. An RTOS application can contain any number of systems, and systems can communicate on a task level using the available RTOS primitives. Systems can be assigned arbitrarily to RTOS tasks so that a task can house more than one system at a time.
Can I prototype my design before having the hardware?
The code generated by IAR Visual State can be integrated easily with an application developed using a RAD tool like Altia Design, Microsoft® Visual Basic®, Microsoft® Visual C++®, Borland® DelphiTM, or any other GUI toolkit of your choosing.
How can I handle asynchronous events?
Asynchronous events are handled if forwarded to the IAR Visual State engine. This is usually done by putting them into the event queue. Once an event is in the event queue, it will eventually be processed by the IAR Visual State control logic.
Can I modify the generated code?
The code generated by IAR Visual State focuses on the control logic of a state machine system. This part of the code should not be modified by hand for several reasons, of which the most important one is that the design is always the only explicit representation of the control logic. In that way, the model and the executing code always stay in sync. Modifying state machine code by hand always carry the risk of introducing hard-to-find errors in the internal bookkeeping of states and conditions, regardless of the original design and implementation method.
How can we use Visual State in interdisciplinary IoT projects?
For an IoT project with Java/C# application and an embedded system, the state machine behind it has great similarities. In this case, the benefit of using IAR Visual State is that you can have the state machines in one design but with different variants, one for the Java/C# application and one for the embedded application. The gain is that the Visual State model will connect the team working with the Java/C# application and the embedded team. Changes are implemented in one place, which minimizes the risk of mistakes and bugs.
Download free trial
IAR Visual State - Free trial version
The evaluation edition is a fully functional edition of IAR Visual State including the Designer, Validator, Verificator, Code generator, documentation generator and project manager. A complete set of user guides is included in PDF format.
Limitations
The evaluation edition corresponds to the latest release of the full edition of IAR Visual State, with a 14-day time limitation with no state limit.
The evaluation edition is intended for prospective customers to test and evaluate IAR Visual State, and must not be used for product development or any other kind of commercial use.