Syntax
FUNCTION TXFREE( channel ) as
INTEGER ' built-in
keyword
Description -- added in version 8.30
TXFREE(channel) will
return the amount of free space in the TX buffer of channel in bytes.
Because the :PC11U37 uses USB for channel 0, it appears to be always
empty.
Example
BAUD(1)=115200 ' always need to enable UART(channel) first
print TXFREE(1) '
show the amount of free space in TXD buffer
TXD(1)="a"
TXD(1)="b"
TXD(1)="c"
TXD(1)="d"
print
TXFREE(1) ' should be less space available
for UARTs without FIFOs
Differences from other BASICs
- no equivalent in Visual BASIC
- no equivalent in PBASIC
See also