41 static unsigned rfunc;
42 static unsigned wfunc;
43 static int dev_channel;
44 static int initialized = 0;
72 struct dsc$descriptor_s com_desc;
79 com_desc.dsc$w_length = strlen( cp );
80 com_desc.dsc$a_pointer = cp;
81 com_desc.dsc$b_class = DSC$K_CLASS_S;
82 com_desc.dsc$b_dtype = DSC$K_DTYPE_T;
83 wfunc = IO$_WRITEVBLK | IO$M_NOFORMAT;
84 rfunc = IO$_READVBLK | IO$M_NOECHO;
85 status = sys$assign(&com_desc,&dev_channel,0,0);
86 if(status != SS$_NORMAL){
87 printf(
"SYS$ASSIGN failed. Status = %d\n",status);
98 dev_open(name,channel)
102 struct dsc$descriptor_s com_desc;
111 com_desc.dsc$w_length = strlen( cp );
112 com_desc.dsc$a_pointer = cp;
115 com_desc.dsc$w_length = strlen( name );
116 com_desc.dsc$a_pointer = name;
118 com_desc.dsc$b_class = DSC$K_CLASS_S;
119 com_desc.dsc$b_dtype = DSC$K_DTYPE_T;
120 wfunc = IO$_WRITEVBLK | IO$M_NOFORMAT;
121 rfunc = IO$_READVBLK | IO$M_NOECHO;
122 status = sys$assign(&com_desc,channel,0,0);
123 if(status != SS$_NORMAL){
124 printf(
"SYS$ASSIGN failed. Status = %d\n",status);
136 dev_printf(buffer,length)
143 status = sys$qiow(6,dev_channel,wfunc,&f_status,0,0,buffer,length,0,0,0,0);
144 if(status != SS$_NORMAL){
145 printf(
"SYS$QIOW failed. Status = %d\n",status);
159 status = sys$qiow(7,dev_channel,rfunc,&f_status,0,0,buf,1,0,0,0,0);
170 dev_write(channel,buffer,length)
178 status = sys$qiow(6,channel,wfunc,&f_status,0,0,buffer,length,0,0,0,0);
179 if(status != SS$_NORMAL){
180 printf(
"SYS$QIOW failed. Status = %d\n",status);
196 status = sys$qiow(7,channel,rfunc,&f_status,0,0,buf,1,0,0,0,0);
static char buf[MAXPROMPT]