[R] reading data in serial port - win32

Cleber Nogueira Borges klebyn at yahoo.com.br
Mon Sep 1 02:33:00 CEST 2008

Hello all

I'd like to get some instruments data by serial port (COM1 - win32)

I make a loopback serial adapter for a testing with the code:

system('mode COM1 9600,N,8,1')
ser <- file("COM1", open='r+')
write('12345', ser)
scan(ser, what=as.character(1), n=1)

So I get the data that I wrote in the port...
But I don't have a more fine control about the serial configuration with
this approach like timeout, handshake etc...

Is there a specific package (library?) for hardware communications?
( For serial port specifically )




Experimente já e veja as novidades.

More information about the R-help mailing list