09.12.2012 Views

Basic Characteristics RAPID

Basic Characteristics RAPID

Basic Characteristics RAPID

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

ClkRead Reads a clock used for timing<br />

Example<br />

ClkRead is used to read a clock that functions as a stop-watch used for timing.<br />

reg1:=ClkRead(clock1);<br />

The clock clock1 is read and the time in seconds is stored in the variable reg1.<br />

Return value Data type: num<br />

Argument<br />

The time in seconds stored in the clock.<br />

ClkRead (Clock)<br />

Clock Data type: clock<br />

Program execution<br />

Syntax<br />

The name of the clock to read.<br />

A clock can be read when it is stopped or running.<br />

Once a clock is read it can be read again, started again, stopped or reset.<br />

If the clock has overflowed, program execution is stopped with an error message.<br />

ClkRead ’(’<br />

[ Clock ’:=’ ] < variable (VAR) of clock > ’)’<br />

A function with a return value of the type num.<br />

<strong>RAPID</strong> Reference Manual 9-ClkRead-1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!