Home  Contents

rawio:rxcnt

Rawio Core4 Lua Event System

SYNOPSIS

  1. nr = handle:rxcnt()
  2. nr = handle:txcnt()

DESCRIPTION

Return the number of characters in the receive buffer (rawio:rxcnt()) or transmit buffer (rawio:txcnt()).

RETURN VALUE

On success, returns the buffer count. On failure, returns nil. In case of an error, the error can be retrieved using rawio:lastError().

ERRORS

This function works only on TTY devices.

SEE ALSO