56 |
|
/* enter main loop */ |
57 |
|
do { |
58 |
|
rdy = disp_wait(); |
59 |
+ |
if (rdy & RDY_SRV) { /* process server result */ |
60 |
+ |
res = serv_result(); |
61 |
+ |
if (pause && res != DS_SHUTDOWN) { |
62 |
+ |
serv_request(DR_ATTEN, 0, NULL); |
63 |
+ |
while ((res = serv_result()) != DS_ACKNOW && |
64 |
+ |
res != DS_SHUTDOWN) |
65 |
+ |
; |
66 |
+ |
} |
67 |
+ |
} |
68 |
|
if (rdy & RDY_DEV) { /* user input from driver */ |
69 |
|
inp = dev_input(); |
70 |
|
if (inp & DFL(DC_SETVIEW)) |
107 |
|
pause = 0; |
108 |
|
break; |
109 |
|
} |
101 |
– |
if (rdy & RDY_SRV) { /* process server result */ |
102 |
– |
res = serv_result(); |
103 |
– |
if (pause && res != DS_SHUTDOWN) { |
104 |
– |
serv_request(DR_ATTEN, 0, NULL); |
105 |
– |
while ((res = serv_result()) != DS_ACKNOW && |
106 |
– |
res != DS_SHUTDOWN) |
107 |
– |
; |
108 |
– |
} |
109 |
– |
} |
110 |
|
} while (res != DS_SHUTDOWN); |
111 |
|
/* all done */ |
112 |
|
quit(0); |