N Device Get Characters - FujiNetWIFI/fujinet-firmware GitHub Wiki

Description

Get one or more characters from a socket previously opened. If ICBLL/ICBLH is more than one, then CIOV will call this routine multiple times, fetching a character from the buffer, each time.

[!TIP] It is recommended that you call STATUS prior to this call, so that you can determine if any characters are available to be fetched.

Parameters

  • IOCB
  • If multiple characters are to be fetched, a pointer to a user buffer must be placed in ICBAL/ICBAH, as well as a length for the buffer in ICBLL/ICBLH

Returns

Standard CIO returns, such as:

  • If there are no more characters to fetch, an ERROR 136 is returned.

Examples

BASIC

Given a IOCB is opened with something like:

OPEN #1,4,0,"N:TCP:192.168.1.8:2000"

The following will fetch the next available byte from the socket, and place in variable A.

GET #1,A

TBD: I need a good example, here!