Class: EventMachine::SerialPort

Inherits:
StreamObject
  • Object
show all
Defined in:
lib/em-serialport/serial_port.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(io) ⇒ SerialPort

Returns a new instance of SerialPort.



27
28
29
# File 'lib/em-serialport/serial_port.rb', line 27

def initialize(io)
  super
end

Class Method Details

.open(dev, baud, databits, stopbits, parity) ⇒ Object



22
23
24
25
# File 'lib/em-serialport/serial_port.rb', line 22

def self.open(dev, baud, databits, stopbits, parity)
  io = ::SerialPort.new(dev, baud, databits, stopbits, parity)
  self.new(io)
end