Rockwell Automation 6008-SV2R VMEbus remote I/O Scanner User Manual
Page 159
Advertising

Chapter
Programming the Scanner
8
8Ć25
/*
**
** LOCK_CONBT_ENTRY() –– lock the data buffer of a Continuous Block Transfer Table Entry
**
**
The function busy–waits on the entry’s turn & sv2_flag fields, using the standard
**
Peterson’s Solution method.
**
**
parameters:
pointer to the Continuous BT Table entry
**
return value:
always success (0)
**
*/
int
lock_conbt_entry (btentry far *entry)
{
entry–>vmp_flag
= 1;
entry–>turn_flag
= 1;
while ((entry–>sv2_flag) && (entry–>turn_flag == 1));
return 0;
}
/*
**
** UNLOCK_CONBT_ENTRY() –– unlock the data buffer of a Continuous Block Transfer Table Entry
**
**
parameters:
pointer to the Continuous BT Table entry
**
return value:
none
**
*/
void
unlock_conbt_entry (btentry far *entry)
{
entry–>vmp_flag = 0;
return;
}
Advertising
This manual is related to the following products: