setDpin {Rduino}R Documentation

Set digital pin

Description

Set a digital pin to on or off

Usage

setDpin(pin, value)

Arguments

pin

the number of the pin to set (integer)

value

the value to which to set the pin (binary)

Examples

## Not run: 
rduinoConnect()
# flash LED rapidly
for (i in 0:9) 
{
  setDpin(8,1)
  Sys.sleep(0.05)
  setDpin(8,0)
  Sys.sleep(0.05)
}
rduinoClose()

## End(Not run)


[Package Rduino version 0.1 Index]