PORTWRITECHAR

Synopsis
PORTWRITECHAR data
Description

Writes one byte to the currently open port and output the actual number of bytes written (0 or 1). The data input must be an integer from 0 to 255.

Example
PORTOPEN "com1
SHOW PORTWRITECHAR ASCII "a
1
SHOW PORTWRITECHAR ASCII "t
1
SHOW PORTWRITECHAR 13
1
WAIT 60
PRINT "Reading...
Reading...
REPEAT 10 [MAKE "x PORTREADCHAR IF NOT :x = -1 [TYPE CHAR :x]]
PRINT ".
at||
OK|
.
PORTCLOSE

SourceForge.net Logo