Table of Contents Previous Chapter Chapter 24: Permissive

Chapter 24: Permissive

1. Introduction

The permissive record is for communication between a server and a client. An example is a sequence program client and an operator interface server. Two fields are used VAL and WFLG. The method of use is as follows:

  1. Initially both VAL and WFLG are 0, which means OFF.
  2. When the server is ready to accept a request, it sets WFLG equal to 1, which means ON.
  3. The client monitors WFLG. Until it turns ON, the client must not change VAL.
  4. When the client wants to notify the server it turns VAL ON.
  5. The server notices that VAL is ON. He sets both WFLG and VAL OFF. Performs whatever action is associated with this permissive (a private matter server and client), and when ready to accept a new request sets WFLG ON.
By using multiple permissive records a sequence program can communicate its current state to a client.

2. Field Summary

-----------------------------------------------------------
Field  Type    DCT  Initial  Access  Modify  Rec Proc   PP   
                                             Monitor         
-----------------------------------------------------------
LABL   STRING  Yes  Null     Yes     Yes     No         Yes  
VAL    USHORT  No   0        Yes     Yes     Yes        Yes  
OVAL   USHORT  No   0        Yes     No                 No   
WFLG   USHORT  No   0        Yes     Yes     Yes        Yes  
OFLG   USHORT  No   0        Yes     No                 No   
-----------------------------------------------------------

3. Field Descriptions

-----------------------------------------------------------------------------------
Name  Summary         Description                                                    
-----------------------------------------------------------------------------------
LABL  Label           A descriptive string.                                          
VAL   Value           Client sets this field when it wants service from server.      
                      Only the client should set this field. The server clears it.   
OVAL  Old Value       Used to decide if monitors should be triggered.  Value         
                      change monitors are invoked if OVAL is not equal to VAL.       
WFLG  Watchdog Flag   Server sets this field when it is ready to accept a request.   
                      Only the server should modify this field.                      
OFLG  Old Flag Value  Used to decide if monitors should be triggered.                
-----------------------------------------------------------------------------------

4. Record Support Routines

Two record support routines are provided: process, and get_value.

process

process sets UDF to FALSE, triggers monitors on VAL and WFLG when they change, and scans the forward link if necessary.

get_value

get_value fills in struct valueDes so that it refers to VAL.

 
Table of Contents Next Chapter