in reply to Reading serial port data into a file

crazysarik:

I'd try something like this:

open my $FH, '>', 'results' or die $!; while (my $bytes = xbee_get_bytes()) { print $FH $bytes; }

...roboticus

When your only tool is a hammer, all problems look like your thumb.