Class: Cgpio::Gpio

Inherits:
Object
  • Object
show all
Defined in:
lib/cgpio/gpio.rb

Class Method Summary collapse

Class Method Details

.new(nr, options = {}) ⇒ Object



5
6
7
8
9
10
11
# File 'lib/cgpio/gpio.rb', line 5

def self.new(nr, options={})
    if Cgpio.configuration.virtual
        Cgpio::VirtualGpio.new(nr, options)
    else
        Cgpio::RealGpio.new(nr, options)
    end
end