|
DataMuseum.dkPresents historical artifacts from the history of: RC4000/8000/9000 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about RC4000/8000/9000 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 1536 (0x600) Types: TextFile Names: »tdebugin«
└─⟦a41ae585a⟧ Bits:30001842 SW-save af projekt 1000, Alarm-system └─⟦72244f0ef⟧ └─⟦this⟧ »tdebugin«
process debugin(var input_sem : semaphore; pu,level : integer); (***********************************************************************) (* *) (* debugin driver *) (* *) (***********************************************************************) const inputlevel_index = 2; datain_index = 7; ok = 0; timeout = 2; mask = -1; max_input_timeout = 20; var ch_msg : reference; msg : reference; result : integer; data_in : byte; begin platoninit; (* to be removed *) if reservech(ch_msg,pu,level,mask) = 1 then begin writeram(inputlevel_index,level); (* init interrupt level *) while true do begin own.timer := max_input_timeout; channel ch_msg do clearlevel; (* wait interrupt *) if own.timer = 0 then begin result := timeout; data_in := 0; (* just assign any legal value *) end else begin result := ok; readram(data_in,datain_index) end; sensesem(msg,input_sem); if not nil(msg) then begin with msg^ do begin u2 := result; u4 := data_in end; return(msg) end end end end . ▶EOF◀