Using source files, Creating a new source file, Renaming a source file – Rockwell Automation 2098-UWCPRG Ultraware Software User Manual User Manual

Page 301: Creating a new source file renaming a source file

Advertising
background image

Rockwell Automation Publication 2098-UM001G-EN-P - February 2011

303

Creating and Running Programs Chapter 6

Using Source Files

A source file is a text file that contains C programming language code, which
Ultraware software uses to create an executable program file for an Ultra5000
drive when you execute the Program menu’s Build command. A source file is
identified by its .c extension. Each source file contains:

# include statements, (which refer to external header files - identified by
their .h extensions)

the C code that is the body of the source file.

You can move a source file to an Ultra5000 drive's Archives branch for storage.

Creating a New Source File

To create a new source file do one of these actions:

Click Source File in the Insert menu.

Click project in the Workspace window, and then right-click Insert Source
File.

A new source file appears in the Workspace window. The name of the new source
file is Source.c or Source

n.c if Source.c already exists. Where n is the lowest

integer that creates a unique source file name within the selected project.

After a source file is created, you can configure its parameters (change its name)
and edit its contents.

Renaming a Source File

To rename a source file, perform these steps.

1. Choose the source file in the Workspace window.
2. Choose one of these commands:

Click Properties in the File menu.

Right-click Properties from the pop-up menu.

Double-click the selected source file.

The Source File window appears in the Client Area:

Advertising