t2:get_val

get_val


get_val — Get I/O value

Description


fix32 get_val(uint8 io);

Get the I/O value indexed by io.

An I/O value is initialized with the current state value of the input element to it mapped.
If an I/O value was programmatically set by set_val(), get_val() will return the value programmatically set.

Parameters


  • io: Index of an I/O value.

Return Value


The current I/O value.

Examples


Example #1 get_val() example

main {
    if(get_val(BUTTON_5) >= 75.5) {
        set_val(BUTTON_5, 100.0);
    }
}

See Also

t2/get_val.txt · Last modified: 2016/11/29 03:09 by J2Kbr