®
10.2 RTC
5 Command Set
All commands are arranged in alphabetical order.
Ctrl Command acquire_rtc
Function
reserves the desired RTC
Call
NoOfAcquiredCard = acquire_rtc( CardNo )
Parameter
CardNo
Result
The return value (unsigned 32-bit value) is CardNo if the reservation was successful, or 0 if
the board is currently reserved for another application or if version check determines an
error.
Comments
• The acquire_rtc command is also useful for single-board systems which need to coor-
dinate the use of a board by multiple applications.
• The acquire_rtc command has no effect if CardNo exceeds the number of RTC
found during initialization (see
boards begin with 1) (return value 0,
• Access rights to existing boards are assigned exclusively (always to only one application
at a time). The acquire_rtc command therefore has no effect if the requested board is
already reserved by another application (return value 0,
RTC5_ACCESS_DENIED). Before an already-reserved board can be acquired via
acquire_rtc, the application with current access rights must explicitly release its rights
via
release_rtc (page 392)
On the other hand, if the board was already freed prior to initialization of an applica-
tion, then initialization via
board access rights for the application. In this case, an explicit acquire_rtc call is not
needed and has no effect. Nevertheless, the return value is the CardNo.
• Assorted versions of the driver DLL and the program files RTC5OUT.out, RTC5RBF.rbf
and RTC5DAT.dat cannot be arbitrarily combined with another. The command
acquire_rtc performs a version compatibility check. If no program files are loaded, then
a version check can't be explicitly executed
RTC5_TIMEOUT), but the check will still be regarded as successful and acquisition will not
be hindered. If program files have been loaded and the version check determines an
error, then access will be denied (return value 0,
RTC5_ACCESS_DENIED|RTC5_VERSION_MISMATCH).
• A board successfully requested via acquire_rtc does not automatically become the
active board. Activation is only achieved via
• Running boards are neither halted nor initialized via acquire_rtc.
• The acquire_rtc command is also available without explicit access rights to a particular
®
RTC
5 board.
• acquire_rtc is not available as a multi-board command.
• Also take into account
®
®
RTC
4 RTC
5 new command
References
init_rtc5_dll, select_rtc, free_rtc5_dll, release_rtc,
®
RTC
5 PC Interface Board
Rev. 1.9 e
10 Commands And Functions
®
5 board for an application (user program)
the desired board's (DLL-internal) number as an unsigned 32-bit value
rtc5_count_cards, page
or
free_rtc5_dll (page
init_rtc5_dll
"Board Acquisition by an Application", page
396) or if CardNo = 0 (real
get_last_error
return code: RTC5_PARAM_ERROR).
get_last_error
259).
will result in board management assigning
(get_last_error
return code:
get_last_error
return code:
select_rtc (page 403)
rtc5_count_cards
®
5 boards
return code:
or init_rtc5_dll.
86.
227
Need help?
Do you have a question about the RTC 5 PC Interface Board and is the answer not in the manual?