Intermec Janus 2010 Reference Manual page 131

Intermec janus 2010: reference guide
Hide thumbs Also See for Janus 2010:
Table of Contents

Advertisement

New_Line;
end if;
-- loop until first character in buffer is a 'Q' or 'q'
while
not done loop
if im_issuccess(status) then
-- get the receive data
while (com_buff_rec.protocol_xfer_status = COMM_INUSE) loop
null;
end loop;
Put_Line ("Receive done");
status := im_rx_check_status (IM_COM1);
if im_iserror(status) then
Put ("rx check = ");
im_message (status);
New_Line;
end if;
Put ("comm_length is ");
SYSWORD_IO.Put (com_buff_rec.comm_length, width => 3);
New_Line;
for i in Integer range 1..Integer(com_buff_rec.comm_length) loop
Put(data_buffer(i));
end loop;
New_Line;
else
Put ("Rx no wait err = ");
im_message (status);
New_Line;
end if;
com_buff_rec.command := IM_CU_TRANSMIT;
com_buff_rec.protocol_xfer_status := COMM_INUSE;
com_buff_rec.user_length := com_buff_rec.comm_length;
com_buff_rec.comm_length := 0;
com_buff_rec.data_ptr := data_buffer'Address;
com_buff_rec.protocol_mode := IM_NO_PROTOCOL;
com_buff_rec.eom_char := 0;
status := im_transmit_buffer_no_wait (IM_COM1, com_buff_rec'Address);
if im_issuccess (status) then
while (com_buff_rec.protocol_xfer_status = COMM_INUSE) loop
Put_Line ("sending data");
end loop;
Put_Line ("Buffer sent");
status := im_tx_check_status (IM_COM1);
if im_iserror(status) then
Put ("tx check = ");
im_message (status);
New_Line;
end if;
else
Put ("transmit stat = ");
im_message (status);
New_Line;
end if;
New_Line;
-- set up to receive again
status := im_cancel_rx_buffer (IM_COM1);
if im_iserror(status) then
Put ("canc rx2 = ");
im_receive_buffer_no_wait
3
3-91

Advertisement

Table of Contents
loading

This manual is also suitable for:

Janus 2050Janus 2020Janus psk for ada

Table of Contents