GeoLocatorByPostalCode (FB)

FUNCTION_BLOCK GeoLocatorByPostalCode EXTENDS APICaller

Requests geo location information from the API Server by using the postal code of a place.

InOut:

Scope

Name

Type

Initial

Comment

Inherited from

Input

xExecute

BOOL

Rising edge: Starts defined operation
FALSE: Resets the defined operation after ready condition was reached

ETrig

Output

xDone

BOOL

TRUE: Ready condition reached

ETrig

xBusy

BOOL

TRUE: Operation is running

ETrig

xError

BOOL

TRUE: Error condition reached

ETrig

Input

sApiKey

API_KEY

APICaller

Output

eError

ERROR

APICaller

sConstructedUrl

URL

Contains the internally constructed URL, that is used to retrieve data from the API Server.

APICaller

xUrlConstructed

BOOL

Is TRUE, when the content of sConstructedUrl is valid (after the internal URL Construction is finished).

APICaller

Input

sPostalCode

POSTAL_CODE

sCountryCode

COUNTRY_CODE

ISO 3166 country code

sLanguageCode

LANGUAGE_CODE

‘’

Optional ISO 3166 country code to extract a local city name in the specifiec language, if available.

Inout

geoLocation

GeoLocation

Methods:

Structure: