Making and Running an Application

Two scenarios are described below. In the first scenario, you build and run an application in one step. In the second scenario, you generate code, compile the code, and run the application in separate steps.

In either case, if you have made changes to the project that have not been saved, a message dialog box will be displayed, telling you that you have unsaved edits and giving you the choice of cancelling the generate code process or saving the project. If you choose to save the project, you will have to specify where to save the project if it has not been saved before.

To Make and Run in One Step

Choose Code Generator from the File menu of the App Builder primary window.

The Code Generator is displayed.

Click Make & Run to generate code, build the application, and run it.

If you have saved the project and all goes well, a number of messages will be displayed in the output pane at the top of the Code Generator. The final message will be "Running: ./[projectname]" and the application will run.

At the least, the application primary window will be displayed. Any windows whose visibility is not set to yes at application startup will be hidden. Depending on what functionality you included that does not require user code, the application might do a variety of things. Menus can be displayed, some connections can be tested, On Item help can be displayed, and so on.

Note -

Ultimately, you must write some code to complete the application. For example, any Call Function callbacks specified in the Connections Editor will have to be substituted for. See "Adding User Code to Generated Code" for more information.

To Generate Code, Make, and Run Separately

Click Generate Code to generate code for the current project.

As the code generator runs, messages are displayed in the output pane at the top of the Code Generator window. The final message should be "Completed successfully." A number of files will be created, including Makefiles, project files, module files, and two dtb_utils files. You can look at the files in the term pane at the bottom of the Code Generator window.

Click Make to build the application.

More messages will be displayed in the Output Pane as the application is compiled. The final message again should be "Completed successfully." A few more files will be created, including object files and the executable application file, which has the name you gave the project.

Click Run to run the application.

The application will be started--as if you had typed the name of the executable at the command line.

Click Abort to quit the application.

This will terminate the application, closing all windows. You can also click Abort to terminate code generation or make operations started in the Code Generator window.

To Set Code Generator Options

To change the options that determine what code is generated and other Code Generator functions:

Choose Code Generator from the File menu of the App Builder primary window to display the Code Generator window.

To Generate Code From the Command Line

Code is generated for each module specified on the command line, or for all modules in the project, if no modules are specified. If no project file is specified, a project file containing the specified module(s) is searched for in the current directory.

Files with extension .bip are assumend to be BIL project files, files with .bix extension are assumed to be encapsulated BIL files, and files with a .bil extension are assumed to be BIL module files.