# LGF_ToUpper (FC / 1.0.0)

Overview

Author: Siemens Industry Online Support

## Short description

This function converts the lowercase letters of a string into their capital equivalents.

### Block Interface

| LGF_ToUpper (FC) |
--- | --- | ---
String |  |  | In |  | Ret_Val |  |  | String

### Input parameter

Identifier | Data type | Description
--- | --- | ---
In | String | String input

### Output parameter

Identifier | Data type | Description
--- | --- | ---
Ret_Val | String | Resulting string, after the conversion

## Functional description

The conversion of a string to upper case is replacing lowerer case characters with their upper case counterparts. Within the ASCII table the upper case characters are at a lower index to their lower case counter parts. The offset is 32 (20hex) e.g. ASCII for 'a' is 97 (61 hex) the ASCII code for 'A' is 65 (41 hex).

That means the conversion is simply a subtraction of 32 (20hex) from the ASCII code in question. ASCII codes which are between 'a' and 'z' are going to be replaced.

## Change log

Version & Date | Change description
--- | ---
| 1.0.0 | Siemens Industry Online Support
| 10.03.2023 | First released version