Average

Syntax:

    integer_variable = Average(byte_variable1 , byte_variable2)

Command Availability:

Available on all microcontrollers.

Explanation:

A function that returns the average of two numbers. This only supports byte variables.

Provides a very fast way to calculate the average of two 8 bit numbers.

Example:

 average_value = Average(8,4)   ' Will return 6